限速[精彩]08-02b_路由器的限速

路由器限速  时间:2021-04-22  阅读:()

关于路由器的限速

速率的分类

1、 CIR合法速率

2、 BC突发速率

3、 BR极限速率

CIR BC BR的关系。

CIR*1.5=BC

BC*2 =BR

例如 限制A用户的上网速率为10KB。

CIR 10KB

BC 15KB

BR 30KB

实验环境

真机 网卡vmnet 1

60.0.0.1

路由器两个以太网网卡

E0/1 wan 60.0.0.2

E0/0 lan 192.168.0.1

将两个网卡接口绑定在vmnet 1上将w indows虚拟机也绑定在vmnet 1上。

虚拟机的ip 192.168.0.254/24

总结

设置好ip和网关后要求在客户端通过trac ert命令测试如果经过了路由器说明成功 在客户端安装下载软件

在服务器端安装ftp服务

路由器限速的过程

基于客户端ip地址的限速

1、创建访问控制列表定义网段

Router(config)#access-list 110 permit ip any 192.168.0.2540.0.0.0

2、定义一个类图class-map

Router(c onfig)#c las s-map aaa

将定义好的访问列表写在类图中

Router(config-cmap)#match access-group 110

3、定义一个策略图

Router(config)#policy-map bbb

总结策略图(类图(访问类表))

 限速的对象是类图。

4、对类图做限速

Router(c onfig-pmap)#c las s aaa

Router(config-pmap-c)#police 80000 1500030000 conform-action transmit exceed-action drop

格式c las s类图名police CIRbit BCbyte BRbyte confirm-action transmit exceed-action drop

注 8bit 位 =1 byte 字节 1024byte 字节 =1KB 1024KB1MB

5、加载策略图接口模式下进行用进口表示

Router(c onfig)#int e0/1

Router(c onfig-if)#s ervic e-policy input bbb

基于客户端mac地址的限速

1、配置mac地址访问列表

Router(config)#acc ess-list rate-limit 100000c.295d.4bf0

格式

Router(config-if)#rate-limit output access-group 10080000 1500030000 confirm-action transmit exceed-action drop

总结

1、区分三种不同的速率注意单位 

2、限速的类型基于ip 基于mac

3、三种图的区别访问列表、类图(class-map)、策略图(policy-map)

4、 明确两种行为 confirm-action transmit

exceed-action drop

######基于客户端IP地址的限速对虚拟机PC下载文件限速最大为10kb。##############

TOPO图如下

将windows虚拟机也绑定在vmnet 1 (Host-only)上

实验环境

真机 网卡vmnet 1 60.0.0.1

路由器两个以太网网卡

E0/1 wan 60.0.0.2

E0/0 lan 192.168.0.1

将两个网卡接口绑定在vmnet 1上将w indows虚拟机也绑定在vmnet 1上。虚拟机的ip 192.168.0.254/24

##配置IP地址

Router>en

Router#c onf t

Router(c onfig)#int e0/0

Router(config-if)#description LAN

Router(c onfig-if)#ip add 192.168.0.1255.255.255.0

Router(c onfig-if)#no sh

Router(c onfig-if)#exit

Router(c onfig)#int e0/1

Router(config-if)#description WAN

Router(c onfig-if)#ip add 60.0.0.2255.0.0.0

Router(c onfig-if)#no sh

Router(c onfig-if)#exit

Router(config)#access-list 110 permit ip any 192.168.0.2540.0.0.0

Router(c onfig)#c las s-map aaa

Router(config-cmap)#match access-group 110

Router(c onfig-cmap)#exit

Router(config)#policy-map bbb

Router(c onfig-pmap)#?

QoS policy-map configuration commands:class policy criteriadescription Policy-Map descriptionexit Exit from QoS policy-map configuration modeno Negate orsetdefault values of acommandrename Rename this policy-map

<cr>

Router(c onfig-pmap)#clas s ?

WORD class-mapnameclass-default System default class matching otherwise unclassified packets

Router(c onfig-pmap)#c las s aaa

Router(c onfig-pmap-c)#polic e?

<8000-2000000000> Bits per second

Router(config-pmap-c)#police 80000?

<1000-512000000> Normal burst bytesconform-action action when rate is less than normal burst

<cr>

Router(config-pmap-c)#police 80000 15000?

<1000-512000000> Maximum burst bytesconform-action action when rate is less than normal burst

<cr>

Router(config-pmap-c)#police 80000 1500030000 conform-action transmit exceed-action dropRouter(c onfig-pmap-c)#exit

Router(c onfig-pmap)#exit

Router(c onfig)#int e0/1

Router(c onfig-if)#s ervic e-policy input bbb

#####以下是基于客户端MAC地址的限速 ######

Router(c onfig-if)#no s ervic e-policy input bbb

Router(c onfig-if)#exit

Router(config)#acc ess-list rate-limit?

<0-99> Precedence ACL index

<100-199> MAC address ACL index

<200-299> mpls exp AC L index

Router(config)#access-list rate-limit 100?

H.H.H MAC address

Router(config)#access-list rate-limit 100000c.295d.4bf0

Router(c onfig)#int e0/0

Router(c onfig-if)#ra

Router(c onfig-if)#rate

Router(c onfig-if)#rate-limit?input Rate lim it on inputoutput Rate lim it on output

Router(config-if)#rate-limit output access-group 10080000 1500030000 confirm-action transmit exceed-action dropRouter(c onfig-if)#

PIGYUN:美国联通CUVIPCUVIP限时cuvip、AS9929、GIA/韩国CN2机房限时六折

pigyun怎么样?PIGYunData成立于2019年,2021是PIGYun为用户提供稳定服务的第三年,目前商家提供香港CN2线路、韩国cn2线路、美西CUVIP-9929、GIA等线路优质VPS,基于KVM虚拟架构,商家采用魔方云平台,所有的配置都可以弹性选择,目前商家推出了七月优惠,韩国和美国所有线路都有相应的促销,六折至八折,性价比不错。点击进入:PIGYun官方网站地址PIGYUN优惠...

CloudCone:$14/年KVM-512MB/10GB/3TB/洛杉矶机房

CloudCone发布了2021年的闪售活动,提供了几款年付VPS套餐,基于KVM架构,采用Intel® Xeon® Silver 4214 or Xeon® E5s CPU及SSD硬盘组RAID10,最低每年14.02美元起,支持PayPal或者支付宝付款。这是一家成立于2017年的国外VPS主机商,提供VPS和独立服务器租用,数据中心为美国洛杉矶MC机房。下面列出几款年付套餐配置信息。CPU:...

易探云服务器怎么过户/转让?云服务器PUSH实操步骤

易探云服务器怎么过户/转让?易探云支持云服务器PUSH功能,该功能可将云服务器过户给指定用户。可带价PUSH,收到PUSH请求的用户在接收云服务器的同时,系统会扣除接收方的款项,同时扣除相关手续费,然后将款项打到发送方的账户下。易探云“PUSH服务器”的这一功能,可以让用户将闲置云服务器转让给更多需要购买的用户!易探云服务器怎么过户/PUSH?1.PUSH双方必须为认证用户:2.买家未接收前,卖家...

路由器限速为你推荐
Thresholdcssipad连不上wifiipad无法加入网络怎么回事勒索病毒win7补丁求问win7 64位旗舰版怎么预防勒索病毒tcpip上的netbios网络连接详细信息上的netbios over tcpip是什么意思?phpecho为什么在PHP中使用echo FALSE;什么也输出不了?应该如何输出FALSE?谢谢!联通版iphone4s苹果4s是联通版,或移动版,或全网通如何知道?csshack关于CSS hack的写法电信版iphone4s4和苹果iPhone 4S 电信版有什么区别联通合约机iphone5iphone5联通合约机是怎么回事google搜图google自定义搜索是什么?怎么用
二级域名 域名到期查询 双线vps hawkhost优惠码 日志分析软件 华为云主机 免费申请个人网站 卡巴斯基破解版 创建邮箱 阿里云手机官网 免费个人网页 买空间网 umax 阿里云邮箱怎么注册 cdn加速 机柜尺寸 alexa搜 侦探online 内存 留言板 更多