PDA

View Full Version : [TUTOR] CCNP (Advance Routing)



Liwh
23-11-2002, 04:36
Trước hết, Liwh viết cái này là vì đang buồn gf :(, với lại ngày hôm nay phải nói về OSPF. Nên viết luôn cho các bạn về những gì Liwh đã đọc qua về giao thức Routing này. Hy vọng nó sẽ giúp ích cho các bạn.

Trước hết OSPF là một giao thức theo kiểu Link-State (LS Liwh có nói trong Poll: CCNA #1). Tức là nó thể hiện trạng thái của 1 đường Link, link này có thể là physical hay logical (virtual link). Trước hết Liwh sẽ giới thiệu một số khái niệm dùng trong OSPF.
* Neighbor: 2 router được cho là neighbor với nhau khi chúng có cùng chung 1 kết nối (có thể là interface vật lý, có thể là logical link) và có chung 1 vài tham số trong Hello packet.
* Adjacencies: được xem như một virtual point-to-point. Tuỳ thuộc vào network type, router type mà các neighbor đó thiết lập adjacencies với nhau.
* Link State Advertisement (LSA): OSPF là 1 link state routing protocol, do đó phải có cách nào để các router sẽ biết được State of the Link của nhau. OSPF đưa ra LSA. LSA được gửi đi giữa 2 Router đã thiết lập Adjacencies, thông báo cho nhau biết về trạng thái link. Link này có thể của stub network, OSPF domain, hay là 1 routing protocol nào khác được redistribute vào OSPF.
* Link State Database (LSDatabase): là nơi để chứa các LSA mà Router nhận được từ đó dựa vào Djistra Algorithm mà xây dựng nên bảng Routing table.
* Hello packet: được send qua lại liên tục (khoảng 10s nếu default của các LAN connection như Ethernet, ****** ,Token ..) để bảo đảm sự tồn tại của neighbor (được xem như keep-alive). Ngoài ra Hello packet còn dùng để thiết lập 1 số tính chất của OSPF link.
* Area: trong 1 domain OSPF, mỗi area được xem như là 1 sub OSPF domain. Chúng hoạt động gần như độc lập với nhau. OSPF chia nhỏ ra thành nhiều Area chủ yếu để giảm tải cho Router như bớt entries trong bảng Routing, các thông tin khi update (hay lúc refresh) sẽ ít đi, và từ tính toán giải thuật SPF cho 1 mạng lớn thì nay chỉ tính toán trong 1 Area ( CPU cần cho xử lí sẽ giảm đi rất nhiều).
* Link: có thể là kết nối Point-to-point, một mạng broadcast (như ehternet thông qua switch), hay Frame Relay, hay Demand Circuit (như Dial up, SVC ..) mà chúng ta đã biết. Nay OSPF còn đưa ra thêm một khái niệm Virtual Link, để chỉ một trường hợp đặc biệt mà Liwh sẽ nói kĩ sau này.
* Router ID: là địa chỉ IP của interface loop-back cao nhất mà Router có (VD: Loop 0 192.168.80.100 so với 192.168.20.202, thì 192.168.80.100 sẽ được chọn). Nếu Router không có interface Loopback, thì Router sẽ chọn địa chỉ IP nào cao nhất trong số các physical interfaces. Router ID được dùng để set DR, BDR của 1 Area, hay set Master/Slave của 1 link. Nói chung ID càng cao thì sẽ càng có nhiều lợi thế.
* Designated Router (DR): chỉ có trong Multiaccess network type. DR là Router sẽ thiết lập Adjacencies với tất cả các Router khác trong 1 mạng, sẽ nhận update và gửi Update đi đến tất cả các Router trong cùng 1 net. 1 OSPF domain có thể có nhiều DR.
* Backup Designated Router (BDR): cũng chỉ có trong Multiaccess Network Type. BDR cũng thiết lập Adjacncies với tất cả Router khác, nhưng chỉ nhận update từ các Router khác mà không reply (DR thì reply, và send update đến các Router khác). BDR dùng để backup cho DR, vì khi DR die, OSPF sẽ mất thời gian để bầu lại DR mới (mạng bị down) . Với BDR, khi DR die, thì BDR sẽ chuyển thành DR ngay (DR và BDR có chung các dữ liệu về network đó). Và lúc này mạng sẽ chọn 1 BDR mới mà kh6ong làm down mạng.
----------------Bạn sẽ hiểu Area, DR, BDR kĩ hơn trong các bài sau----------------
* Routing Table: cũng giống như những Routing Protocol khác, OSPF cũng có 1 bảng Routing để tìm ra đường đi tối ưu đến 1 network nào đó. Đối với bảng routing của OSPF, ngoài chỉ ra Route này được học từ OSPF. Mà còn chỉ ra route này là từ 1 routing domain (protocol) khác (External), hay từ 1 Area khác (InterArea).
* Metric: cứ mỗi 1 link thì OSPF sẽ gán 1 cost lên đó ( Cost = 10^8 / BW). Thì Metric từ A -> B sẽ là cost của tất cả các link từ A -> B (mặc dù có 1 số ltrường hợp metric sẽ không đổi cho dù đi qua nhiều Router).

Vẫn còn rất nhiều, nhưng lâu lâu viết 1 ít. Ban đầu hơi khó hiểu, nhưng sau này các bạn sẽ thấy dễ hiểu hơn khi biết cách hoạt dộgn của nó.
Thân

yuna_admirer
24-11-2002, 23:27
Tui post phần debug của OSPF process lên , bà con tự xem nhé :
R1#debug ip packet
IP packet debugging is on
R1#
R1#
00:34:15: IP: s=172.16.12.1 (local), d=224.0.0.5 (Serial0), len 64, sending
broad/multicast
00:34:16: IP: s=10.0.0.3 (Ethernet0), d=224.0.0.5, len 84, rcvd 0
00:34:16: IP: s=172.16.12.2 (Serial0), d=224.0.0.5, len 84, rcvd 0
00:34:16: IP: s=172.16.12.1 (local), d=224.0.0.5 (Serial0), len 84, sending
broad/multicast
00:34:16: IP: s=10.0.0.5 (Ethernet0), d=224.0.0.5, len 84, rcvd 0
00:34:16: IP: s=10.0.0.1 (local), d=224.0.0.6 (Ethernet0), len 84, sending
broad/multicast
00:34:16: IP: s=10.0.0.3 (Ethernet0), d=224.0.0.5, len 64, rcvd 0
00:34:17: IP: s=172.16.12.2 (Serial0), d=224.0.0.5, len 68, rcvd 0
00:34:17: IP: s=10.0.0.5 (Ethernet0), d=224.0.0.5, len 72, rcvd 0
00:34:17: IP: s=10.0.0.5 (Ethernet0), d=10.0.0.1, len 84, rcvd 0
00:34:17: IP: s=172.16.12.1 (local), d=224.0.0.5 (Serial0), len 84, sending
broad/multicast
00:34:17: IP: s=172.16.12.2 (Serial0), d=224.0.0.5, len 84, rcvd 0
00:34:18: IP: s=172.16.12.2 (Serial0), d=224.0.0.5, len 80, rcvd 0
00:34:18: IP: s=10.0.0.1 (local), d=10.0.0.5 (Ethernet0), len 84, sending
00:34:18: IP: s=10.0.0.3 (Ethernet0), d=224.0.0.5, len 80, rcvd 0
00:34:18: IP: s=10.0.0.5 (Ethernet0), d=10.0.0.1, len 84, rcvd 0
00:34:18: IP: s=10.0.0.1 (local), d=224.0.0.6 (Ethernet0), len 80, sending
broad/multicast
00:34:18: IP: s=10.0.0.5 (Ethernet0), d=10.0.0.1, len 64, rcvd 0
00:34:18: IP: s=172.16.12.1 (local), d=224.0.0.5 (Serial0), len 84, sending
broad/multicast
00:34:18: IP: s=172.16.12.2 (Serial0), d=224.0.0.5, len 84, rcvd 0
00:34:18: IP: s=172.16.12.1 (local), d=224.0.0.5 (Serial0), len 68, sending
broad/multicast
00:34:18: IP: s=10.0.0.1 (local), d=224.0.0.5 (Ethernet0), len 72, sending
broad/multicast
00:34:18: IP: s=10.0.0.5 (Ethernet0), d=224.0.0.5, len 84, rcvd 0
00:34:20: IP: s=10.0.0.3 (Ethernet0), d=224.0.0.5, len 84, rcvd 0
00:34:20: IP: s=10.0.0.1 (local), d=224.0.0.6 (Ethernet0), len 84, sending
broad/multicast
00:34:20: IP: s=172.16.12.1 (local), d=224.0.0.5 (Serial0), len 64, sending
broad/multicast
R1#u a
00:34:22: IP: s=10.0.0.3 (Ethernet0), d=224.0.0.5, len 72, rcvd 0
00:34:23: IP: s=172.16.12.2 (Serial0), d=224.0.0.5, len 84, rcvd 0
00:34:23: IP: s=10.0.0.3 (Ethernet0), d=224.0.0.5, len 84, rcvd 0
00:34:23: IP: s=10.0.0.1 (local), d=224.0.0.6 (Ethernet0), len 84, sending
broad/multicast
00:34:23: IP: s=10.0.0.5 (Ethernet0), d=10.0.0.1, len 84, rcvd 0
00:34:23: IP: s=10.0.0.5 (Ethernet0), d=224.0.0.5, len 84, rcvd 0ll
All possible debugging has been turned off
R1#
00:34:23: IP: s=10.0.0.5 (Ethernet0), d=224.0.0.5, len 80, rcvd 0
00:34:23: IP: s=172.16.12.1 (local), d=224.0.0.5 (Serial0), len 80, sending
broad/multicast
00:34:23: IP: s=172.16.12.2 (Serial0), d=224.0.0.5, len 80, rcvd 0
00:34:23: IP: s=10.0.0.3 (Ethernet0), d=224.0.0.5, len 84, rcvd 0
00:34:23: IP: s=172.16.12.2 (Serial0), d=224.0.0.5, len 84, rcvd 0
00:34:23: IP: s=172.16.12.1 (local), d=224.0.0.5 (Serial0), len 84, sending
broad/multicast
00:34:23: IP: s=10.0.0.5 (Ethernet0), d=224.0.0.5, len 84, rcvd 0
R1#

[b]Liwh à , cái debug interface state machine vì một lý do nào đó đã "biến mất" cu có giử thì post lên nhé.

yuna_admirer
25-11-2002, 13:25
Tiếp tục post : Đây là hoạt động của OSPF sau khi database đã build xong . OSPF chạy thuật giải SPF ( nói sau) để build bảng Route :
router s ospf 1
Rub(config-router)#area 1 stub
Rub(config-router)#^Z
Rub#
Rub#
02:02:22: %SYS-5-CONFIG_I: Configured from console by console
02:02:23: OSPF: running SPF for area 1
02:02:23: OSPF: Initializing to run spf
02:02:23: It is a router LSA 192.168.30.1. Link Count 3
02:02:23: Processing link 0, id 192.168.30.10, link data 192.168.30.9, type 1
02:02:23: No RTR Back link
02:02:23: Processing link 1, id 192.168.30.8, link data 255.255.255.248, type 3
02:02:23: Add better path to LSA ID 192.168.30.15, gateway 192.168.30.8, dist 64
02:02:23: Add path: next-hop 192.168.30.9, interface Serial1
02:02:23: Processing link 2, id 192.168.30.1, link data 255.255.255.255, type 3
02:02:23: Add better path to LSA ID 192.168.30.1, gateway 192.168.30.1, dist 1
02:02:23: Add path: next-hop 192.168.30.1, interface Loopback1
02:02:23: OSPF: Adding Stub nets
02:02:23: OSPF: delete lsa id 192.168.30.1, type 0, adv rtr 192.168.30.1 from delete list
02:02:23: OSPF: insert route list LS ID 192.168.30.1, type 0, adv rtr 192.168.30.1
02:02:23: OSPF: delete lsa id 192.168.30.15, type 0, adv rtr 192.168.30.1 from delete list
02:02:23: OSPF: insert route list LS ID 192.168.30.15, type 0, adv rtr 192.168.30.1
02:02:23: OSPF: Entered old delete routine
02:02:23: OSPF: Delete path to router 192.168.30.10 via 192.168.30.10 spf 13

02:02:23: OSPF: delete lsa id 192.168.30.10, type 1, adv rtr 192.168.30.10 from delete list
02:02:23: OSPF: running spf for summaries area 1
02:02:23: OSPF: Start processing Summary LSA 192.168.10.0, mask 255.255.255.224, adv 192.168.30.10, age 74, seq 0x80000004 (Area 1)
02:02:23: OSPF: ABR not reachable 192.168.30.10
02:02:23: OSPF: Start processing Summary LSA 192.168.10.32, mask 255.255.255.240, adv 192.168.30.10, age 74, seq 0x80000003 (Area 1)
02:02:23: OSPF: ABR not reachable 192.168.30.10
02:02:23: OSPF: Start processing Summary LSA 192.168.20.0, mask 255.255.255.252, adv 192.168.30.10, age 74, seq 0x80000004 (Area 1)
02:02:23: OSPF: ABR not reachable 192.168.30.10
02:02:23: OSPF: Start processing Summary LSA 192.168.20.2, mask 0.0.0.0, adv 192.168.30.10, age 74, seq 0x80000001 (Area 1)
02:02:23: OSPF: ABR not reachable 192.168.30.10
02:02:23: OSPF: sum_delete_old_routes area 1
02:02:23: OSPF: sum-Deleting old route 192.168.20.2
02:02:23: OSPF: Delete path to router 192.168.20.2 via 192.168.30.10 spf 13

02:02:23: OSPF: sum-Deleting old route 192.168.20.0
02:02:23: OSPF: sum-Deleting old route 192.168.10.32
02:02:23: OSPF: sum-Deleting old route 192.168.10.0
02:02:23: OSPF: delete lsa id 192.168.20.2, type 4, adv rtr 192.168.30.10 from delete list
02:02:23: OSPF: delete lsa id 192.168.20.0, type 3, adv rtr 192.168.30.10 from delete list
02:02:23: OSPF: delete lsa id 192.168.10.32, type 3, adv rtr 192.168.30.10 from delete list
02:02:23: OSPF: delete lsa id 192.168.10.0, type 3, adv rtr 192.168.30.10 from delete list
02:02:23: OSPF: Started Building Type 5 External Routes
02:02:23: OSPF: ex_delete_old_routes
02:02:23: OSPF: Started Building Type 7 External Routes
02:02:23: OSPF: ex_delete_old_routes
02:02:33: OSPF: running SPF for area 1
02:02:33: OSPF: Initializing to run spf
02:02:33: It is a router LSA 192.168.30.1. Link Count 2
02:02:33: Processing link 0, id 192.168.30.8, link data 255.255.255.248, type 3
02:02:33: Add better path to LSA ID 192.168.30.15, gateway 192.168.30.8, dist 64
02:02:33: Add path: next-hop 192.168.30.9, interface Serial1
02:02:33: Processing link 1, id 192.168.30.1, link data 255.255.255.255, type 3
02:02:33: Add better path to LSA ID 192.168.30.1, gateway 192.168.30.1, dist 1
02:02:33: Add path: next-hop 192.168.30.1, interface Loopback1
02:02:33: OSPF: Adding Stub nets
02:02:33: OSPF: delete lsa id 192.168.30.1, type 0, adv rtr 192.168.30.1 from delete list
02:02:33: OSPF: insert route list LS ID 192.168.30.1, type 0, adv rtr 192.168.30.1
02:02:33: OSPF: delete lsa id 192.168.30.15, type 0, adv rtr 192.168.30.1 from delete list
02:02:33: OSPF: insert route list LS ID 192.168.30.15, type 0, adv rtr 192.168.30.1
02:02:33: OSPF: Entered old delete routine
02:02:33: OSPF: running spf for summaries area 1
02:02:33: OSPF: Start processing Summary LSA 192.168.10.0, mask 255.255.255.224, adv 192.168.30.10, age 84, seq 0x80000004 (Area 1)
02:02:33: OSPF: ABR not reachable 192.168.30.10
02:02:33: OSPF: Start processing Summary LSA 192.168.10.32, mask 255.255.255.240, adv 192.168.30.10, age 84, seq 0x80000003 (Area 1)
02:02:33: OSPF: ABR not reachable 192.168.30.10
02:02:33: OSPF: Start processing Summary LSA 192.168.20.0, mask 255.255.255.252, adv 192.168.30.10, age 84, seq 0x80000004 (Area 1)
02:02:33: OSPF: ABR not reachable 192.168.30.10
02:02:33: OSPF: Start processing Summary LSA 192.168.20.2, mask 0.0.0.0, adv 192.168.30.10, age 84, seq 0x80000001 (Area 1)
02:02:33: OSPF: ABR not reachable 192.168.30.10
02:02:33: OSPF: sum_delete_old_routes area 1
02:02:33: OSPF: Started Building Type 5 External Routes
02:02:33: OSPF: ex_delete_old_routes
02:02:33: OSPF: Started Building Type 7 External Routes
02:02:33: OSPF: ex_delete_old_routes
Rub#sh ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, * - candidate default
U - per-user static route, o - ODR

Gateway of last resort is not set

192.168.30.0/29 is subnetted, 2 subnets
C 192.168.30.0 is directly connected, Loopback1
C 192.168.30.8 is directly connected, Serial1
172.16.0.0/24 is subnetted, 1 subnets
C 172.16.2.0 is directly connected, Ethernet0
10.0.0.0/24 is subnetted, 1 subnets
C 10.1.1.0 is directly connected, Loopback0
Rub#
02:03:05: OSPF: Detect change in LSA type 1, LSID 192.168.30.10, from 192.168.30.10 area 1
02:03:05: OSPF: Detect change in LSA type 3, LSID 192.168.20.0, from 192.168.30.10 area 1
02:03:05: OSPF: Schedule partial SPF - type 3 id 192.168.20.0 adv rtr 192.168.30.10
02:03:05: OSPF: Detect change in LSA type 3, LSID 192.168.10.32, from 192.168.30.10 area 1
02:03:05: OSPF: Schedule partial SPF - type 3 id 192.168.10.32 adv rtr 192.168.30.10
02:03:05: OSPF: Detect change in LSA type 3, LSID 192.168.10.0, from 192.168.30.10 area 1
02:03:05: OSPF: Schedule partial SPF - type 3 id 192.168.10.0 adv rtr 192.168.30.10
02:03:05: OSPF: Schedule partial SPF - type 3 id 0.0.0.0 adv rtr 192.168.30.10
02:03:05: OSPF: Service partial SPF 4/0/0
02:03:05: OSPF: Start partial processing Summary LSA 192.168.20.0, mask 255.255.255.252, adv 192.168.30.10, age 11, seq 0x80000005 (Area 1)
02:03:05: OSPF: ABR not reachable 192.168.30.10
02:03:05: OSPF: delete lsa id 192.168.20.0, type 3, adv rtr 192.168.30.10 from delete list
02:03:05: OSPF: lsa id 192.168.20.0 not on delete list
02:03:05: OSPF: Start partial processing Summary LSA 192.168.10.32, mask 255.255.255.240, adv 192.168.30.10, age 11, seq 0x80000004 (Area 1)
02:03:05: OSPF: ABR not reachable 192.168.30.10
02:03:05: OSPF: delete lsa id 192.168.10.32, type 3, adv rtr 192.168.30.10 from delete list
02:03:05: OSPF: lsa id 192.168.10.32 not on delete list
02:03:05: OSPF: Start partial processing Summary LSA 192.168.10.0, mask 255.255.255.224, adv 192.168.30.10, age 11, seq 0x80000005 (Area 1)
02:03:05: OSPF: ABR not reachable 192.168.30.10
02:03:05: OSPF: delete lsa id 192.168.10.0, type 3, adv rtr 192.168.30.10 from delete list
02:03:05: OSPF: lsa id 192.168.10.0 not on delete list
02:03:05: OSPF: Start partial processing Summary LSA 0.0.0.0, mask 0.0.0.0, adv 192.168.30.10, age 11, seq 0x80000001 (Area 1)
02:03:05: OSPF: ABR not reachable 192.168.30.10
02:03:05: OSPF: delete lsa id 0.0.0.0, type 3, adv rtr 192.168.30.10 from delete list
02:03:05: OSPF: lsa id 0.0.0.0 not on delete list
02:03:10: OSPF: running SPF for area 1
02:03:10: OSPF: Initializing to run spf
02:03:10: It is a router LSA 192.168.30.1. Link Count 3
02:03:10: Processing link 0, id 192.168.30.10, link data 192.168.30.9, type 1
02:03:10: No RTR Back link
02:03:10: Processing link 1, id 192.168.30.8, link data 255.255.255.248, type 3
02:03:10: Add better path to LSA ID 192.168.30.15, gateway 192.168.30.8, dist 64
02:03:10: Add path: next-hop 192.168.30.9, interface Serial1
02:03:10: Processing link 2, id 192.168.30.1, link data 255.255.255.255, type 3
02:03:10: Add better path to LSA ID 192.168.30.1, gateway 192.168.30.1, dist 1
02:03:10: Add path: next-hop 192.168.30.1, interface Loopback1
02:03:10: OSPF: Adding Stub nets
02:03:10: OSPF: delete lsa id 192.168.30.1, type 0, adv rtr 192.168.30.1 from delete list
02:03:10: OSPF: insert route list LS ID 192.168.30.1, type 0, adv rtr 192.168.30.1
02:03:10: OSPF: delete lsa id 192.168.30.15, type 0, adv rtr 192.168.30.1 from delete list
02:03:10: OSPF: insert route list LS ID 192.168.30.15, type 0, adv rtr 192.168.30.1
02:03:10: OSPF: Entered old delete routine
02:03:10: OSPF: running spf for summaries area 1
02:03:10: OSPF: Start processing Summary LSA 0.0.0.0, mask 0.0.0.0, adv 192.168.30.10, age 16, seq 0x80000001 (Area 1)
02:03:10: OSPF: ABR not reachable 192.168.30.10
02:03:10: OSPF: Start processing Summary LSA 192.168.10.0, mask 255.255.255.224, adv 192.168.30.10, age 16, seq 0x80000005 (Area 1)
02:03:10: OSPF: ABR not reachable 192.168.30.10
02:03:10: OSPF: Start processing Summary LSA 192.168.10.32, mask 255.255.255.240, adv 192.168.30.10, age 16, seq 0x80000004 (Area 1)
02:03:10: OSPF: ABR not reachable 192.168.30.10
02:03:10: OSPF: Start processing Summary LSA 192.168.20.0, mask 255.255.255.252, adv 192.168.30.10, age 16, seq 0x80000005 (Area 1)
02:03:10: OSPF: ABR not reachable 192.168.30.10
02:03:10: OSPF: Start processing Summary LSA 192.168.20.2, mask 0.0.0.0, adv 192.168.30.10, age 121, seq 0x80000001 (Area 1)
02:03:10: OSPF: ABR not reachable 192.168.30.10
02:03:10: OSPF: sum_delete_old_routes area 1
02:03:10: OSPF: Started Building Type 5 External Routes
02:03:10: OSPF: ex_delete_old_routes
02:03:10: OSPF: Started Building Type 7 External Routes
02:03:10: OSPF: ex_delete_old_routes
02:03:10: OSPF: Detect change in LSA type 1, LSID 192.168.30.10, from 192.168.30.10 area 1
Rub#
02:03:20: OSPF: running SPF for area 1
02:03:20: OSPF: Initializing to run spf
02:03:20: It is a router LSA 192.168.30.1. Link Count 3
02:03:20: Processing link 0, id 192.168.30.10, link data 192.168.30.9, type 1
02:03:20: Add better path to LSA ID 192.168.30.10, gateway 192.168.30.10, dist 64
02:03:20: Add path: next-hop 192.168.30.10, interface Serial1
02:03:20: Processing link 1, id 192.168.30.8, link data 255.255.255.248, type 3
02:03:20: Add better path to LSA ID 192.168.30.15, gash ip roteway 192.168.30.8, dist 64
02:03:20: Add path: next-hop 192.168.30.9, interface Serial1
02:03:20: Processing link 2, id 192.168.30.1, link data 255.255.255.255, type 3
02:03:20: Add better path to LSA ID 192.168.30.1, gateway 192.168.30.1, dist 1
02:03:20: Add path: next-hop 192.168.30.1, interface Loopback1
02:03:20: OSPF: Add Router Route to 192.168.30.10 via 192.168.30.10. Metric: 64
02:03:20: OSPF: insert route list LS ID 192.168.30.10, type 1, adv rtr 192.168.30.10
02:03:20: It is a ute
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, * - candidate default
U - per-user static route, o - ODR

Gateway of last resort is 192.168.30.10 to network 0.0.0.0

192.168.30.0/29 is subnetted, 2router LSA 192.168.30.10. Link Count 2
02:03:20: Processing link 0, id 192.168.30.1, link data 192.168.30.10, type 1
02:03:20: Ignore newdist 128 olddist 0
02:03:20: Processing link 1, id 192.168.30.8, link data 255.255.255.248, type 3
02:03:20: Add better path to LSA ID 192.168.30.15, gateway 192.168.30.8, dist 128
02:03:20: Add path: next-hop 192.168.30.10, interface subnets
C 192.168.30.0 is directly connected, Loopback1
C 192.168.30.8 is directly connected, Serial1
192.168.10.0/24 is variably subnetted, 2 subnets, 2 masks
O IA 192.168.10.32/28 [110/202] via 192.168.30.10, 00:00:02, Serial1
O IA 192.168.10.0/27 [110/192] via 192.168.30.10, 00:00:02, Serial1
172.16.0.0/24 is subnetted, 1 subnets
C 172.16.2.0 is directly connected, Ethernet0
192.168.20.0/30 is subnetted, 1 subnets
O IA 192.168.20.0 [110/128] via 192.168.30.10, 00:00:02, Serial1
10.0.0.0/24 is subnetted, 1 subnets
C 10.1.1.0 is directly coSerial1
02:03:20: OSPF: Adding Stub nets
02:03:20: OSPF: delete lsa id 192.168.30.1, type 0, adv rtr 192.168.30.1 from delete list
02:03:20: OSPF: insert route list LS ID 192.168.30.1, type 0, adv rtr 192.168.30.1
02:03:20: OSPF: delete lsa id 192.168.30.15, type 0, adv rtr 192.168.30.1 from delete list
02:03:20: OSPF: insert route list LS ID 192.168.30.15, type 0, annected, Loopback0
O*IA 0.0.0.0/0 [110/65] via 192.168.30.10, 00:00:03, Serial1
Rub#dv rtr 192.168.30.1
02:03:20: OSPF: Entered old delete routine
02:03:20: OSPF: running spf for summaries area 1
02:03:20: OSPF: Start processing Summary LSA 0.0.0.0, mask 0.0.0.0, adv 192.168.30.10, age 26, seq 0x80000001 (Area 1)
02:03:20: Add better path to LSA ID 0.0.0.0, gateway 0.0.0.0, dist 65
02:03:20: Add path: next-hop 192.168.30.10, interface Serial1
02:03:20: Add Summary Route to 0.0.0.0. Metric: 65, Next Hop: 192.168.30.10
02:03:20: OSPF: insert route list LS ID 0.0.0.0, type 3, adv rtr 192.168.30.10
02:03:20: OSPF: Start processing Summary LSA 192.168.10.0, mask 255.255.255.224, adv 192.168.30.10, age 26, seq 0x80000005 (Area 1)
02:03:20: Add better path to LSA ID 192.168.10.0, gateway 0.0.0.0, dist 192
02:03:20: Add path: next-hop 192.168.30.10, interface Serial1
02:03:20: Add Summary Route to 192.168.10.0. Metric: 192, Next Hop: 192.168.30.10
02:03:20: OSPF: insert route list LS ID 192.168.10.0, type 3, adv rtr 192.168.30.10
02:03:20: OSPF: Start processing Summ
Rub#ary LSA 192.168.10.32, mask 255.255.255.240, adv 192.168.30.10, age 26, seq 0x80000004 (Area 1)
02:03:20: Add better path to LSA ID 192.168.10.32, gateway 0.0.0.0, dist 202
02:03:20: Add path: next-hop 192.168.30.10, interface Serial1
02:03:20: Add Summary Route to 192.168.10.32. Metric: 202, Next Hop: 192.168.30.10
02:03:20: OSPF: insert route list LS ID 192.168.10.32, type 3, adv rtr 192.168.30.10
02:03:20: OSPF: Start processing Summary LSA 192.168.20.0, mask 255.255.255.252, adv 192.168.30.10, age 26, seq 0x80000005 (Area 1)
02:03:20: Add better path to LSA ID 192.168.20.0, gateway 0.0.0.0, dist 128
02:03:20: Add path: next-hop 192.168.30.10, interface Serial1
02:03:20: Add Summary Route to 192.168.20.0. Metric: 128, Next Hop: 192.168.30.10
02:03:20: OSPF: insert route list LS ID 192.168.20.0, type 3, adv rtr 192.168.30.10
02:03:20: OSPF: Start processing Summary LSA 192.168.20.2, mask 0.0.0.0, adv 192.168.30.10, age 131, seq 0x80000001 (Area 1)
02:03:20: Add better path to LSA ID 192.168.20.2, gateway 0.0.0.0, dist 128
02:03:20: Add path: next-hop 192.168.30.10, interface Serial1
02:03:20: OSPF: Add Router Route to 192.168.20.2 from summary ASBR LSA. Metric: 128
02:03:20: OSPF: insert route list LS ID 192.168.20.2, type 4, adv rtr 192.168.30.10
02:03:20: OSPF: sum_delete_old_routes area 1
02:03:20: OSPF: Started Building Type 5 External Routes
02:03:20: OSPF: ex_delete_old_routes
02:03:20: OSPF: Started Building Type 7 External Routes
02:03:20: OSPF: ex_delete_old_routes
Rub#sh ip route
Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP
D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP
i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, * - candidate default
U - per-user static route, o - ODR

Gateway of last resort is 192.168.30.10 to network 0.0.0.0

192.168.30.0/29 is subnetted, 2 subnets
C 192.168.30.0 is directly connected, Loopback1
C 192.168.30.8 is directly connected, Serial1
192.168.10.0/24 is variably subnetted, 2 subnets, 2 masks
O IA 192.168.10.32/28 [110/202] via 192.168.30.10, 00:00:16, Serial1
O IA 192.168.10.0/27 [110/192] via 192.168.30.10, 00:00:16, Serial1
172.16.0.0/24 is subnetted, 1 subnets
C 172.16.2.0 is directly connected, Ethernet0
192.168.20.0/30 is subnetted, 1 subnets
O IA 192.168.20.0 [110/128] via 192.168.30.10, 00:00:16, Serial1
10.0.0.0/24 is subnetted, 1 subnets
C 10.1.1.0 is directly connected, Loopback0
O*IA 0.0.0.0/0 [110/65] via 192.168.30.10, 00:00:17, Serial1
Rub#u all
All possible debugging has been turned off
Rub#

yuna_admirer
25-11-2002, 14:21
Reset ALL OSPF processes? [no]:
00:11:20: OSPF: Rcv hello from 192.168.1.1 area 0 from Serial1 192.168.1.1
00:11:20: OSPF: End of hello processingy
AC#
AC#
AC#
AC#
AC#
00:11:22: OSPF: Interface Serial1 going Down
00:11:22: OSPF: 10.1.1.1 address 192.168.1.2 on Serial1 is dead, state DOWN
00:11:22: OSPF: 192.168.1.1 address 192.168.1.1 on Serial1 is dead, state DOWN
00:11:22: OSPF: Interface Serial1 going Up
00:11:23: OSPF: Build router LSA for area 0, router ID 10.1.1.1, seq 0x80000001
00:11:30: OSPF: Rcv hello from 192.168.1.1 area 0 from Serial1 192.168.1.1
00:11:30: OSPF: 2 Way Communication to 192.168.1.1 on Serial1, state 2WAY
00:11:30: OSPF: Send DBD to 192.168.1.1 on Serial1 seq 0x2384 opt 0x2 flag 0x7 len 32
00:11:30: OSPF: End of hello processing
00:11:30: OSPF: Rcv DBD from 192.168.1.1 on Serial1 seq 0x8CF opt 0x2 flag 0x7 len 32 mtu 1500 state EXSTART
00:11:30: OSPF: NBR Negotiation Done. We are the SLAVE
00:11:30: OSPF: Send DBD to 192.168.1.1 on Serial1 seq 0x8CF opt 0x2 flag 0x2 len 52
00:11:30: OSPF: Rcv DBD from 192.168.1.1 on Serial1 seq 0x8D0 opt 0x2 flag 0x3 len 52 mtu 1500 state EXCHANGE
00:11:30: OSPF: Send DBD to 192.168.1.1 on Serial1 seq 0x8D0 opt 0x2 flag 0x0 len 32
00:11:30: OSPF: Database request to 192.168.1.1
00:11:30: OSPF: sent LS REQ packet to 192.168.1.1, length 12
00:11:30: OSPF: Rcv DBD from 192.168.1.1 on Serial1 seq 0x8D1 opt 0x2 flag 0x1 len 32 mtu 1500 state EXCHANGE
00:11:30: OSPF: Exchange Done with 192.168.1.1 on Serial1
00:11:30: OSPF: Send DBD to 192.168.1.1 on Serial1 seq 0x8D1 opt 0x2 flag 0x0 len 32
00:11:30: OSPF: Synchronized with 192.168.1.1 on Serial1, state FULL
00:11:31: OSPF: Build router LSA for area 0, router ID 10.1.1.1, seq 0x80000002
00:11:36: OSPF: Build router LSA for area 0, router ID 10.1.1.1, seq 0x80000007
00:11:40: OSPF: Rcv hello from 192.168.1.1 area 0 from Serial1 192.168.1.1
00:11:40: OSPF: End of hello processing
AC#


AC#
00:11:50: OSPF: Rcv hello from 192.168.1.1 area 0 from Serial1 192.168.1.1
00:11:50: OSPF: End of hello processing
AC#

yuna_admirer
26-11-2002, 10:24
Ở trên là thuật toán SPF khi có thay đổi trong Topology
Ở dưới là Interface neighbor State Machine . Chú ý : nó sẻ qua các giai đoạn : Down - Up - 2way - Exstart - Exchange - FUll

Liwh
28-11-2002, 05:17
Liwh mới vừa viết xong, các bạn đọc thử rồi cho ý kiến hen. Còn IS-IS và BGP chưa xong, để Liwh nghiên cứu 2 phần đó xong sẽ viết tiếp vào luôn.
Enjoy this

RIP
Routing Update: 30 seconds (change with "timers basic <update> <invalid> <holddown> <flush>")
Invalid Timer: 180 seconds
Holddown Timer: 180 seconds
Flush Timer: 210 seconds. not sure

IGRP
Routing update: 90 seconds (change with "timers basic <update> <invalid> <holddown> <flush> [sleep_in_miliseconds]")
Invalid Timer: 270 seconds. If invalid timer expire before recieving update, this route entry mark as unreachable.
Holddown Timer: 280 seconds. If receive a worse metric for an route entry, in this time no new information about that route entry be accepted .
Flush Timer: 630 seconds. After this time, the entry will be flush out of the routing table.
Sleep: when a router receive a new trigger update, it wait for sleep time to recalculate its routing table.

EIGRP
Neighbor Discovery/Maintain
Hello Interval: 60 seconds for lower-than-T1-link, 5 seconds for others (change with "ip helo-interval eigrp <process_id> <seconds>")
Hold time: 3 times Hello Interval
DUAL
Active timer: 3 minutes (change with "timers active-time <minutes|disable>")

OSPF
Neighbor Discovery/Maintain
Hello Interval: 30 seconds for NBMA, 10 seconds for others. (change with "ip ospf hello-interval <seconds>")
DeadInterval: four times the Hello Interval (change with ip ospf dead-interval <seconds>)
Wait Timer: equals to Dead Interval, when wait timers expires the election of DR/BDR begin.
Poll Interval: 60 seconds
Interface:
InfTransDelay: Interface Transmit Delay, 1 second (change with "ip ospf transmit-delay <seconds>")
LSA Flooding:
Rxmt Interval: Retransmit Interval, 5 seconds (change with "ip ospf retransmit-interval <seconds>") : retransmit the OSPF packet that has not been acknowledge
LSRefresh Interval: 1800 seconds (30 minutes), check there LSA Database
LSA group-pacing timer: 240 seconds (change with "timers lsa-group-pacing <seconds>"). I don't understand about this timer much, can anyone help me ?
MaxAge: 3600 seconds
SPF timer: 10 seconds (change with "timers spf <seconds>") : determine how long to calculate the LSDatabase after recieving LSUpdate.

IS-IS maybe in the next time

EGP
Neighbor Acquisition Protocol
Neighbor Acquisition Request : resend after 30 seconds if no confirm
3 Neighbor Acquisition Request means 90 seconds --> transition from Acquire to Idle
Idle Remaining timer : 300 seconds --> transition to Acquire state
Neighbor Reachability Protocol
Hello Interval: 60 seconds (change with "timers egp <[hello_interval]|[poll_interval]>")
3 Hello means 180 seconds --> change state to Cease
Neighbor Cease message interval: 60 seconds
3 Cease means 180 seconds --> change state to Idle
Idle Remaining timer : 300 seconds --> transition to Acquire state
Network Reachability Protocol
Poll Interval: 180 seconds (change with "timers egp <[hello_interval]|[poll_interval]>")
2 Poll means 360 seconds --> change state to Down, Cease

BGPv4 maybe in the next time

Thân
Liwh

yuna_admirer
28-11-2002, 09:39
Hay lắm , hay nhất là câu "I love you Suong Mai"

Neo
28-11-2002, 10:04
Hê hê, càng thất tình xuất chiêu càng dzữ

Một chút ý kiến nè:

Mọi người hỏng rãnh để đọc hết đâu.
Điều quan trọng của 1 bài viết là trình bày vấn đề theo cách hiểu của mình, nói được cái hay của vấn đề.
Lúc đó bài viết sẽ hay hơn :D

yuna_admirer
28-11-2002, 21:57
Thứ 7 này làm seminar OSPF , liwh nhận được slide của anh Minh chưa ?

Liwh
29-11-2002, 09:52
Cái bài này Liwh tự viết mà. Nghiên cứu rồi đó. Vì thấy các bạn khi thi cần, Liwh viết ra để dễ coi.
Thân

Neo
29-11-2002, 11:56
Hic, tui nói tên yuna í.
Liwh viết thì dễ hiểu rồi:)

yuna_admirer
29-11-2002, 21:37
:o :o :o :o :o :o :o :o :o :o :o :o :o :o :o