学习内容:
**1.Telnet登录路由器
学习时间:
- 周六上午 9 点-上午 11 点
- 周日下午 3 点-下午 6 点
学习产出:
拓扑图:
R1:
Router>
Router>en
Router#conf t
Enter configuration commands, one per line. End with CNTL/Z.
Router(config)#hostname R1
R1(config)#int g0/0
R1(config-if)#ip add 192.168.1.254 255.255.255.0
R1(config-if)#no shut
R1(config-if)#
%LINK-5-CHANGED: Interface GigabitEthernet0/0, changed state to up
%LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/0, changed state to up
R1(config)#enable secret 123456 (设置特权密码)
R1(config)#username admin password cisco (定义Telnet的用户名admin,密码cisco)
R1(config)#line vty 0 4 (0-4 设定虚拟终端连接数5)
R1(config-line)#login local (配置要求本地登录)
R1(config-line)#exi
R1(config)#ip domain-name cisco.com (配置路由器所在域名cisco.com)
R1(config)#line vty 5 15 (0-15 设定虚拟终端连接数11)
R1(config-line)#transport input ssh (配置允许远程连接SSH服务器)
R1(config-line)#login local (配置要求本地登录)
R1(config-line)#exi
R1(config)#config-register key gen
R1>en
Password: (密码123456)
R1#conf t
Enter configuration commands, one per line. End with CNTL/Z.
R1(config)#crypto key generate rsa
The name for the keys will be: R1.cisco.com
Choose the size of the key modulus in the range of 360 to 2048 for your
General Purpose Keys. Choosing a key modulus greater than 512 may take
a few minutes.
How many bits in the modulus [512]: 1024
% Generating 1024 bit RSA keys, keys will be non-exportable…[OK]
R1(config)#ip ssh version 2 (SSH版本2)
R1(config)#exi
write (保存)
Building configuration…
[OK]
R1#
SWA:
Switch>en
Switch#conf t
swa(config)#hostname SWA (改名)
PC1:
PC2:
任务验收:
PC1:
Username:admin
Password: cisco
R1>enable
Password: 123456
R1#
PC2:
Password: cisco
R1>enable
Password: 123456
R1#