基于IP 的QoS 配置举例。

使class ip-range1 内的每个IP 地址都有最多2M带宽,class ip-range2 中的所有IP 地址共享10M 带宽。

第一步:配置class:
hostname(config)# class-map ip-range1
hostname(config-class-map)# match ip-range 2.2.0.0 2.2.10.255
hostname(config-class-map)# exit
hostname(config)# class-map ip-range2
hostname(config-class-map)# match ip-range 192.168.100.200 192.168.100.200
hostname(config-class-map)# exit
hostname(config)#

第二步:配置QoS Profile:
hostname(config)# qos-profile profile1
hostname(config-qos-profile)# class ip-range1
hostname(config-qos-prof-cmap)# ip-qos per-ip max-bandwidth 2000
hostname(config-qos-prof-cmap)# exit
hostname(config-qos-profile)# class ip-range2
hostname(config-qos-prof-cmap)# match-priority 3
hostname(config-qos-prof-cmap)# ip-qos shared-bandwidth max-bandwidth 10000
hostname(config-qos-prof-cmap)# exit
hostname(config-qos-profile)# exit
hostname(config)#

第三步:绑定QoS Profile 到接口:
hostname(config)# interface ethernet0/2
hostname(config-if-eth0/2)# qos-profile input profile1
hostname(config-if-eth0/2)# qos-profile output profile1
hostname(config-if-eth0/2)# exit
hostname(config)#

原创文章如转载,请注明:
转载自醉生梦死的博客
原文地址:http://www.liusuping.com/post/hillstone-qos-ip-base.html