记录OSPF配置,建立邻居失败的过程

在这里插入图片描述

1.配置完ospf后,在路由表中不出现ospf相关信息

[SW2]ospf
[SW2-ospf-1]are	
[SW2-ospf-1]area 0
[SW2-ospf-1-area-0.0.0.0]net	
[SW2-ospf-1-area-0.0.0.0]network 0.0.0.0
Jul  4 2024 22:11:58-08:00 SW2 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 19, the 
change loop count is 0, and the maximum number of records is 4095.
                                         ^
Error:Incomplete command found at '^' position.
[SW2-ospf-1-area-0.0.0.0]network 0.0.0.0 0.0.0.0
[SW2-ospf-1-area-0.0.0.0]qu
[SW2-ospf-1]qu
[SW2]dis ip rou	
[SW2]dis ip routing-table 
Route Flags: R - relay, D - download to fib
------------------------------------------------------------------------------
Routing Tables: Public
         Destinations : 6        Routes : 6        

Destination/Mask    Proto   Pre  Cost      Flags NextHop         Interface

      127.0.0.0/8   Direct  0    0           D   127.0.0.1       InLoopBack0
      127.0.0.1/32  Direct  0    0           D   127.0.0.1       InLoopBack0
    192.168.2.0/24  Direct  0    0           D   192.168.2.2     Vlanif20
    192.168.2.2/32  Direct  0    0           D   127.0.0.1       Vlanif20
    192.168.3.0/24  Direct  0    0           D   192.168.3.254   Vlanif30
  192.168.3.254/32  Direct  0    0           D   127.0.0.1       Vlanif30


2.查看错误信息,display ospf error

[SW2]display ospf error

	 OSPF Process 1 with Router ID 192.168.3.254
		 OSPF error statistics 

General packet errors:
 0     : IP: received my own packet     590   : Bad packet
 0     : Bad version                    0     : Bad checksum
 0     : Bad area id                    0     : Drop on unnumbered interface
 0     : Bad virtual link               0     : Bad authentication type
 0     : Bad authentication key         0     : Packet too small
 0     : Packet size > ip length        0     : Transmit error
 0     : Interface down                 0     : Unknown neighbor
 590   : Bad net segment                0     : Extern option mismatch
 0     : Router id confusion

HELLO packet errors:
 0     : Netmask mismatch               0     : Hello timer mismatch
 0     : Dead timer mismatch            0     : Virtual neighbor unknown
 0     : NBMA neighbor unknown          0     : Invalid Source Address

DD packet errors:
 0     : Neighbor state low             0     : Unknown LSA type
 0     : MTU option mismatch

LS ACK packet errors:
 0     : Neighbor state low             0     : Unknown LSA type

LS REQ packet errors:
 0     : Neighbor state low             0     : Empty request
 0     : Bad request

LS UPD packet errors:
 0     : Neighbor state low             0     : Newer self-generate LSA 
 0     : LSA checksum bad               0     : Received less recent LSA
 0     : Unknown LSA type

Opaque errors:
 0     : 9-out of flooding scope        0     : 10-out of flooding scope
 0     : 11-out of flooding scope       0     : Unkown TLV type

Retransmission for packet over Limitation errors:
 0     : Number for DD Packet           0     : Number for Update Packet
 0     : Number for Request Packet

Receive Grace LSA errors:
 0     : Number of invalid LSAs         0     : Number of policy failed LSAs
 0     : Number of wrong period LSAs

Configuration errors:
 0     : Tunnel cost mistake

出现2处错误:Bad net segment 和Bad packet。
猜测是由网段划分错误导致的包错误。
3.逐一检查2个路由器划分网段是否有误,最后在三层交换机的0/0/1接口发现网段配置错误,此处应该配置为vlan 20

[SW2]interface int	
[SW2]interface g	
[SW2]interface GigabitEthernet 0/0/1
[SW2-GigabitEthernet0/0/1]dis this
#
interface GigabitEthernet0/0/1
 port link-type access
 port default vlan 30
#
return

4.重新划分网段port default vlan 20,出现如下信息,表示ospf建立邻居成功

[SW2-GigabitEthernet0/0/1]port default vlan 20
[SW2-GigabitEthernet0/0/1]
Jul  4 2024 22:22:15-08:00 SW2 %%01IFNET/4/IF_STATE(l)[0]:Interface Vlanif30 has
 turned into DOWN state.
Jul  4 2024 22:22:15-08:00 SW2 %%01IFNET/4/LINK_STATE(l)[1]:The line protocol IP
 on the interface Vlanif30 has entered the DOWN state.
Jul  4 2024 22:22:19-08:00 SW2 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 20, the 
change loop count is 0, and the maximum number of records is 4095.
Jul  4 2024 22:22:21-08:00 SW2 %%01OSPF/4/NBR_CHANGE_E(l)[2]:Neighbor changes ev
ent: neighbor status changed. (ProcessId=1, NeighborAddress=192.168.2.1, Neighbo
rEvent=HelloReceived, NeighborPreviousState=Down, NeighborCurrentState=Init)
Jul  4 2024 22:22:21-08:00 SW2 %%01OSPF/4/NBR_CHANGE_E(l)[3]:Neighbor changes ev
ent: neighbor status changed. (ProcessId=1, NeighborAddress=192.168.2.1, Neighbo
rEvent=2WayReceived, NeighborPreviousState=Init, NeighborCurrentState=ExStart)
Jul  4 2024 22:22:21-08:00 SW2 %%01OSPF/4/NBR_CHANGE_E(l)[4]:Neighbor changes ev
ent: neighbor status changed. (ProcessId=1, NeighborAddress=192.168.2.1, Neighbo
rEvent=NegotiationDone, NeighborPreviousState=ExStart, NeighborCurrentState=Exch
ange)
Jul  4 2024 22:22:21-08:00 SW2 %%01OSPF/4/NBR_CHANGE_E(l)[5]:Neighbor changes ev
ent: neighbor status changed. (ProcessId=1, NeighborAddress=192.168.2.1, Neighbo
rEvent=ExchangeDone, NeighborPreviousState=Exchange, NeighborCurrentState=Loadin
g)
Jul  4 2024 22:22:21-08:00 SW2 %%01OSPF/4/NBR_CHANGE_E(l)[6]:Neighbor changes ev
ent: neighbor status changed. (ProcessId=1, NeighborAddress=192.168.2.1, Neighbo
rEvent=LoadingDone, NeighborPreviousState=Loading, NeighborCurrentState=Full)

[SW2]dis ip routing-table 
Route Flags: R - relay, D - download to fib
------------------------------------------------------------------------------
Routing Tables: Public
         Destinations : 5        Routes : 5        

Destination/Mask    Proto   Pre  Cost      Flags NextHop         Interface

      127.0.0.0/8   Direct  0    0           D   127.0.0.1       InLoopBack0
      127.0.0.1/32  Direct  0    0           D   127.0.0.1       InLoopBack0
    192.168.1.0/24  OSPF    10   2           D   192.168.2.1     Vlanif20
    192.168.2.0/24  Direct  0    0           D   192.168.2.2     Vlanif20
    192.168.2.2/32  Direct  0    0           D   127.0.0.1       Vlanif20

  • 3
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值