一.实验拓扑图
二.实验目的
1. 起用ospf协议,进程号100
2. 启用认证 md5
3. 启用r2做DR,r3做BDR
4. 设r1的cost值为50
三.实验命令
r1;
en
config t
int e0
ip add 1.1.1.1 255.255.255.0
no shut
int loop 1
ip add 4.4.4.4 255.255.255.0
exit
r2:
en
config t
int e0
ip add 1.1.1.2 255.255.255.0
no shut
int loop 1
ip add 2.2.2.2 255.255.255.0
exit
r3:
en
config t
int e0
ip add 1.1.1.3 255.255.255.0
int loop 1
ip add 3.3.3.3 255.255.255.0
exit
启用ospf协议:
r1:
config t
router ospf 100
net 1.1.1.1 0.0.0.0 area 0
net 4.4.4.0 0.0.0.255 area0
exit
r2:
config t
router ospf 100
net 1.1.1.2 0.0.0.0 area 0
net 2.2.2.0 0.0.0.255 area 0
exit
r3:
config t
router ospf 100
net 1.1.1.3 0.0.0.0 area 0
net 3.3.3.3 0.0.0.255 area 0
exit
启用md5认证
r1:config t
router ospf 100
area 0 authentication message-digest
int e0
ip ospf message-digest-key 1 md5 cisco
r2:config t
router ospf 100
area 0 authentication message-digest
int e0
ip ospf message-digest-key 1 md5 cisco
r2:config t
router ospf 100
area 0 authentication message-digest
int e0
ip ospf message-digest-key 1 md5 cisco
设置r2为DR,设置r3为BDR
r2 ;
config t
int e0
ip ospf priority 100
exit
r3:
config t
int e0
ip ospf priority 50
设置r1的cost值为50
r1:
config t
int e0
ip ospf cost 50
exit