远程登录路由器
拓扑
实现用PC远程telnet R2
IP地址分配:
PC 地址:192.168.1.100/24
R1的F0/0:192.168.1.254/30,s0/0:12.1.1.1、24
R2的 s0/0:12.1.1.2/24
1.配置R1
en
conf t
no ip do lo
lin con 0
no exec-t
logg sy
ho R1
int f0/0
ip add 192.168.1.254 255.255.255.0
no sh
int s0/0
ip add 12.1.1.1 255.255.255.0
no sh
测试可以通。
2.配置R2
en
conf t
no ip do lo
lin con 0
no exec-t
logg sy
ho R2
int s0/0
ip add 12.1.1.2 255.255.255.0
no sh
exit
R2(config)#enable password
zdan
//设置进入特权模式的密码为zdan //
R2(config)#lin vty 0 4
R2(config-line)#password
cisco01
//设置vty线路密码为cisco01 //
3.配路由协议(本例中用RIP)
R1(config)#router rip
R1(config-router)#net 192.168.1.0
R1(config-router)#net 12.1.1.0
R1(config-router)end
R2(config)#router rip
R2(config-router)#net 12.1.1.0
R2(config-router)end
已经成功的远程登录到R2了。
转载于:https://blog.51cto.com/baohua/886216