8. OSPF的NSSA详解

1. OSPF的NSSA(not so stub area)区域

  • 不接收5类LSA,但是可以引入外部路由,引入一种新的7类的NSSA的LSA

  • 场景:一个分支现在不接收5类LSA,同时还要在本区域得到默认路由去指向运行商而不是总公司(area 0)

[SW3-ospf-1]ar
[SW3-ospf-1]area 15
[SW3-ospf-1-area-0.0.0.15]
[SW3-ospf-1-area-0.0.0.15]nssa 
Error: The specified area has been configured as a STUB area. //需要先拿掉STUB的配置,然后再配置NSSA

[R5-ospf-1-area-0.0.0.15]dis th
[V200R003C00]
#
 area 0.0.0.15 
  nssa   //该区域中所有设备都配置nssa,否则NP位不一致,导致无法建立邻居
  
  
  
[SW3-ospf-1-area-0.0.0.15]dis ospf peer brief 

         OSPF Process 1 with Router ID 13.13.13.13
                  Peer Statistic Information
----------------------------------------------------------------------------
 Area Id          Interface                        Neighbor id      State    
 0.0.0.15         Vlanif30                         0.0.0.1          Full        

 0.0.0.15         Vlanif30                         5.5.5.5          Full        




[SW3]dis ip routing-table protocol ospf

Route Flags: R - relay, D - download to fib
Public routing table : OSPF
         Destinations : 13       Routes : 14       
OSPF routing table status : <Active>
         Destinations : 13       Routes : 14
Destination/Mask    Proto   Pre  Cost      Flags NextHop         Interface

        0.0.0.0/0   O_NSSA  150  1           D   10.1.15.1       Vlanif30
                    O_NSSA  150  1           D   10.1.15.5       Vlanif30 //华为设备上默认从ABR(s)处得到7类LSA产生的默认路由,这点在思科设备上不会自动产生
       10.1.1.1/32  OSPF    10   1           D   10.1.15.1       Vlanif30
       10.1.1.4/32  OSPF    10   49          D   10.1.15.1       Vlanif30
       10.1.1.5/32  OSPF    10   1           D   10.1.15.5       Vlanif30
      10.1.34.0/24  OSPF    10   97          D   10.1.15.1       Vlanif30
      10.1.35.0/24  OSPF    10   2           D   10.1.15.5       Vlanif30
      10.1.56.0/24  OSPF    10   49          D   10.1.15.5       Vlanif30
       11.1.1.1/32  OSPF    10   1           D   10.1.15.1       Vlanif30
       33.1.1.1/32  OSPF    10   2           D   10.1.15.5       Vlanif30
       44.1.1.1/32  OSPF    10   49          D   10.1.15.1       Vlanif30
       55.1.1.1/32  OSPF    10   1           D   10.1.15.5       Vlanif30
       66.1.1.1/32  OSPF    10   49          D   10.1.15.5       Vlanif30
      100.1.1.1/32  O_NSSA  150  1           D   10.1.15.1       Vlanif30 //不同于STUB区域,此时NSSA区域得到了本区域引入的7类LSA产生的外部路由(其他区域引入的外部路由通过默认路由去访问)


[R6-ospf-1]import-route direct

[SW3]dis ip routing-table protocol ospf   //NSSA内部的设备看不到其他区域引入的外部路由,但是可以通过默认路由去访问

Route Flags: R - relay, D - download to fib

Public routing table : OSPF
         Destinations : 13       Routes : 14       

OSPF routing table status : <Active>
         Destinations : 13       Routes : 14

Destination/Mask    Proto   Pre  Cost      Flags NextHop         Interface

        0.0.0.0/0   O_NSSA  150  1           D   10.1.15.1       Vlanif30
                    O_NSSA  150  1           D   10.1.15.5       Vlanif30
       10.1.1.1/32  OSPF    10   1           D   10.1.15.1       Vlanif30
       10.1.1.4/32  OSPF    10   49          D   10.1.15.1       Vlanif30
       10.1.1.5/32  OSPF    10   1           D   10.1.15.5       Vlanif30
      10.1.34.0/24  OSPF    10   97          D   10.1.15.1       Vlanif30
      10.1.35.0/24  OSPF    10   2           D   10.1.15.5       Vlanif30
      10.1.56.0/24  OSPF    10   49          D   10.1.15.5       Vlanif30
       11.1.1.1/32  OSPF    10   1           D   10.1.15.1       Vlani
  • 0
    点赞
  • 28
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值