第一步、在R1、R2、R3、R4上运行OSPF
第二步、在R3、R4、R5、R6上运行ISIS
第三步、在R1上创建lo0、lo1创建环回口,配置IP,并将该路由引入OSPF
第四步、在R6创建lo0、lo1创建环回口,配置IP,并将该路由引入ISIS
第五步、在AS边界路由器AR3和AR4上执行路由的双点双向引入,仅将OSPF区域的1.1.1.1/32和1.1.1.2/32路由引入到ISIS,将ISIS区域的1.1.1.3/32和1.1.1.4/32路由引入到OSPF。
R1配置
interface GigabitEthernet0/0/0 ip address 10.0.12.1 255.255.255.0 # interface GigabitEthernet0/0/1 ip address 10.0.13.1 255.255.255.0 interface LoopBack0 ip address 1.1.1.1 255.255.255.255 # interface LoopBack1 ip address 1.1.1.2 255.255.255.255 # ospf 1 router-id 1.1.1.1 import-route direct route-policy 1 area 0.0.0.0 network 10.0.12.0 0.0.0.255 network 10.0.13.0 0.0.0.255 # route-policy 1 permit node 1 if-match ip-prefix 1 # ip ip-prefix 1 index 10 permit 1.1.1.0 24 greater-equal 32 less-equal 32 #定义一个前缀列表。
R2配置
interface GigabitEthernet0/0/0 ip address 10.0.12.2 255.255.255.0 # interface GigabitEthernet0/0/1 ip address 10.0.24.2 255.255.255.0 ospf 1 router-id 2.2.2.2 area 0.0.0.0 network 10.0.12.0 0.0.0.255 network 10.0.24.0 0.0.0.255
R3配置
isis 1 is-level level-2 network-entity 49.0030.0300.3003.00 import-route ospf 1 route-policy oti interface GigabitEthernet0/0/0 ip address 10.0.13.3 255.255.255.0 # interface GigabitEthernet0/0/1 ip address 10.0.34.3 255.255.255.0 isis enable 1 # interface GigabitEthernet0/0/2 ip address 10.0.35.3 255.255.255.0 isis enable 1 ospf 1 router-id 3.3.3.3 import-route isis 1 route-policy ito area 0.0.0.0 network 10.0.13.0 0.0.0.255 network 10.0.34.0 0.0.0.255 # route-policy oti deny node 5 if-match tag 200 # route-policy oti permit node 10 if-match ip-prefix 1 apply tag 100 # route-policy ito deny node 5 if-match tag 400 # route-policy ito permit node 10 if-match ip-prefix 1 apply tag 300 # ip ip-prefix 1 index 10 permit 1.1.1.0 24 greater-equal 32 less-equal 32
R4配置
isis 1 is-level level-2 network-entity 49.0040.0400.4004.00 interface GigabitEthernet0/0/0 ip address 10.0.24.4 255.255.255.0 # interface GigabitEthernet0/0/1 ip address 10.0.34.4 255.255.255.0 isis enable 1 # interface GigabitEthernet0/0/2 ip address 10.0.46.4 255.255.255.0 isis enable 1 ospf 1 router-id 4.4.4.4 preference ase 14 area 0.0.0.0 network 10.0.24.0 0.0.0.255 network 10.0.34.0 0.0.0.255 # route-policy ito deny node 5 if-match tag 100 # route-policy ito permit node 10 if-match ip-prefix 1 apply tag 200 # route-policy oti deny node 5 if-match tag 300 # route-policy oti permit node 10 if-match ip-prefix 1 apply tag 400 # ip ip-prefix 1 index 10 permit 1.1.1.0 24 greater-equal 32 less-equal 32
R5配置
isis 1 is-level level-2 network-entity 49.0050.0500.5005.00 interface GigabitEthernet0/0/0 ip address 10.0.35.5 255.255.255.0 isis enable 1 # interface GigabitEthernet0/0/1 ip address 10.0.56.5 255.255.255.0 isis enable 1
R6配置
isis 1 is-level level-2 network-entity 49.0060.0600.6006.00 import-route direct route-policy 1 interface GigabitEthernet0/0/0 ip address 10.0.46.6 255.255.255.0 isis enable 1 # interface GigabitEthernet0/0/1 ip address 10.0.56.6 255.255.255.0 isis enable 1 interface LoopBack0 ip address 1.1.1.3 255.255.255.255 # interface LoopBack1 ip address 1.1.1.4 255.255.255.255 # route-policy 1 permit node 10 if-match ip-prefix 1 # ip ip-prefix 1 index 10 permit 1.1.1.0 24 greater-equal 32 less-equal 32