OSPF Deep Dive: LSA Types, Areas, NSSA, Virtual Links, Stub Areas และ Route Summarization

OSPF Deep Dive: LSA Types, Areas, NSSA, Virtual Links, Stub Areas และ Route Summarization

OSPF (Open Shortest Path First) เป็น link-state routing protocol ที่ใช้กันมากที่สุดใน enterprise networks LSA Types กำหนดข้อมูลที่แต่ละ router โฆษณา, Areas แบ่ง network เพื่อ scalability, NSSA ให้ flexibility สำหรับ external routes ใน stub areas, Virtual Links เชื่อม disconnected areas กลับไปหา backbone, Stub Areas ลด routing table size และ Route Summarization ลด LSA flooding

OSPF ใช้ Dijkstra’s SPF algorithm คำนวณ shortest path tree จาก link-state database ที่ทุก router ใน area เดียวกันมีเหมือนกัน เมื่อ network มี 1000+ routers การใส่ทุกอย่างใน single area ทำให้ SPF calculation ช้า, LSA flooding มาก, routing table ใหญ่ → ต้องใช้ hierarchical design ด้วย areas เพื่อ scale

OSPF LSA Types

LSA Type Name Generated By Scope
Type 1 Router LSA Every router Within area (lists router’s links and costs)
Type 2 Network LSA DR (Designated Router) Within area (describes multi-access network)
Type 3 Summary LSA ABR (Area Border Router) Between areas (inter-area routes)
Type 4 ASBR Summary LSA ABR Between areas (tells how to reach ASBR)
Type 5 External LSA ASBR (AS Boundary Router) Entire OSPF domain (external routes)
Type 7 NSSA External LSA ASBR in NSSA Within NSSA (converted to Type 5 at ABR)

OSPF Area Types

Area Type LSA 1,2 LSA 3 LSA 4,5 LSA 7 Default Route
Normal Optional
Stub ABR injects default
Totally Stubby ✗ (only default) ABR injects default only
NSSA Optional (not automatic)
Totally NSSA ✗ (only default) ABR injects default only

Area Design

Component Role Best Practice
Area 0 (Backbone) Central area — all other areas must connect to Area 0 Keep backbone stable, redundant ABR connections
ABR Router on boundary of 2+ areas (has LSDB for each area) Summarize routes at ABR → reduce inter-area LSAs
ASBR Router that redistributes external routes into OSPF Filter external routes, tag with route-map
Internal Router All interfaces in single area Most routers — simple config
Area Size Recommended: 50-200 routers per area Too big = slow SPF, too small = too many ABRs

Stub Areas

Feature รายละเอียด
Purpose ลดขนาด LSDB และ routing table โดย block Type 4,5 LSAs (external routes)
Stub Area No external routes → ABR injects default route แทน (Type 3 LSA ยังมี)
Totally Stubby No external + no inter-area → ABR injects default route only (smallest routing table)
Restriction ไม่มี ASBR ใน stub area (ไม่สามารถ redistribute routes เข้า stub)
Use Case Remote sites ที่ต้องการ simple routing — ทุก traffic ออกผ่าน ABR ด้วย default route

NSSA (Not-So-Stubby Area)

Feature รายละเอียด
Purpose เหมือน stub area แต่อนุญาตให้มี ASBR → redistribute external routes เป็น Type 7 LSA
Type 7 → Type 5 ABR แปลง Type 7 เป็น Type 5 ก่อน flood ไป area อื่น
Default Route ไม่ auto-inject default (ต้อง config manually: area X nssa default-information-originate)
Totally NSSA NSSA + block inter-area routes → only default + Type 7 (smallest + external allowed)
Use Case Remote site ที่มี connection ไป external network (เช่น internet, partner) ต้อง redistribute

Virtual Links

Feature รายละเอียด
Purpose เชื่อม area ที่ไม่ได้ connect กับ Area 0 โดยตรง (ผ่าน transit area)
How Logical link ระหว่าง 2 ABRs ผ่าน non-backbone area → extend Area 0
Config area [transit-area] virtual-link [remote-ABR-router-id] (บนทั้ง 2 ABRs)
Limitation Transit area ต้องไม่ใช่ stub area (ต้อง carry Type 5 LSAs)
Best Practice Virtual links = temporary fix → redesign network ให้ทุก area connect Area 0 directly

Route Summarization

Type Where Command
Inter-Area Summarization ABR (summarize routes เข้า/ออก area) area [area-id] range [network] [mask]
External Summarization ASBR (summarize redistributed routes) summary-address [network] [mask]
Benefit ลด LSA count, ลด routing table size, ลด SPF calculation
Discard Route Summarization สร้าง discard route (Null0) → ป้องกัน routing loops Automatic
Best Practice ออกแบบ IP addressing scheme ที่ contiguous per area → summarize ง่าย

OSPF Timers and Convergence

Timer Default Tuning
Hello 10s (broadcast/P2P), 30s (NBMA) ลดเป็น 1-3s สำหรับ fast detection (BFD ดีกว่า)
Dead 4× Hello (40s default) ลดตาม Hello
SPF Delay 5s initial, 10s hold ใช้ exponential backoff: spf-delay 50ms, spf-holdtime 200ms
LSA Throttle 5s initial lsa-throttle 50ms 200ms 5000ms (aggressive)
BFD Not enabled Enable BFD สำหรับ sub-second failure detection (50-300ms)

ทิ้งท้าย: OSPF = Hierarchical Design for Scalable Routing

OSPF Deep Dive LSA Types: Type 1 (router), Type 2 (network/DR), Type 3 (inter-area/ABR), Type 5 (external/ASBR), Type 7 (NSSA) Areas: Normal (all LSAs), Stub (no external), Totally Stubby (default only), NSSA (stub + external Type 7) Design: Area 0 backbone, ABR summarization, 50-200 routers/area, contiguous IP per area NSSA: stub area that allows redistribution (Type 7 → Type 5 at ABR) Virtual Links: temporary fix for disconnected areas (extend Area 0 through transit area) Summarization: inter-area (ABR range), external (ASBR summary-address) → reduce LSA + table size Key: hierarchical OSPF design with proper area types + summarization = scalable, fast-converging network

อ่านเพิ่มเติมเกี่ยวกับ BGP Deep Dive Path Attributes Route Selection และ MPLS Deep Dive Labels LSP LDP ที่ siamlancard.com หรือจาก icafeforex.com และ siam2r.com

จัดส่งรวดเร็วส่งด่วนทั่วประเทศ
รับประกันสินค้าเคลมง่าย มีใบรับประกัน
ผ่อนชำระได้บัตรเครดิต 0% สูงสุด 10 เดือน
สะสมแต้ม รับส่วนลดส่วนลดและคะแนนสะสม

© 2026 SiamLancard — จำหน่ายการ์ดแลน อุปกรณ์ Server และเครื่องพิมพ์ใบเสร็จ

SiamLancard
Logo
Free Forex EA Download — XM Signal · EA Forex ฟรี
iCafeForex.com - สอนเทรด Forex | SiamCafe.net
Shopping cart