class-map

更新时间:2023-06-06 16:58:12 阅读: 评论:0

R1#sho run   
Current configuration : 1397 bytes
!
version 12.4
rvice timestamps debug datetime mc
rvice timestamps log datetime mc
no rvice password-encryption
!
hostname R1
!
boot-start-marker
boot-end-marker
!
!
桂花糯米藕的做法no aaa new-model
memory-size iomem 5
!
!
ip cef
no ip domain lookup
!
!
!
!       
!
!
!
!
!
!
!
!
!
!
!
!
class-map match-all a                给class-map起名字叫a(match-all和match-any的区别在于match-any是匹配其中条件一项就来转发而match-all是匹配所有条件才转发)
match access-group 100              匹配访问控制列表100
!
! 花胶炖鸡汤
吴伯箫policy-map b                          给policy-map定义名字(给策略定义)                       
咳嗽吃什么菜好class a                              (匹配class a里面的条件)
t ip precedence 1                  (设置数据包的标记为1)
!
!
!
!       
interface Loopback0
ip address 1.1.1.1 255.255.255.0
!
interface Loopback1
ip address 2.2.2.2 255.255.255.0
!
interface Ethernet0/0
no ip address
shutdown
half-duplex
!
interface Ethernet0/1
no ip address
shutdown
half-duplex
!
interface Ethernet0/2
no ip address
shutdown舒窈纠兮
half-duplex
!作文介绍自己
interface Ethernet0/3
no ip address
shutdown
half-duplex
!
interface Serial1/0
ip address 12.1.1.1 255.255.255.0
encapsulation frame-relay        (启用帧中继协议)
rial restart-delay 0
frame-relay map ip 12.1.1.2 102 broadcast (指定对端映射)
no frame-relay inver-arp                (关闭帧中继的arp)
rvice-policy output b                    (在接口应用策略)
!
interface Serial1/1
no ip address
shutdown
rial restart-delay 0
!
interface Serial1/2
no ip address
shutdown
rial restart-delay 0
!
interface Serial1/3
no ip address
shutdown
rial restart-delay 0
!
router eigrp 1
network 0.0.0.0
no auto-summary
!
ip http rver
!
!
!
access-list 100 permit icmp any host 11.11.11.11 做访问控制列表来允许r1上的所有网段访问11.11.11.11
!
!
!
control-plane
!
!
!
!
!
妮维雅男士洗面奶
!
!       
!
!
line con 0
exec-timeout 0 0
logging synchronous
line aux 0
line vty 0 4
!
!
end
R1#
r2
R2(config)#do show ru
% Ambiguous command:  "show ru"
R2(config)#do show run
Current configuration : 1357 bytes
!
version 12.4
rvice timestamps debug datetime mc
rvice timestamps log datetime mc
no rvice password-encryption
!
hostname R2
!
boot-start-marker
boot-end-marker
!
!
no aaa new-model
memory-size iomem 5
!
!
ip cef
no ip domain lookup
!
!
!
!       
!
!
!
!
!
鹤山公园!
!
!
!
!
!
!
class-map match-all a      (启用class-map 定义名字为a)
match access-group 100      (应用访问控制列表)
match ip precedence 1          (定以数据包的标记为 1)
!
!
policy-map b             
(启用class-map定义名字为 b)
class a                      (应用class  a)
drop                      (如果比匹配以上条件的数据包 则进行丢弃)
!
!
!       
!
interface Loopback0
ip address 11.11.11.11 255.255.255.0
!
interface Ethernet0/0
no ip address
shutdown
half-duplex
!
interface Ethernet0/1
no ip address
shutdown
half-duplex
!
interface Ethernet0/2
no ip address
shutdown
half-duplex
!
interface Ethernet0/3
no ip address
shutdown
half-duplex
!
interface Serial1/0
ip address 12.1.1.2 255.255.255.0
encapsulation frame-relay          (封装成fram-relay)
rial restart-delay 0             
frame-relay map ip 12.1.1.1 201 broadcast(指定对端映射)
no frame-relay inver-arp                (关闭frame-relay 的arp)
rvice-policy input b                    (在接口应用策略)
!
interface Serial1/1
no ip address
shutdown
rial restart-delay 0
!
interface Serial1/2
no ip address
shutdown
rial restart-delay 0
!
interface Serial1/3
no ip address
shutdown
rial restart-delay 0
!
router eigrp 1
network 0.0.0.0
no auto-summary
!
no ip http rver
!
!
!
access-list 100 permit icmp any host 11.11.11.11(做访问控制列表允许r1上的所有网段的icmp协议反问11.11.11.11)
!
!
!
control-plane
!
!
!
!
!
!
!
!
>
>class-map match-all c2
> match cos  5
> match packet length min 500 max 500
>class-map match-all c1
> match cos  5
> match packet length min 200 max 1500
> match not packet length min 500 max 500
>!
>!
>policy-map t-pre
> class c1
>  t ip precedence 2
> class c2
>  t ip precedence 1
--More--

本文发布于:2023-06-06 16:58:12,感谢您对本站的认可!

本文链接:https://www.wtabcd.cn/fanwen/fan/89/1006405.html

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。

标签:数据包   定义   匹配
相关文章
留言与评论(共有 0 条评论)
   
验证码:
推荐文章
排行榜
Copyright ©2019-2022 Comsenz Inc.Powered by © 专利检索| 网站地图