全部博文(1015)
分类:
2009-01-20 23:09:17
Router A与Router B通信,链路层封装PPP,都运行OSPF协议。对Router A上的OSPF进程进行,引入三条静态。通过在Router B上过滤规则,使接收到的三条静态部分可见,部分被屏蔽掉。
【组网图】
【脚本】
RouterA脚本 |
[Router A] interface serial 1/0/0 [Router A-Serial1/0/0] ip address 10.0.0.1 255.0.0.0 [Router A-Serial1/0/0] link-protocol ppp [Router A-Serial1/0/0] quit [Router A] ip route-static 20.0.0.1 32 serial 1/0/0 [Router A] ip route-static 30.0.0.1 32 serial 1/0/0 [Router A] ip route-static 40.0.0.1 32 serial 1/0/0 [Router A] router id 1.1.1.1 [Router A] ospf [Router A-ospf-1] area 0 [Router A-ospf-1-area-0.0.0.0] network 10.0.0.0 0.0.0.255 [Router A-ospf-1] import-route static |
RouterB脚本 |
[Router B] interface serial 1/0/0 [Router B-Serial1/0/0] ip address 10.0.0.2 255.0.0.0 [Router B-Serial1/0/0] link-protocol ppp [Router B-Serial1/0/0] quit [Router B] acl number 2001 [Router B-acl-basic-2001] rule deny source 30.0.0.0 0.255.255.255 [Router B-acl-basic-2001] rule permit source any [Router B] router id 2.2.2.2 [Router B] ospf [Router B-ospf-1] area 0 [Router A-ospf-1-area-0.0.0.0] network 10.0.0.0 0.0.0.255 [Router B-ospf-1] filter-policy 2001 import |