2、基本调试
' ^% Q* d) L3 B: A# |6 Q$ MRA#sh ip route ospf ------查看通过OSPF学习到的路由0 Z$ s- n" L& b. S* u0 C4 Q5 X7 u. ?
2.0.0.0/24 is subnetted, 1 subnets
# |: I* s- V( }0 D A4 W2 vO 2.2.2.0 [110/65] via 10.0.0.2, 00:00:14, Serial1/0
2 v# l" u q4 m$ @ 3.0.0.0/24 is subnetted, 1 subnets
2 r- r- `0 C. ]$ G! n6 FO 3.3.3.0 [110/65] via 12.0.0.2, 00:00:14, Serial1/2- R- w7 h5 P, R# p
11.0.0.0/24 is subnetted, 1 subnets
2 t. J, L/ b' x7 s7 K2 d" b: m7 {O 11.0.0.0 [110/128] via 12.0.0.2, 00:00:14, Serial1/2
$ Z# F% W. ^' a0 o: g: @/ m [110/128] via 10.0.0.2, 00:00:14, Serial1/0! `/ @3 |% i) T4 T
7 F) e2 S! M6 x1 s! K% D$ p7 [RA#sh ip protocols -----查看路由0 N Y7 } W. Z
Routing Protocol is "ospf 1" ------启用了OSPF,进程号为1
! H/ I& e0 E2 O* T1 l* _, V Outgoing update filter list for all interfaces is not set) s1 w y0 a5 H, U
Incoming update filter list for all interfaces is not set
! v3 f) v" m& V7 o- P2 n1 I3 S Router ID 1.1.1.1 ------路由器ID
& R( D" m, R1 k5 `6 p/ m5 i& n0 } Number of areas in this router is 1. 1 normal 0 stub 0 nssa( a* q) Y5 \6 Y# }$ K
Maximum path: 4# a9 C" N2 m7 A0 N
Routing for Networks: -----路由的网络$ @: G7 w+ C( L% ]2 Q
1.1.1.0 0.0.0.255 area 0
& m" x, N$ F7 l% R, | 10.0.0.0 0.0.0.255 area 09 p3 W6 ^+ }+ e; L- x) L
12.0.0.0 0.0.0.255 area 0: ?+ B# p& c4 H1 u
Reference bandwidth unit is 100 mbps ----路由花费参考带宽为100M H" a: f2 X0 x" _* X, X
Routing Information Sources: ----邻居路由器0 v. P' d, w( f$ ^
Gateway Distance Last Update
+ O$ z: t0 R% C7 z( l- o1 x 3.3.3.3 110 00:01:14
. n; f) w3 X o2 S" X) y% M 2.2.2.2 110 00:01:14
* {3 w% ?" @" g% V Distance: (default is 110)" f; c8 \) t$ G! `- X5 e+ U+ z
6 f8 x2 d" h, C1 Z) D4 b4 i* f
RA#sh ip ospf interface s1/2 -----查看接口
, B2 q9 ~7 |) |/ ?Serial1/2 is up, line protocol is up
# n. p4 A9 @# n! u9 q6 m Internet Address 12.0.0.1/24, Area 0
+ r3 e6 I7 [1 | F) i Process ID 1, Router ID 1.1.1.1, Network Type POINT_TO_POINT, Cost: 643 I3 G1 v; A9 y$ N+ T
Transmit Delay is 1 sec, State POINT_TO_POINT
: I% k4 V; g/ ]% I5 Z Timer intervals configured, Hello 10, Dead 40, Wait 40, Retransmit 5 ----hello/dead时间间隔
C2 ]- u8 l: R6 A" N/ m ………… | @) x/ C" O4 l
Suppress hello for 0 neighbor(s)
& Q; m( D4 G7 e+ j" ?, X& _6 K4 b$ ~6 `+ S; f8 e2 I# s0 B
RA#sh ip ospf nei -----查看邻居
9 Z2 {6 o" _5 a$ q4 kNeighbor ID Pri State Dead Time Address Interface' p( L z B7 s0 y5 n p) ^
3.3.3.3 0 FULL/ - 00:00:37 12.0.0.2 Serial1/2& }& K2 ~! t$ b7 |" W
2.2.2.2 0 FULL/ - 00:00:39 10.0.0.2 Serial1/0/ k' ^( S- y7 o6 S/ k0 N
从以上可见,在点对点环境下,没有DR/BDR选举,邻居关系自动建立。
: B, ^9 f8 [0 {3 R; C4 j+ E. N
& j- l, X/ j7 @2 lRA#sh ip ospf database -----查看LSDB,三张表的LSDB是一样的
0 ? [/ V5 V y* Q0 O+ x* l OSPF Router with ID (1.1.1.1) (Process ID 1)/ B7 r6 g/ T o
Router Link States (Area 0); h( ^+ X' a, n# m* @7 o
Link ID ADV Router Age Seq# Checksum Link count
! r$ I7 S9 {- a. a2 L8 K' s: _1.1.1.1 1.1.1.1 325 0x80000005 0x00E5BD 5
, p/ |7 D y1 a; S2.2.2.2 2.2.2.2 223 0x80000006 0x002F6D 58 ~( K& n6 }) F6 b
3.3.3.3 3.3.3.3 202 0x80000005 0x00C1CF 5 |