拓扑图
IP基于192.168.1.0 24划分,区域0的汇总网段为192.168.1.0 25
实验通过OSPF动态路由达成全网通,并划分了0和1两个区域,其中区域0以R3为ABR和DR。
通过改写R1和R2的优先级使得区域内无BDR。
通过以R4为边界路由器配置缺省路由达到PING通4.4.4.0 24网段。
在区域1内各个接口使用密钥加密。
配置指令如下
[r1]ospf 1 router-id 1.1.1.1 进入OSPF协议,1.1.1.1这个位置可以自己编辑,默认为IP地址
[r1-ospf-1-area-0.0.0.0]network 宣告
[r2]display ospf peer 查看邻居表-详细
[r2]display ospf peer brief 查看邻居关系简表
[r2]display ospf lsdb
<r1>display ip routing-table protocol ospf 查看路由表中OSPF形成的路由
[r1-ospf-1]bandwidth-reference 修改参考带宽
[r1-GigabitEthernet0/0/1]ospf authentication-mode md5 1 cipher ****** 添加认证
[r2-ospf-1-area-0.0.0.0]abr-summary 汇总
[r1-ospf-1]silent-interface GigabitEthernet 沉默接口
[r3-ospf-1]default-route-advertise always 在边界路由器上配置缺省路由
实验结果如下