远程管理功能
首先,看一下实验拓扑
1.开启路由器远程管理功能,可以从两边的交换机上远程管理路由器,配置网关地址(远程访问密码123)
<AR1>sys
[AR1]interface GigabitEthernet 0/0/1
[AR1-GigabitEthernet0/0/1]ip address 192.168.10.254 24
[AR1-GigabitEthernet0/0/1]int g0/0/2
[AR1-GigabitEthernet0/0/2]ip address 172.16.0.254 24
[AR1-GigabitEthernet0/0/2]user vty 0 4
[AR1-ui-vty0-4]set authentication password cipher 123
[AR1-ui-vty0-4]user privilege level 3
[AR1-ui-vty0-4]return
<AR1>save
The current configuration will be written to the device.
Are you sure to continue? (y/n)[n]:y
2.给交换机配置远程管理功能
(1)LSW1(远程密码111)
<LSW1>sys
[LSW1]interface Vlanif 1
[LSW1-Vlanif1]ip address 192.168.10.251 24
[LSW1-Vlanif1]user vty 0 4
[LSW1-ui-vty0-4]set authentication password cipher 111
[LSW1-ui-vty0-4]user privilege level 3
[LSW1-ui-vty0-4]return
<LSW1>save
The current configuration will be written to the device.
Are you sure to continue?[Y/N]y
(2)LSW2(远程密码222)
<LSW2>sys
[LSW2]interface Vlanif 1
[LSW2-Vlanif1]ip address 172.16.0.251 24
[LSW2-Vlanif1]user vty 0 4
[LSW2-ui-vty0-4]set authentication password cipher 222
[LSW2-ui-vty0-4]user privilege level 3
[LSW2-ui-vty0-4]return
<LSW2>save
The current configuration will be written to the device.
Are you sure to continue?[Y/N]y
3.分别给设备设置IP地址和子网掩码,网关
确保10.10、10.11、0.10、0.11互相之间可以ping通
4.到了这里已经可以实现交换机上远程管理路由器和路由器上管理交换机
<AR1>telnet 192.168.10.251
5.在lsw1远程管理lsw2
分别给LSW1和LSW2配置静态路由
<LSW1>sys
Enter system view, return user view with Ctrl+Z.
[LSW1]ip route-static 172.16.0.0 24 192.168.10.254
<LSW2>sys
Enter system view, return user view with Ctrl+Z.
[LSW2]ip route-static 192.168.10.0 24 172.16.0.254
IP route-static 0.0.0.0 0 网关IP //默认路由
ping一下另一台交换机通了就可以在交换机上远程管理交换机
<LSW1>ping 172.16.0.251
<LSW2>telnet 172.16.0.251