分享
 
 
 

Traffic Engineering with MPLS

王朝other·作者佚名  2008-05-31
窄屏简体版  字體: |||超大  

Modular QoS CLI 有以下三种形式:

Class map—How you define what traffic you're interested in

Policy map—What you do to the traffic defined in a class map

Service policy—How you enable a policy map on an interface

定义Class Map

The first step in using MQC is to build a class map. Not surprisingly, you do this with the class-map command:

vxr12(config)#class-map ?

Word class-map name

match-all Logical-AND all matching statements under this classmap

match-any Logical-OR all matching statements under this classmapm

The match-all and match-any keywords let you specify whether traffic matches this class, if it matches all the rules in this class or any of them, respectively. The default is match-all.

You create a class by giving it a name. This puts you in a submode called config-cmap:

vxr12(config)#class-map voice

vxr12(config-cmap)#?

QoS class-map configuration commands:

description Class-Map description

exit Exit from QoS class-map configuration mode

match classification criteria

no Negate or set default values of a command

rename Rename this class-mapm

The most useful option under config-cmap is match, which lets you define the traffic you want to match with this class map. Its options are as follows:

vxr12(config-cmap)#match ?

Access-group Access group

any Any packets

class-map Class map

cos IEEE 802.1Q/ISL class of service/user priority values

destination-address Destination address

fr-de Match on Frame-relay DE bit

input-interface Select an input interface to match

ip IP specific values

mpls Multi Protocol Label Switching specific values

not Negate this match result

protocol Protocol

qos-group Qos-group

source-address Source addressm

举例

class-map match-all voice

match mpls eXPerimental 5

policy-map llq

class voice

priority percent 30

This defines a class that matches any MPLS traffic that has the EXP bits set to 5 and then defines a policy for that traffic that gives the traffic 30 percent of a link's bandwidth. The policy map hasn't been enabled on an interface yet; you'll see that in a minute.

You can match multiple values with the same line using the following command sequence:

class-map match-any bronze-service

match mpls experimental 0 1

This matches any packets that have an MPLS EXP of 0 or 1. As with route maps, multiple values specified within the same match clause (sUCh as match mpls experimental 0 1) are implicitly ORed together; a packet can't have both EXP 0 and EXP 1, so this implicit ORing makes sense.

You can also match more than one criteria within a class, and you can use the match-any and match-all statements to decide how you want to match traffic. For example, the following policy matches traffic that has MPLS EXP 5 or traffic that entered the router on interface POS3/0:

class-map match-any gold

match mpls experimental 5

match input-interface POS3/0

The following policy matches any traffic that has MPLS EXP 5 and that came in on interface POS3/0:

class-map match-all gold

match mpls experimental 5

match input-interface POS3/0

vxr12#show class-map

Class Map match-all gold (id 2)

Match mpls experimental 5

Match input-interface POS3/0

Class Map match-any class-default (id 0)

Match any

Class Map match-all voice (id 3)

Match mpls experimental 5

Policy Map

After you define the class maps you want to match, you need to associate the class of traffic with a behavior. You create the behavior with the policy-map command, which, like class-map, puts you in a special submode:

vxr12(config)#policy-map ?

WORD policy-map name

vxr12(config)#policy-map llq

vxr12(config-pmap)#?

QoS policy-map configuration commands:

class policy criteria

description Policy-Map description

exit Exit from QoS policy-map configuration mode

no Negate or set default values of a command

rename Rename this policy-map

Under the config-pmap submode, you specify the class you want to match. This puts you in the config-pmap-c submode:

vxr12(config)#policy-map llq

vxr12(config-pmap)#class voice

vxr12(config-pmap-c)#?

QoS policy-map class configuration commands:

bandwidth Bandwidth

exit Exit from QoS class action configuration mode

no Negate or set default values of a command

police Police

priority Strict Scheduling Priority for this Class

queue-limit Queue Max Threshold for Tail Drop

random-detect Enable Random Early Detection as drop policy

service-policy Configure QoS Service Policy

set Set QoS values

shape Traffic Shaping

class-map match-any voice

match mpls experimental 5

policy-map llq

class voice

priority percent 30

class-map match-all business

match mpls experimental 3 4

class-map match-all voice

match mpls experimental 5

policy-map business-and-voice

class voice

priority percent 30

class business

bandwidth percent 60

class class-default

bandwidth percent 10

Service Policy

vxr12(config-if)#service-policy ?

history Keep history of QoS metrics

input Assign policy-map to the input of an interface

output Assign policy-map to the output of an interface

vxr12(config-if)#service-policy out

vxr12(config-if)#service-policy output ?

WORD policy-map name

vxr12(config-if)#service-policy output llq

##############################

vxr12#show policy-map interface pos3/0

POS3/0

Service-policy output: llq

Class-map: voice (match-all)

0 packets, 0 bytes

5 minute offered rate 0 bps, drop rate 0 bps

Match: mpls experimental 5

Weighted Fair Queuing

Strict Priority

Output Queue: Conversation 264

Bandwidth 30 (%)

Bandwidth 46500 (kbps) Burst 1162500 (Bytes)

(pkts matched/bytes matched) 0/0

(total drops/bytes drops) 0/0

Class-map: class-default (match-any)

21 packets, 15744 bytes

5 minute offered rate 3000 bps, drop rate 0 bps

Match: any

 
 
 
免责声明:本文为网络用户发布,其观点仅代表作者个人观点,与本站无关,本站仅提供信息存储服务。文中陈述内容未经本站证实,其真实性、完整性、及时性本站不作任何保证或承诺,请读者仅作参考,并请自行核实相关内容。
2023年上半年GDP全球前十五强
 百态   2023-10-24
美众议院议长启动对拜登的弹劾调查
 百态   2023-09-13
上海、济南、武汉等多地出现不明坠落物
 探索   2023-09-06
印度或要将国名改为“巴拉特”
 百态   2023-09-06
男子为女友送行,买票不登机被捕
 百态   2023-08-20
手机地震预警功能怎么开?
 干货   2023-08-06
女子4年卖2套房花700多万做美容:不但没变美脸,面部还出现变形
 百态   2023-08-04
住户一楼被水淹 还冲来8头猪
 百态   2023-07-31
女子体内爬出大量瓜子状活虫
 百态   2023-07-25
地球连续35年收到神秘规律性信号,网友:不要回答!
 探索   2023-07-21
全球镓价格本周大涨27%
 探索   2023-07-09
钱都流向了那些不缺钱的人,苦都留给了能吃苦的人
 探索   2023-07-02
倩女手游刀客魅者强控制(强混乱强眩晕强睡眠)和对应控制抗性的关系
 百态   2020-08-20
美国5月9日最新疫情:美国确诊人数突破131万
 百态   2020-05-09
荷兰政府宣布将集体辞职
 干货   2020-04-30
倩女幽魂手游师徒任务情义春秋猜成语答案逍遥观:鹏程万里
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案神机营:射石饮羽
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案昆仑山:拔刀相助
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案天工阁:鬼斧神工
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案丝路古道:单枪匹马
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案镇郊荒野:与虎谋皮
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案镇郊荒野:李代桃僵
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案镇郊荒野:指鹿为马
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案金陵:小鸟依人
 干货   2019-11-12
倩女幽魂手游师徒任务情义春秋猜成语答案金陵:千金买邻
 干货   2019-11-12
 
推荐阅读
 
 
 
>>返回首頁<<
 
靜靜地坐在廢墟上,四周的荒凉一望無際,忽然覺得,淒涼也很美
© 2005- 王朝網路 版權所有