拓扑环境
IP地址配置如下:
PC1=192.168.1.1/24
PC2=172.16.0.1/16
AR3_GI0/0/1=192.168.1.254/24
AR3_GI0/0/0=10.0.0.1/8
AR3_LO0=1.1.1.1/0
AR5_GI0/0/1=172.16.0.254/16
AR5_GI0/0/0=10.0.0.2/8
AR5_LO0=2.2.2.2/0
OSPF配置如下:
AR3配置如下:
#
sysname AR3
#
interface GigabitEthernet0/0/0
ip address 10.0.0.1 255.0.0.0
#
interface GigabitEthernet0/0/1
ip address 192.168.1.254 255.255.0.0
#
interface LoopBack0
ip address 1.1.1.1 255.255.255.255
#
ospf 1
area 0.0.0.0
network 10.0.0.0 0.255.255.255
network 192.168.1.0 0.0.0.255
#
return
AR5配置:
#
sysname AR5
#
interface GigabitEthernet0/0/0
ip address 10.0.0.2 255.0.0.0
#
interface GigabitEthernet0/0/1
ip address 172.16.0.254 255.255.0.0
#
interface LoopBack0
ip address 2.2.2.2 255.255.255.255
#
ospf 1
area 0.0.0.0
network 10.0.0.0 0.255.255.255
network 172.16.0.0 0.0.255.255
#
return
配置验证:
使用display ospf peer brief 看状态是FULL
使用display ip routing-table 查看路由表,有对端的路由信息
PC1 PING PC2可以ping通。