[R1]ospf 1 router-id 1.1.1.1
[R1-ospf-1]
Jul 8 2021 19:42:28-08:00 R1 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 6, the ch
ange loop count is 0, and the maximum number of records is 4095.
[R2]ospf 1 router-id 2.2.2.2
Jul 8 2021 19:43:08-08:00 R2 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 5, the ch
ange loop count is 0, and the maximum number of records is 4095
[R3]ospf 1 router-id 3.3.3.3
Jul 8 2021 19:43:49-08:00 R3 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 8, the ch
ange loop count is 0, and the maximum number of records is 4095.
[R4]ospf
[R4]ospf 1 router-id 4.4.4.4
Jul 8 2021 19:44:59-08:00 R4 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 5, the ch
ange loop count is 0, and the maximum number of records is 4095.
3、路由器进行宣告
[R1-ospf-1]area 0
[R1-ospf-1-area-0.0.0.0]
Jul 8 2021 19:46:48-08:00 R1 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 7, the ch
ange loop count is 0, and the maximum number of records is 4095.
[R1-ospf-1-area-0.0.0.0]network 1.1.1.1 0.0.0.0
Jul 8 2021 19:47:58-08:00 R1 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 8, the ch
ange loop count is 0, and the maximum number of records is 4095.
[R1-ospf-1-area-0.0.0.0]network 10.0.1.1 0.0.0.0
Jul 8 2021 19:48:58-08:00 R1 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 9, the ch
ange loop count is 0, and the maximum number of records is 4095.
[R1-ospf-1-area-0.0.0.0]network 10.0.2.1 0.0.0.0
Jul 8 2021 19:49:28-08:00 R1 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 10, the c
hange loop count is 0, and the maximum number of records is 4095.
[R2-ospf-1]area 0
[R2-ospf-1-area-0.0.0.0]
Jul 8 2021 19:50:59-08:00 R2 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 6, the ch
ange loop count is 0, and the maximum number of records is 4095.
[R2-ospf-1-area-0.0.0.0]network 2.2.2.2 0.0.0.0
Jul 8 2021 19:51:19-08:00 R2 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 7, the ch
ange loop count is 0, and the maximum number of records is 4095
[R2-ospf-1-area-0.0.0.0]display this
#
area 0.0.0.0
network 2.2.2.2 0.0.0.0
network 10.0.1.2 0.0.0.0
#
return
[R3-ospf-1-area-0.0.0.0]network 10.0.2.2 0.0.0.0
Jul 8 2021 19:55:01-08:00 R3 %%01OSPF/4/NBR_CHANGE_E(l)[0]:Neighbor changes eve
nt: neighbor status changed. (ProcessId=1, NeighborAddress=10.0.2.1, NeighborEve
nt=HelloReceived, NeighborPreviousState=Down, NeighborCurrentState=Init)
[R3-ospf-1]area 1
Jul 8 2021 19:55:49-08:00 R3 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 11, the c
hange loop count is 0, and the maximum number of records is 4095.
[R3-ospf-1-area-0.0.0.1]network 3.3.3.3 0.0.0.0
[R3-ospf-1-area-0.0.0.1]
Jul 8 2021 19:56:09-08:00 R3 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 12, the c
hange loop count is 0, and the maximum number of records is 4095.
[R3-ospf-1-area-0.0.0.1]network 10.0.3.1 0.0.0.0
[R3-ospf-1-area-0.0.0.1]
Jul 8 2021 19:57:09-08:00 R3 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 13, the c
hange loop count is 0, and the maximum number of records is 4095.
[R4-ospf-1]area 1
[R4-ospf-1-area-0.0.0.1]
Jul 8 2021 19:57:49-08:00 R4 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 6, the ch
ange loop count is 0, and the maximum number of records is 4095.
[R4-ospf-1-area-0.0.0.1]network 4.4.4.4 0.0.0.0
[R4-ospf-1-area-0.0.0.1]
Jul 8 2021 19:58:19-08:00 R4 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 7, the ch
ange loop count is 0, and the maximum number of records is 4095.
[R4-ospf-1-area-0.0.0.1]network 10.0.3.2 0.0.0.0
[R4-ospf-1-area-0.0.0.1]
Jul 8 2021 19:58:49-08:00 R4 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 8, the ch
ange loop count is 0, and the maximum number of records is 4095.
*检验
R1:
[R1-ospf-1-area-0.0.0.0]display this
#
area 0.0.0.0
network 1.1.1.1 0.0.0.0
network 10.0.1.1 0.0.0.0
network 10.0.2.1 0.0.0.0
#
return
R2:
[R2-ospf-1-area-0.0.0.0]display this
#
area 0.0.0.0
network 2.2.2.2 0.0.0.0
network 10.0.1.2 0.0.0.0
#
R3:(注意,R3有两个不同的网段,宣告时有两个区域)
[R3-ospf-1-area-0.0.0.0]display this
#
area 0.0.0.0
network 10.0.2.2 0.0.0.0
#
[R3-ospf-1-area-0.0.0.1]display this
#
area 0.0.0.1
network 3.3.3.3 0.0.0.0
network 10.0.3.1 0.0.0.0
#
return
R4[R4-ospf-1-area-0.0.0.1]display this
#
area 0.0.0.1
network 4.4.4.4 0.0.0.0
network 10.0.3.2 0.0.0.0
#
return
4、R1-R3之间R1为DR,没有BDR
[R3]interface e0/0/0
[R3-Ethernet0/0/0]int
[R3-Ethernet0/0/0]int e0/0/1
[R3-Ethernet0/0/1]os
[R3-Ethernet0/0/1]ospf dr-
[R3-Ethernet0/0/1]ospf dr-priority 3
[R3-Ethernet0/0/1]
Jul 8 2021 20:36:58-08:00 R3 %%01OSPF/3/NBR_CHG_DOWN(l)[8]:Neighbor event:neigh
bor state changed to Down. (ProcessId=1, NeighborAddress=4.4.4.4, NeighborEvent=
KillNbr, NeighborPreviousState=Full, NeighborCurrentState=Down)
[R3-Ethernet0/0/1]q
[R3]q
<R3>reset no
<R3>reset o
<R3>reset ospf p
<R3>reset ospf process
Warning: The OSPF process will be reset. Continue? [Y/N]:y
<R3>
Jul 8 2021 20:37:58-08:00 R3 %%01OSPF/3/NBR_CHG_DOWN(l)[16]:Neighbor event:neig
hbor state changed to Down. (ProcessId=1, NeighborAddress=1.1.1.1, NeighborEvent
=KillNbr, NeighborPreviousState=Full, NeighborCurrentState=Down)
[R2]int
[R2]interface e0/0/0
[R2-Ethernet0/0/0]int e0/0/0
[R2-Ethernet0/0/0]os
[R2-Ethernet0/0/0]ospf dr-
[R2-Ethernet0/0/0]ospf dr-priority 3
[R2-Ethernet0/0/0]
Jul 8 2021 20:39:35-08:00 R2 %%01OSPF/3/NBR_CHG_DOWN(l)[0]:Neighbor event:neigh
bor state changed to Down. (ProcessId=1, NeighborAddress=1.1.1.1, NeighborEvent=
KillNbr, NeighborPreviousState=Full, NeighborCurrentState=Down)
[R2-Ethernet0/0/0]q
[R2]q
<R2>
<R2>reset o
<R2>reset ospf p
<R2>reset ospf process
Warning: The OSPF process will be reset. Continue? [Y/N]:y
<R2>
Jul 8 2021 20:40:08-08:00 R2 %%01OSPF/3/NBR_CHG_DOWN(l)[8]:Neighbor event:neigh
bor state changed to Down. (ProcessId=1, NeighborAddress=1.1.1.1, NeighborEvent=
KillNbr, NeighborPreviousState=Full, NeighborCurrentState=Down)
5、D4-D3,D4为DR,没有BDR
[R3-Ethernet0/0/0]ospf dr-priority 4
Jul 8 2021 20:54:40-08:00 R3 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.
191.3.1 configurations have been changed. The current change number is 21, the c
hange loop count is 0, and the maximum number of records is 4095
[R3-Ethernet0/0/0]q
[R3]q
<R3>reset o
<R3>reset ospf p
<R3>reset ospf process
Warning: The OSPF process will be reset. Continue? [Y/N]:y
<R3>
Jul 8 2021 20:55:28-08:00 R3 %%01OSPF/3/NBR_CHG_DOWN(l)[0]:Neighbor event:neigh
bor state changed to Down. (ProcessId=1, NeighborAddress=1.1.1.1, NeighborEvent=
KillNbr, NeighborPreviousState=Full, NeighborCurrentState=Down)
6、查看邻居关系表
[R4-ospf-1-area-0.0.0.1]dis ospf peer
OSPF Process 1 with Router ID 4.4.4.4
Neighbors
Area 0.0.0.1 interface 10.0.3.2(Ethernet0/0/0)'s neighbors
Router ID: 3.3.3.3 Address: 10.0.3.1
State: Full Mode:Nbr is Slave Priority: 3
DR: 10.0.3.2 BDR: 10.0.3.1 MTU: 0
Dead timer due in 35 sec
Retrans timer interval: 5
Neighbor is up for 00:08:29
Authentication Sequence: [ 0 ]
R3-ospf-1-area-0.0.0.0]dis ospf peer
OSPF Process 1 with Router ID 3.3.3.3
Neighbors
Area 0.0.0.0 interface 10.0.2.2(Ethernet0/0/0)'s neighbors
Router ID: 1.1.1.1 Address: 10.0.2.1
State: Full Mode:Nbr is Slave Priority: 1
DR: 10.0.2.1 BDR: 10.0.2.2 MTU: 0
Dead timer due in 31 sec
Retrans timer interval: 5
Neighbor is up for 00:10:15
Authentication Sequence: [ 0 ]
Neighbors
Area 0.0.0.1 interface 10.0.3.1(Ethernet0/0/1)'s neighbors
Router ID: 4.4.4.4 Address: 10.0.3.2
State: Full Mode:Nbr is Master Priority: 1
DR: 10.0.3.2 BDR: 10.0.3.1 MTU: 0
Dead timer due in 38 sec
Retrans timer interval: 5
Neighbor is up for 00:10:18
Authentication Sequence: [ 0 ]
[R2-ospf-1-area-0.0.0.0]dis ospf peer
OSPF Process 1 with Router ID 2.2.2.2
Neighbors
Area 0.0.0.0 interface 10.0.1.2(Ethernet0/0/0)'s neighbors
Router ID: 1.1.1.1 Address: 10.0.1.1
State: Full Mode:Nbr is Slave Priority: 1
DR: 10.0.1.1 BDR: 10.0.1.2 MTU: 0
Dead timer due in 32 sec
Retrans timer interval: 5
Neighbor is up for 00:09:01
Authentication Sequence: [ 0 ]
7、全网可达
[R4]ping 1.1.1.1
PING 1.1.1.1: 56 data bytes, press CTRL_C to break
Reply from 1.1.1.1: bytes=56 Sequence=1 ttl=254 time=50 ms
Reply from 1.1.1.1: bytes=56 Sequence=2 ttl=254 time=60 ms
Reply from 1.1.1.1: bytes=56 Sequence=3 ttl=254 time=50 ms
Reply from 1.1.1.1: bytes=56 Sequence=4 ttl=254 time=80 ms
Reply from 1.1.1.1: bytes=56 Sequence=5 ttl=254 time=50 ms
综合实验31、划分ip地址即环回地址2、开启OSPF[R1]ospf 1 router-id 1.1.1.1[R1-ospf-1]Jul 8 2021 19:42:28-08:00 R1 DS/4/DATASYNC_CFGCHANGE:OID 1.3.6.1.4.1.2011.5.25.191.3.1 configurations have been changed. The current change number is 6, the change loop count is 0,