Learn how to configure ssh on a switch.ssh is used to remote login to a device pc server switch or router securely.The difference between ssh and telnet is that in telnet username and password is sent on line in simple text form while in ssh it is encrypted and hence make ssh more secure.
Learn how to configure ssh on a cisco switch in few simple steps:
Switch>enable Switch#config t Enter configuration commands, one per line. End with CNTL/Z. Switch(config)#hostname S1 S1(config)#interface vlan 1 S1(config-if)#ip address 192.168.1.1 255.255.255.0 S1(config-if)#no shut S1(config-if)#exit S1(config)#line vty 0 5 S1(config-line)#password redhat123 S1(config-line)#login S1(config-line)#
Now for ssh configuration below steps are must:
S1>enable S1#config t Enter configuration commands, one per line. End with CNTL/Z. S1(config)#ip domain name shivangi S1(config)#crypto key generate rsa The name for the keys will be: S1.shivangi 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] S1(config)#ip ssh version 2 *Mar 1 0:21:8.384: %SSH-5-ENABLED: SSH 1.99 has been enabled S1(config)#line vty 0 5 S1(config-line)#transport input ssh
Now check your ssh connection from any of your pc.
PC>ssh -l admin 192.168.1.1 Open Password:
Now if you want to change username from admin to something else you can do that from entering switch global configuration mode:
S1(config)#username satish secret redhat S1(config)#line vty 0 5 S1(config-line)#login local S1(config-line)#
Now test it from any of your pc by logging through your newly created user:
PC>ssh -l satish 192.168.1.1 Open Password: S1>show arp Protocol Address Age (min) Hardware Addr Type Interface Internet 192.168.1.1 - 0001.43A9.275D ARPA Vlan1 Internet 192.168.1.3 30 00E0.F940.4904 ARPA Vlan1
This post will assist the internet visitors for creating
new webpage or even a blog from start to end.
LikeLike