例1:
class-map c1
match input-interface g0/1----匹配g0/1进入的流量
policy-map p1
class c1
bandwidth 20000
inter g0/0
service-policy output p1-----该流量从g0/0接口出去分配20000kbps带宽。
例2:
switch上的配置QOS:
inter range fa0/1-5
mls qos cos 1-----所有未打标签的数据帧打为cos 1
msl qos trust cos-----信任所有打了标签的数据帧
mls qos
mls qos srr-queue input threshold 1 40 100-----队列1 第1个阀值为40.第2个阀值为100
mls qos srr-queue input cos-map queue 1 threshold 3 5----cos=3,5放在队列1中,使用阀值1
mls qos srr-queue input buffers 100 0-----队列1的buffer设置为100% 队列2的buffer设置为0%
inter fa0/19-24
mls qos trust cos