OSPF 和RIP的配置R2>enR2#conf tR2(config)#inter f0/0R2(config-if)#ip address 202.106.12.2 255.255.255.0R2(config-if)#no shutR2(config-if)#inter f0/1R2(config-if)#ip address 202.106.23.2 255.255.255.0R2(config-if)#no shutR2(config-if)#inter loop 0R2(config-if)#ip address 2.2.2.2 255.255.255.255R2(config-if)#no shutR2(config-if)#exR2(config)#router ripR2(config-router)#version 2R2(config-router)#no auto-summaryR2(config-router)#net 0.0.0.0R2(config-router)#endR2(config)#ip route 0.0.0.0 0.0.0.0 202.106.23.3R2#writeBuilding configuration...[OK]R3的配置R5>enR5#conf tR5(config)#inter f0/0R5(config-if)#ip address 202.106.45.5 255.255.255.0R5(config-if)#no shutR5(config-if)#inter f0/1R5(config-if)#ip address 202.106.56.5 255.255.255.0R5(config-if)#no shutR5(config-if)#inter loop 0R5(config-if)#ip address 5.5.5.5 255.255.255.255R5(config-if)#no shutR5(config-if)#exR5(config)#router ospf 110R5(config-router)#net 5.5.5.5 0.0.0.0 a 0R5(config-router)#net 202.106.56.0 0.0.0.255 a 2R5(config-router)#net 202.106.45.0 0.0.0.255 a 0R5#writeBuilding configuration...R6查看2类LSAshow ip ospf database summary查
转载于:https://blog.51cto.com/8068072/1341910