OSPF配置常用命令知识总结

1.display ospf abr-asbr 命令用来显示OSPF的区域边界路由器和自治系统边界路由器信息。

[R3]dis ospf abr-asbr

OSPF Process 1 with Router ID 20.1.3.0
Routing Table to ABR and ASBR

Rt Type       Destination    Area    Cost   Nexthop       Type
Intra-area    30.3.6.0       0.0.0.0    3      192.168.34.4           ABR

2.display ospf lsdb 命令用来显示OSPF的链路状态数据库(LSDB)信息。

[R3]display ospf lsdb

OSPF Process 1 with Router ID 20.1.3.0
Link State Database

Area: 0.0.0.0
Type      LinkState ID     AdvRouter    Age    Len   Sequence   Metric
Router        20.1.3.0      20.1.3.0      1264     36     80000004    1
Router        0.2.5.0        0.2.5.0       1257    48    80000007    1
Network    192.168.56.6    30.3.6.0       1259   32    80000001    0
Network    192.168.34.3    20.1.3.0      1264    32    80000001    0

3.display ospf peer brief //查看OSPF邻接表

[R3]display ospf peer brief

OSPF Process 1 with Router ID 20.1.3.0
Peer Statistic Information
----------------------------------------------------------------------------
Area Id   Interface         Neighbor id   State
0.0.0.0      GigabitEthernet0/0/2      0.2.4.0           Full
0.0.0.20    GigabitEthernet0/0/0     20.1.2.0         Full
0.0.0.20    GigabitEthernet0/0/1          20.1.1.0               Full
----------------------------------------------------------------------------

4.display ip routing-table protocol ospf  //查看OSPF路由表

[R3]display ip routing-table protocol ospf
Route Flags: R - relay, D - download to fib
------------------------------------------------------------------------------
Public routing table : OSPF
Destinations : 5 Routes : 6

OSPF routing table status : <Active>
Destinations : 5 Routes : 6

Destination/Mask    Proto    Pre    Cost    Flags   NextHop     Interface

192.168.12.0/24      OSPF    10    2      D    192.168.13.1    GigabitEthernet0/0/1
           OSPF    10    2      D    192.168.23.2    GigabitEthernet0/0/0
192.168.20.0/24      OSPF    10    2     D    192.168.13.1    GigabitEthernet0/0/1
192.168.45.0/24      OSPF    10    2      D    192.168.34.4    GigabitEthernet0/0/2
192.168.56.0/24      OSPF       10    3      D    192.168.34.4    GigabitEthernet0/0/2
192.168.67.0/24      OSPF    10     4      D    192.168.34.4    GigabitEthernet0/0/2

OSPF routing table status : <Inactive>
Destinations : 0 Routes : 0

5.配置网络接口类型,影响DR的选举

[R3] interface GigabitEthernet 0/0/0
[R3-GigabitEthernet0/0/0] ospf  network-type  p2p

6.配置所在网段的接口,影响DR的选举

[R3] interface GigabitEthernet 0/0/0

[R3-GigabitEthernet0/0/0] ospf dr-priority 0

7.配置路由器所在接口的cost,影响路由的选择

[R3]interface GigabitEthernet 0/0/0
[R3-GigabitEthernet0/0/0]ospf cost 45

8.配置路由器间的Hello计时器时长

[R3]interface GigabitEthernet 0/0/0
[R3-GigabitEthernet0/0/0]ospf timer hello 4

9.配置路由器之间的Dead计时器时长

[R3]interface GigabitEthernet 0/0/0
[R3-GigabitEthernet0/0/0]ospf timer dead 33

最新文章

  1. js中typeOf用法
  2. c++中resize函数怎么用
  3. Windows Server 2008 R2中的ASP.NET环境架设
  4. Linux 查找指定名称的进程并显示进程详细信息
  5. IOS - Objective-C NSArray和NSMutableArray的详解 使用
  6. java读取utf8配置文件乱码
  7. mark元素
  8. HTML中的图像
  9. java关闭流,解压缩后的清除
  10. 神奇的脱机 app_offline.htm
  11. 排序命令sort
  12. Page.ClientScript.RegisterStartupScript
  13. UML 小结(6)- UML九种图的比较与学习
  14. intellij安装 配置 创建项目
  15. Web前端框架与类库
  16. adb shell dumpsys
  17. 【转】Java并发编程:如何创建线程?
  18. 模仿ReentrantLock类自定义锁
  19. noip第17课作业
  20. P3173 [HAOI2009]巧克力 &amp;&amp; P1324 矩形分割

热门文章

  1. Ubuntu安装Zabbix6.0
  2. JSTL 报错 TagLibraryValidator
  3. 23年用vuex进行状态管理out了,都开始用pinia啦!
  4. [GKCTF2021]random
  5. 洛谷P4726 【模板】多项式指数函数(多项式 exp)
  6. 使用python和adb来学习(学习通)
  7. nodejs基础知识点
  8. Nacos配置管理
  9. rtl8188eu 关闭power save
  10. ZooKeeper的主要应用场景