实验1:
R1配置:
sysname R1
interface GigabitEthernet0/0/0
ip address 1.1.1.1 255.255.255.0
interface LoopBack0
ip address 192.168.1.1 255.255.255.0
ospf 1 router-id 10.10.10.10 #开启ospf进程1,路由ID取名为10.10.10.10
area 0 #配置区域0
network 1.1.1.0 0.0.0.255
network 192.168.1.0 0.0.0.255
R2配置:
sysname R2
interface GigabitEthernet0/0/0
ip address 1.1.1.2 255.255.255.0
interface GigabitEthernet0/0/1
ip address 2.2.2.2 255.255.255.0
interface LoopBack0
ip address 192.168.2.1 255.255.255.0
ospf 1 router-id 20.20.20.20
area 0
network 1.1.1.0 0.0.0.255
network 2.2.2.0 0.0.0.255
network 192.168.2.0 0.0.0.255
R3配置:
sysname R3
interface GigabitEthernet0/0/0
ip address 2.2.2.3 255.255.255.0
interface LoopBack0
ip address 192.168.3.1 255.255.255.0
ospf 1 router-id 30.30.30.30
area 0.0.0.0
network 2.2.2.0 0.0.0.255
network 192.168.3.0 0.0.0.255
查看
邻居信息:
查看Link State Database
查看ospf路由表
查看路由表