实验拓扑:
实验代码如下:
R1:
enable
config t
hostname R1
int s1/1
ip address 192.168.12.1 255.255.255.0
no shutdown
exit
int lo1
ip add 192.168.1.1 255.255.255.0
no shutdown
exit
router rip
version 2
no auto-summary
network 192.168.1.0
network 192.168.12.0
end
R2:
enable
config t
hostname R2
int s1/0
ip address 192.168.12.2 255.255.255.0
no shutdown
exit
int s1/1
ip add 192.168.23.1 255.255.255.0
no shutdown
exit
int lo2
ip add 192.168.2.2 255.255.255.0
no shutdown
exit
router rip
version 2
redistribute eigrp 100 metric 3
network 192.168.12.0
exit
router eigrp 100
network 192.168.23.0
network 192.168.2.0
redistribute rip metric 1544 20000 255 1 1500
end
R3:
enable
config t
hostname R3
int s1/0
ip add 192.168.23.2 255.255.255.0
no shutdown
exit
int s1/2
ip add 192.168.37.1 255.255.255.0
no shutdown
exit
int lo3
ip add 192.168.3.1 255.255.255.0
no shutdown
exit
router eigrp 100
network 192.168.23.0 0.0.0.255
redistribute ospf 200 metric 1544 20000 255 1 1500
exit
router ospf 200
network 192.168.3.0 0.0.0.255 area 0
network 192.168.37.0 0.0.0.255 area 0
redistribute eigrp 100 metric 20 metric-type 2 subnets
end
R7:
enable
config t
hostname R7
int s1/2
ip add 192.168.37.2 255.255.255.0
no shutdown
exit
int s1/5
ip add 192.168.76.1 255.255.255.0
ip router isis
no shutdown
exit
router ospf 200
network 192.168.37.0 0.0.0.255 area 0
redistribute connected subnets
redistribute isis level-1-2 metric 10 metric-type 1 subnets
exit
clns routing
router isis
net 49.0001.0000.0000.0007.00
redistribute ospf 200 level-2 metric 3 metric-type internal
exit
end
R6
enable
config t
hostname R6
int s1/2
ip add 192.168.76.2 255.255.255.0
ip router isis
no shutdown
int lo6
ip add 192.168.6.1 255.255.255.0
ip router isis
no shutdown
exit
clns routing
router isis
net 49.0001.0000.0000.0006.00
end