首页 | 编程语言 | 网站建设 | 游戏天堂 | 冲浪宝典 | 网络安全 | 操作系统 | 软件时空 | 硬件指南 | 病毒相关 | IT 认证
软讯网络 > 冲浪宝典 > 冲浪技巧 > 端口限速配置
【标  题】:端口限速配置
【关键字】:
【来  源】:http://www.cublog.cn/u/22266/showart.php?id=255774

端口限速配置

2950端口限速配置
Step 1 access-list 1 permit 172.20.10.16
Step 2 class-map videoclass
Step 3 match access-group 1
Step 4 exit
Step 5 policy-map
Step 6 class videoclass
Step 7 police 5000000 8192 exceed-action drop .
Step 8 exit
Step 9 exit
Step 10 interface gigabitethernet0/1
Step 11 service-policy input videopolicy
Step 12 exit
一台2950交换机,要对第二个端口限速,第一个端口是上联交换机端口。
配置如下:
class-map match-all 3M
match access-group 101
!
!
policy-map test
class 3M
police 3000000 32768 exceed-action drop
!
ip subnet-zero
!
spanning-tree extend system-id
!
!
interface FastEthernet0/1
no ip address
!
interface FastEthernet0/2
switchport mode access
no ip address
service-policy input test
!
interface FastEthernet0/3
no ip address
!!
interface Vlan1
no ip route-cache
!
access-list 101 permit ip any any
发现只在第二端口做策略限速不成功,后来在第一个端口也做了数据后限速成功了,请问这是什么原因?
做策略 可以给每个单口一个策略,
if)service-policy input/out name
config)class-map match-all map-name
match xxx
config)policy-map name
class map-name
police cir xxxx
 
 
2621限速配置
 1. 在全局模式下开启cef:
    Router(config)#ip cef
    2. 定义标准或者扩展访问列表:
    Router(config)#access-list 2 permit 192.168.6.0 0.0.0.255
    3. 在希望限制的端口上进行rate-limit:
    Rounter(config-if)#rate-limit output access-group 2 128000 16000 16000 conform-action transmit exceed-action drop
    这样我们就对192.168.6.0网段进行了限速,速率为128kbps。
    下面,重点介绍一下rate-limit的命令格式:
    #rate-limit {input|output} [access-group number] bps burst-normal burst-max conform-action action exceed-action action
    input|output:这是定义数据流量的方向。
    access-group number:定义的访问列表的号码。
    bps:定义流量速率的上限,单位是bps。
    burst-normal burst-max:定义的数据容量的大小,一般采用8000,16000,32000,单位是字节,当到达的数据超过此容量时,将触发某个动作,丢弃或转发等,从而达到限速的目的。
    conform-action和exceed-action:分别指在速率限制以下的流量和超过速率限制的流量的处理策略。
    action:是处理策略,包括drop和transmit等。
ip cef
access 2 permit x.x.x.3 0.0.0.0
int f0/1
rate-limit output access-group 2 2048000 256000 256000 conform-action transmit exceed-action drop
 
VLAN基本配置命令(搜集整理)0309:【上一篇】
SU使用笔记及安装:【下一篇】
【相关文章】
没有相关文章
【随机文章】
  • 用as设计计算器,按照运算法则运算
  • Symfony简介
  • MySQL使用和管理
  • 网络新威胁 无线局域网入侵检测现状和要点
  • 世纪葵花--桌面直播录像机系统5.2
  • 3dmax6.0--Gul3d for max 水的制作教程
  • 二叉树遍历算法实现(C#2.0)
  • TDosMove v1.02 (替代TAB移动)
  • SCO Unix 制作系统应急盘“Out of inodes”错误的处理
  • Google编程大赛解题一道
  • 【相关评论】
    没有相关评论
    【发表评论】
    姓名:
    邮件:
    随机码*
    评论*
          
    |  首 页  |  版权声明  |  联系我们   |  网站地图  |
    CopyRight © 2004-2007 软讯网络 All Rigths Reserved.