大家好,今天,教大家如何使用流策略实现流行为控制。
流行为流分类
理论:
现在进一步记录策略路由的流应用
配置策略路由可以将到达接口的三层报文重定向到指定的下一跳地址
通过配置重定向,设备将符合流分类规则的报文重定向到指定的下一跳地址。包含重定向动作的流策略只能在全局、接口或VLAN的入方向上应用。
配置策略路由前任务
在配置策略路由前,需要配置相关接口的ip地址和路由协议,保证路由互通。
操作步骤
1、配置acl
2、配置流分类
[Huawei]traffic classifier c1
[Huawei-classifier-c1]if-match acl 3001
3、配置流行为
[Huawei]traffic behavior b1
[Huawei-behavior-b1]redirect ip-nexthop x.x.x.x
当存在多个下一跳时,设备按照主备方式对报文进行重定向转发。一个流行为中最多可以配置4个下一跳,设备根据下一跳的配置顺序确定主备链路,先配置的下一跳IP地址优先级较高。配置的第一个下一跳IP地址作为主用链路,其他链路作为备用链路。当主用链路Down之后,则主动选取优先级高的下一跳作为新的主链路;当原主用链路恢复正常以后,流量再回切至原主用链路。
4、配置流策略
traffic policy p
classifier jiaoxue behavior xxxxx
一、实验目的
- 掌握配置端到端QoS的方法
- 掌握使用流策略实现流行为控制的方法
二、实验拓扑
三、实验场景
你是公司的网络管理员。公司网络分成两部分,其中R1与S1在公司总部,R2与S2在公司分部,之间通过专线实现互联。随着网络的发展,内网带宽逐渐增大,而专线的带宽一直没有升级,所以网络中出现了比较严重的重要业务反应较慢,或无法正常使用的情况。
部署端到端QoS,你可以调整相应的QoS特性,保证重要的业务数据能更好的发送到目标,并通过流策略实现对流行为的控制。
四、实验步骤
4.1 步骤一. 基础配置与 IP 编址
给所有路由器和交换机S3,S4配置IP地址和掩码。
R1
<R1>system-view Entersystemview,returnuserviewwithCtrl+Z. [R1]interfaceSerial1/0/0 [R1-Serial1/0/0]ipaddress10.0.12.1255.255.255.0 [R1-Serial1/0/0]quit [R1]interfaceGigabitEthernet0/0/1 [R1-GigabitEthernet0/0/1]ip address10.0.145.1255.255.255.0
R2
<R2>system-view Entersystemview,returnuserviewwithCtrl+Z. [R2]interfaceSerial1/0/0 [R2-Serial1/0/0]ipaddress10.0.12.2255.255.255.0 [R2-Serial1/0/0]quit [R2]interfaceGigabitEthernet0/0/2 [R2-GigabitEthernet0/0/2]ip address10.0.34.2255.255.255.0
R3
<R3>system-view Entersystemview,returnuserviewwithCtrl+Z. [R3]interfaceGigabitEthernet0/0/2 [R3-GigabitEthernet0/0/2]ip address10.0.34.3255.255.255.0
R4
<R4>system-view Entersystemview,returnuserviewwithCtrl+Z. [R4]interfaceGigabitEthernet0/0/1 [R4-GigabitEthernet0/0/1]ip address10.0.145.4255.255.255.0
R5
<R5>system-view Entersystemview,returnuserviewwithCtrl+Z. [R5]interfaceGigabitEthernet0/0/1 [R5-GigabitEthernet0/0/1]ip address10.0.145.5255.255.255.0
S3
<S3>system-view Entersystemview,returnuserviewwithCtrl+Z. [S3]interface Vlanif1 [S3-Vlanif1]ipa ddress10.0.145.3255.255.255.0
S4
<S4>system-view Entersystemview,returnuserviewwithCtrl+Z. [S4]interfaceVlanif1 [S4-Vlanif1]ip address 10.0.34.4255.255.255.0
配置完成后,测试直连链路的连通性。
R1 ping R2
[R1]ping-c110.0.12.2 PING10.0.12.2:56databytes,pressCTRL_Ctobreak Replyfrom10.0.12.2:bytes=56Sequence=1ttl=255time=36ms ---10.0.12.2pingstatistics--- 1packet(s)transmitted 1packet(s)received 0.00%packetloss round-tripmin/avg/max=36/36/36ms
R1 ping S3
[R1]ping-c110.0.145.3 PING10.0.145.3:56databytes,pressCTRL_Ctobreak Replyfrom10.0.145.3:bytes=56Sequence=1ttl=255time=35ms ---10.0.145.3pingstatistics--- 1packet(s)transmitted 1packet(s)received 0.00%packetloss round-tripmin/avg/max=35/35/35ms
R1 ping R4
[R1]ping-c110.0.145.4 PING10.0.145.4:56databytes,pressCTRL_Ctobreak Replyfrom10.0.145.4:bytes=56Sequence=1ttl=255time=6ms ---10.0.145.4pingstatistics--- 1packet(s)transmitted 1packet(s)received 0.00%packetloss round-tripmin/avg/max=6/6/6ms
R1 ping R5
[R1]ping-c110.0.145.5 PING10.0.145.5:56databytes,pressCTRL_Ctobreak Replyfrom10.0.145.5:bytes=56Sequence=1ttl=255time=6ms ---10.0.145.5pingstatistics--- 1packet(s)transmitted 1packet(s)received 0.00%packetloss round-tripmin/avg/max=6/6/6ms
R2 ping R3
[R2]ping-c110.0.34.3 PING10.0.34.3:56databytes,pressCTRL_Ctobreak Replyfrom10.0.34.3:bytes=56Sequence=1ttl=255time=5ms ---10.0.34.3pingstatistics--- 1packet(s)transmitted 1packet(s)received 0.00%packetloss round-tripmin/avg/max=5/5/5ms
R2 ping S4
[R2]ping-c110.0.34.4 PING10.0.34.4:56databytes,pressCTRL_Ctobreak Replyfrom10.0.34.4:bytes=56Sequence=1ttl=255time=36ms ---10.0.34.4pingstatistics--- 1packet(s)transmitted 1packet(s)received 0.00%packetloss round-tripmin/avg/max=36/36/36ms
4.2 步骤二. 配置静态路由
在所有路由器和交换机S3,S4上配置静态路由。
[R1]iproute-static10.0.34.0255.255.255.010.0.12.2 [R2]iproute-static10.0.145.0255.255.255.010.0.12.1 [R3]iproute-static0.0.0.00.0.0.010.0.34.2 [R4]iproute-static0.0.0.00.0.0.010.0.145.1 [R5]iproute-static0.0.0.00.0.0.010.0.145.1 [S3]iproute-static0.0.0.00.0.0.010.0.145.1 [S4]iproute-static0.0.0.00.0.0.010.0.34.2
配置完成后,测试网络连通性。
S3
[S3]ping-c110.0.34.4 PING10.0.34.4:56databytes,pressCTRL_Ctobreak Replyfrom10.0.34.4:bytes=56Sequence=1ttl=252time=40ms ---10.0.34.4pingstatistics--- 1packet(s)transmitted 1packet(s)received 0.00%packetloss round-tripmin/avg/max=40/40/40ms
R4
[R4]ping-c110.0.34.3 PING10.0.145.4:56databytes,pressCTRL_Ctobreak Replyfrom10.0.145.4:bytes=56Sequence=1ttl=255time=3ms ---10.0.145.4pingstatistics--- 1packet(s)transmitted 1packet(s)received 0.00%packetloss round-tripmin/avg/max=3/3/3ms
R5
[R5]ping-c110.0.34.3 PING10.0.34.3:56databytes,pressCTRL_Ctobreak Replyfrom10.0.34.3:bytes=56Sequence=1ttl=253time=44ms ---10.0.34.3pingstatistics--- 1packet(s)transmitted 1packet(s)received 0.00%packetloss round-tripmin/avg/max=44/44/44ms
4.3 步骤三. 配置 DSCP 优先级的重标记
公司网络中有语音,视频,数据三种业务,但是由于公司总部与分部之间的专线仍然没有得到升级,所以网络不可避免的出现了拥塞。
通过配置端到端的QoS来实现语音报文的优先发送,视频报文的带宽保证。
将R4与R3之间的流量模拟为语音报文,将R5与R3之间的流量模拟为视频报文,将S3与S4之间的报文模拟为数据报文。接下来将针对语音报文和视频报文做一系列相关的QoS策略,对数据报文采用默认的尽力而为的传输。
现在将语音报文的DSCP值标记为EF,视频报文的DSCP值标记为AF32。
在S1上创建ACL3001,3002,分别匹配R4去往R3,R5去往R3的流量。
[S1]aclnumber3001 [S1-acl-adv-3001]rule0permitipsource10.0.145.40destination10.0.34.30 [S1-acl-adv-3001]quit [S1]aclnumber3002 [S1-acl-adv-3002]rule0permitipsource10.0.145.50destination10.0.34.30
在S1上创建流分类class-voice-s1,匹配ACL3001。创建流行为behavior-voice-s1,将DSCP优先级重标记为EF。
创建流策略policy-voice-s1,关联流分类class-voice-s1与流行为behavior-voice-s1,在S1上的G0/0/4接口入方向上调用该流策略。
[S1]trafficclassifierclass-voice-s1 [S1-classifier-class-voice-s1]if-matchacl3001 [S1-classifier-class-voice-s1]quit [S1]trafficbehaviorbehavior-voice-s1 [S1-behavior-behavior-voice-s1]remarkdscpef [S1-behavior-behavior-voice-s1]quit [S1]trafficpolicypolicy-voice-s1 [S1-trafficpolicy-policy-voice-s1]classifierclass-voice-s1behaviorbehavior-voice-s1 [S1-trafficpolicy-policy-voice-s1]quit [S1]interfaceGigabitEthernet0/0/4 [S1-GigabitEthernet0/0/4]traffic-policypolicy-voice-s1inbound
在S1上创建流分类class-video-s1,匹配ACL3002。创建流行为behavior-video-s1,将DSCP优先级重标记为AF32。
创建流策略policy-video-s1,关联流分类class-video-s1与流行为behavior-video-s1,在S1上的G0/0/5接口入方向上应用该流策略。
[S1]trafficclassifierclass-video-s1 [S1-classifier-class-video-s1]if-matchacl3002 [S1-classifier-class-video-s1]quit [S1]trafficbehaviorbehavior-video-s1 [S1-behavior-behavior-video-s1]remarkdscpaf32 [S1-behavior-behavior-video-s1]quit [S1]trafficpolicypolicy-video-s1 [S1-trafficpolicy-policy-video-s1]classifierclass-video-s1behaviorbehavior-video-s1 [S1-trafficpolicy-policy-video-s1]quit [S1]interfaceGigabitEthernet0/0/5 [S1-GigabitEthernet0/0/5]traffic-policypolicy-video-s1inbound
在S2上创建ACL3001,3002,分别匹配R3去往R4,R3去往R5的流量。
[S2]aclnumber3001 [S2-acl-adv-3001]rule0permitipsource10.0.34.30destination10.0.145.40 [S2-acl-adv-3001]quit [S2]aclnumber3002 [S2-acl-adv-3002]rule0permitipsource10.0.34.30destination10.0.145.50
在S2上创建流分类class-voice-s2,匹配ACL3001。创建流行为behavior-voice-s2,将DSCP优先级重标记为EF。
[S2]trafficclassifierclass-voice-s2 [S2-classifier-class-voice-s2]if-matchacl3001 [S2-classifier-class-voice-s2]quit [S2]trafficbehaviorbehavior-voice-s2 [S2-behavior-behavior-voice-s2]remarkdscpef
在S2上创建流分类class-video-s2,匹配ACL3002。创建流行为behavior-video-s2,将DSCP优先级重标记为AF32。
[S2]trafficclassifierclass-video-s2 [S2-classifier-class-video-s2]if-matchacl3002 [S2-classifier-class-video-s2]quit [S2]trafficbehaviorbehavior-video-s2 [S2-behavior-behavior-video-s2]remarkdscpaf32
在S2上创建流策略policy-voice-video-s2,关联流分类class-voice-s2与流行为behavior-voice-s2,关联流分类class-video-s2与流行为behavior-video-s2,在S2上的G0/0/3接口入方向上应用该流策略。
[S2]trafficpolicypolicy-voice-video-s2 [S2-trafficpolicy-policy-voice-video-s2]classifierclass-voice-s2behaviorbehavior-voice-s2 [S2-trafficpolicy-policy-voice-video-s2]classifierclass-video-s2behaviorbehavior-video-s2 [S2-trafficpolicy-policy-voice-video-s2]quit [S2]interfaceGigabitEthernet0/0/3 [S2-GigabitEthernet0/0/3]traffic-policypolicy-voice-video-s2inbound
4.4 步骤四. 配置流量整形和监管
在公司总部和分部的核心交换机上部署流量整形,缓解流量拥塞的问题。
在S1上的接口G0/0/1出方向上配置流量整形,CIR设为128kbit/s。
[S1]interfaceGigabitEthernet0/0/1 [S1-GigabitEthernet0/0/1]qoslroutboundcir128
查看流量整形配置信息。
[S1]displayqoslroutboundinterfaceGigabitEthernet0/0/1 GigabitEthernet0/0/1lroutbound: cir:128Kbps,cbs:16000Byte
在S2上的接口G0/0/2出方向上配置流量整形,CIR设为128kbit/s。
[S2]interfaceGigabitEthernet0/0/2 [S2-GigabitEthernet0/0/2]qoslroutboundcir128
查看流量整形配置信息。
[S2]displayqoslroutboundinterfaceGigabitEthernet0/0/2 GigabitEthernet0/0/2lroutbound: cir:128Kbps,cbs:16000Byte
在公司总部和分部的出口路由器上部署流量监管,进一步缓解流量拥塞的问题。
在R1上的G0/0/1接口入方向上配置流量监管,CIR设为72kbit/s。
[R1]interfaceGigabitEthernet0/0/1 [R1-GigabitEthernet0/0/1]qoscarinboundcir72
在R2上的G0/0/2接口入方向上配置流量监管,CIR设为72kbit/s。
[R2]interfaceGigabitEthernet0/0/2 [R2-GigabitEthernet0/0/2]qoscarinboundcir72
4.5 步骤五. 配置基于流策略的拥塞管理与拥塞避免
在公司总部与分部的出口路由器上部署基于流策略的拥塞管理与拥塞避免。
保证语音流量低延迟,优先发送,保证视频流量拥有足够的带宽。
配置R1上的G0/0/1接口配置信任DSCP优先级。
[R1]interfaceGigabitEthernet0/0/1 [R1-GigabitEthernet0/0/1]trustdscp
在R1上创建WRED丢弃模板video-r1,使其基于DSCP优先级进行丢弃,将阀值下限设为50,上限设为90,丢弃概率设为30。
[R1]drop-profilevideo-r1 [R1-drop-profile-video-r1]wreddscp [R1-drop-profile-video-r1]dscpaf32low-limit50high-limit90discard-percentage30
在R1上创建流分类class-af32-r1,匹配DSCP值为AF32的视频流量。创建流行为behavior-af32-r1,配置队列调度方式为AF,最大带宽占接口带宽百分比设为40,并与丢弃模板video-r1绑定。
[R1]trafficclassifierclass-af32-r1 [R1-classifier-class-af32-r1]if-matchdscpaf32 [R1-classifier-class-af32-r1]quit [R1]trafficbehaviorbehavior-af32-r1 [R1-behavior-behavior-af32-r1]queueafbandwidthpct40 [R1-behavior-behavior-af32-r1]drop-profilevideo-r1
在R1上创建流分类class-ef-r1,匹配DSCP值为EF的语音流量。创建流行为behavior-ef-r1,配置队列的调度方式为EF,最大带宽占接口带宽百分比设为30。
[R1]trafficclassifierclass-ef-r1 [R1-classifier-class-ef-r1]if-matchdscpef [R1-classifier-class-ef-r1]quit [R1]trafficbehaviorbehavior-ef-r1 [R1-behavior-behavior-ef-r1]queueefbandwidthpct30
在R1上创建流策略policy-r1,关联流分类class-af32-r1与流行为behavior-af32-r1,关联流分类class-ef-r1与流行为behavior-ef-r1,并在R1上的S1/0/0接口出方向上应用。
[R1]trafficpolicypolicy-r1 [R1-trafficpolicy-policy-r1]classifierclass-af32-r1behaviorbehavior-af32-r1 [R1-trafficpolicy-policy-r1]classifierclass-ef-r1behaviorbehavior-ef-r1 [R1-trafficpolicy-policy-r1]quit [R1]interfaceSerial1/0/0 [R1-Serial1/0/0]traffic-policypolicy-r1outbound
在公司总部R1上配置完后,在公司分部R2上也作相应配置。
配置R2上的G0/0/2接口配置信任DSCP优先级。
[R2]interfaceGigabitEthernet0/0/2 [R2-GigabitEthernet0/0/2]trustdscp
在R2上创建WRED丢弃模板video-r2,使其基于DSCP优先级进行丢弃,将阀值下限设为50,上限设为90,丢弃概率设为30。
[R2]drop-profilevideo-r2 [R2-drop-profile-video-r2]wreddscp [R2-drop-profile-video-r2]dscpaf32low-limit50high-limit90discard-percentage30
在R1上创建流分类class-af32-r2,匹配DSCP值为AF32的视频流量。创建流行为behavior-af32-r2,配置队列调度方式为AF,最大带宽占接口带宽百分比设为40,并与丢弃模板video-r2绑定。
[R2]trafficclassifierclass-af32-r2 [R2-classifier-class-af32-r2]if-matchdscpaf32 [R2-classifier-class-af32-r2]quit [R2]trafficbehaviorbehavior-af32-r2 [R2-behavior-behavior-af32-r2]queueafbandwidthpct40 [R2-behavior-behavior-af32-r2]drop-profilevideo-r2
在R1上创建流分类class-ef-r2,匹配DSCP值为EF的语音流量。创建流行为behavior-ef-r2,配置队列的调度方式为EF,最大带宽占接口带宽百分比设为30。
[R2]trafficclassifierclass-ef-r2 [R2-classifier-class-ef-r2]if-matchdscpef [R2-classifier-class-ef-r2]quit [R2]trafficbehaviorbehavior-ef-r2 [R2-behavior-behavior-ef-r2]queueefbandwidthpct30
在R1上创建流策略policy-r2,关联流分类class-af32-r2与流行为behavior-af32-r2,关联流分类class-ef-r2与流行为behavior-ef-r2,并在R2上的S1/0/0接口出方向上应用。
[R2]trafficpolicypolicy-r2 [R2-trafficpolicy-policy-r2]classifierclass-af32-r2behaviorbehavior-af32-r2 [R2-trafficpolicy-policy-r2]classifierclass-ef-r2behaviorbehavior-ef-r2 [R2]interfaceSerial1/0/0 [R2-Serial1/0/0]traffic-policypolicy-r2outbound
4.6 步骤六. 配置基于流策略实现流行为控制
公司总部现在出于优化的的目的将针对部分流量做控制,丢弃掉UDP端口号范围为4000至5000的部分视频流量。
在R1上创建ACL3003,匹配从R5去往R3 UDP端口范围为4000至5000的部分流量。
[R1]aclnumber3003 [R1-acl-adv-3003]rule0permitudpsource-portrange40005000source10.0.145.50destination 10.0.34.30
在R1上创建流分类class-drop,匹配ACL3003。
[R1]trafficclassifierclass-drop [R1-classifier-class-drop]if-matchacl3003
在R1上创建流行为behavior-drop,配置命令deny,执行禁止动作。
[R1]trafficbehaviorbehavior-drop [R1-behavior-behavior-drop]deny
在R1上创建流策略policy-drop,关联流分类class-drop与流行为behavior-drop,并在接口G0/0/5的入方向上应用。
[R1]trafficpolicypolicy-drop [R1-trafficpolicy-policy-drop]classifierclass-dropbehaviorbehavior-drop [R1-trafficpolicy-policy-drop]quit [R1]interfaceGigabitEthernet0/0/1 [R1-GigabitEthernet0/0/1]traffic-policypolicy-dropinbound
查看配置信息。
[R1]displaytrafficpolicyuser-definedpolicy-drop UserDefinedTrafficPolicyInformation: Policy:policy-drop Classifier:class-drop Operator:OR Behavior:behavior-drop Deny
五、附加实验: 思考并验证
实验完成后,回顾QoS的知识框架,总结QoS中各项策略的使用范围与应用场景。
六、最终设备配置
R1
<R1>displaycurrent-configuration [V200R007C00SPC600] # sysnameR1 # aclnumber3003 rule0permitudpsource10.0.145.50source-portrange40005000destination10.0.34.30 # drop-profilevideo-r1 wreddscp dscpaf32low-limit50high-limit90discard-percentage30 # trafficclassifierclass-dropoperatoror if-matchacl3003 trafficclassifierclass-ef-r1operatoror if-matchdscpef trafficclassifierclass-af32-r1operatoror if-matchdscpaf32 # trafficbehaviorbehavior-af32-r1 queueafbandwidthpct40 drop-profilevideo-r1 trafficbehaviorbehavior-ef-r1 queueefbandwidthpct30 trafficbehaviorbehavior-drop deny # trafficpolicypolicy-drop classifierclass-dropbehaviorbehavior-drop trafficpolicypolicy-r1 classifierclass-af32-r1behaviorbehavior-af32-r1 classifierclass-ef-r1behaviorbehavior-ef-r1 # interfaceSerial1/0/0 link-protocolppp ipaddress10.0.12.1255.255.255.0 traffic-policypolicy-r1outbound # interfaceGigabitEthernet0/0/1 ipaddress10.0.145.1255.255.255.0 trustdscp qoscarinboundcir72cbs13536pbs22536greenpassyellowpassreddiscard traffic-policypolicy-dropinbound # iproute-static10.0.34.0255.255.255.010.0.12.2 # return
R2
<R2>displaycurrent-configuration [V200R007C00SPC600] # sysnameR2 # drop-profilevideo-r2 wreddscp dscpaf32low-limit50high-limit90discard-percentage30 # trafficclassifierclass-ef-r2operatoror if-matchdscpef trafficclassifierclass-af32-r2operatoror if-matchdscpaf32 # trafficbehaviorbehavior-af32-r2 queueafbandwidthpct40 drop-profilevideo-r2 trafficbehaviorbehavior-ef-r2 queueefbandwidthpct30 # trafficpolicypolicy-r2 classifierclass-af32-r2behaviorbehavior-af32-r2 classifierclass-ef-r2behaviorbehavior-ef-r2 # interfaceSerial1/0/0 link-protocolppp ipaddress10.0.12.2255.255.255.0 traffic-policypolicy-r2outbound # interfaceGigabitEthernet0/0/2 ipaddress10.0.34.2255.255.255.0 trustdscp qoscarinboundcir72cbs13536pbs22536greenpassyellowpassreddiscard # iproute-static10.0.145.0255.255.255.010.0.12.1 # return
R3
<R3>displaycurrent-configuration [V200R007C00SPC600] # sysnameR3 # interfaceGigabitEthernet0/0/2 ipaddress10.0.34.3255.255.255.0 # iproute-static0.0.0.00.0.0.010.0.34.2 # return
R4
<R4>displaycurrent-configuration [V200R007C00SPC600] # sysnameR4 # interfaceGigabitEthernet0/0/1 ipaddress10.0.145.4255.255.255.0 # iproute-static0.0.0.00.0.0.010.0.145.1 # return
R5
<R5>displaycurrent-configuration [V200R007C00SPC600] # sysnameR5 # interfaceGigabitEthernet0/0/1 ipaddress10.0.145.5255.255.255.0 # iproute-static0.0.0.00.0.0.010.0.145.1 # return
S1
<S1>displaycurrent-configuration # !SoftwareVersionV200R008C00SPC500 sysnameS1 # aclnumber3001 rule0permitipsource10.0.145.40destination10.0.34.30 aclnumber3002 rule0permitipsource10.0.145.50destination10.0.34.30 # trafficclassifierclass-video-s1operatorand if-matchacl3002 trafficclassifierclass-voice-s1operatorand if-matchacl3001 # trafficbehaviorbehavior-video-s1 remarkdscpaf32 trafficbehaviorbehavior-voice-s1 remarkdscpef # trafficpolicypolicy-video-s1 classifierclass-video-s1behaviorbehavior-video-s1 trafficpolicypolicy-voice-s1 classifierclass-voice-s1behaviorbehavior-voice-s1 # interfaceGigabitEthernet0/0/1 qoslroutboundcir128cbs16000 # interfaceGigabitEthernet0/0/4 traffic-policypolicy-voice-s1inbound # interfaceGigabitEthernet0/0/5 traffic-policypolicy-video-s1inbound # return
S2
<S2>displaycurrent-configuration # !SoftwareVersionV200R008C00SPC500 sysnameS2 # aclnumber3001 rule0permitipsource10.0.34.30destination10.0.145.40 aclnumber3002 rule0permitipsource10.0.34.30destination10.0.145.50 # trafficclassifierclass-video-s2operatorand if-matchacl3002 trafficclassifierclass-voice-s2operatorand if-matchacl3001 # trafficbehaviorbehavior-video-s2 remarkdscpaf32 trafficbehaviorbehavior-voice-s2 remarkdscpef # trafficpolicypolicy-voice-video-s2 classifierclass-voice-s2behaviorbehavior-voice-s2 classifierclass-video-s2behaviorbehavior-video-s2 # interfaceGigabitEthernet0/0/2 qoslroutboundcir128cbs16000 # interfaceGigabitEthernet0/0/3 traffic-policypolicy-voice-video-s2inbound # return
S3
<S3>displaycurrent-configuration # !SoftwareVersionV200R008C00SPC500 sysnameS3 # interfaceVlanif1 ipaddress10.0.145.3255.255.255.0 # iproute-static0.0.0.00.0.0.010.0.145.1 # return
S4
<S4>displaycurrent-configuration # !SoftwareVersionV200R008C00SPC500 sysnameS4 # interfaceVlanif1 ipaddress10.0.34.4255.255.255.0 # iproute-static0.0.0.00.0.0.010.0.34.2 # return
至此本文结束,大家可以根据此文一步一步完成实验!