Common Switch Commands

Time setting (Huawei switch)
clock datetime HH:MM:SS YYYY-MM-DD
clock timezone BJ add 8:00:00
dis clock
ssh login (Huawei switch)

rsa local-key-pair create //Generate key
aaa
 local-user wzl password cipher admin //Create user and password is cipher text
 local-user wzl privilege level 15 //User level is 3
 local-user wzl service-type ssh //Service type is ssh
stelnet server enable //Enable SSH service
ssh user wzl authentication-type password //User authentication type is password authentication
ssh user wzl service-type stelnet //Service type is ssh

user-interface vty 0 4 //Enter line 0 to 4
 authentication-mode aaa //The authentication mode is aaa
 protocol inbound ssh //Use ssh protocol
 protocol inbound all
 user privilege level 15

Optional:
ssh server port 1025 //Modify the ssh port to 1025
display rsa local-key-pair public

 H3C switch configuration ssh login
1. Open the ssh service, create a key.
system-view
ssh server enable //Enable ssh service
public-key local create rsa //Create rsa key
public-key local create dsa //Create dsa key
2. Configure vty virtual interface.
user-interface vty 4 //Enter the vty configuration
authentication-mode scheme //Set the authentication mode
protocol inbound ssh //Set the login protocol to ssh,
protocol inbound all// The default is all
quit //Exit vty mode
3. Create a configuration user.
local-user wzl //Create user iautos
password simple P@ssw0rdxxx //Set password P@ssw0rdxxx
service-type ssh //Set user login authority to ssh
authorization-attribute user-role level-15//Set user level to 15
quit //Exit user configuration mode
save //Save configuration


The command to add multiple ports at a time in the cisco switch VLAN
 Switch(config)#interface range fastethernet 0/1-48
Switch(config-range)#switchport access vlan 10

Ruijie Switch

Set time

Ruijie>enable
Ruijie#clock set 10:00:00 12 1 2012 ------>clock set hour:minute:second month day year
Ruijie#configure terminal ------>Enter global configuration mode
Ruijie(config )#clock timezone beijing 8 ------>Set the time zone of the switch
Ruijie(config)#end
Ruijie#write ------>Confirm the configuration is correct, save the configuration

 

 

Guess you like

Origin blog.csdn.net/wzlsunice88/article/details/103972456