交换机常见命令

时间设置(华为交换机)
clock datetime HH:MM:SS YYYY-MM-DD
clock timezone BJ add 8:00:00
dis clock
ssh登陆(华为交换机)

rsa local-key-pair create  //生成密钥
aaa
 local-user wzl password cipher admin  //创建用户并且密码是密文
 local-user wzl privilege level 15  //用户等级为3
 local-user wzl service-type ssh  //服务类型为ssh
stelnet server enable  //使能SSH服务
ssh user wzl authentication-type password  //用户的验证类型为密码验证
ssh user wzl service-type stelnet  //服务类型为ssh

user-interface vty 0 4  //进入0到4线路
 authentication-mode aaa  //验证模式为aaa
 protocol inbound ssh  //使用ssh协议
 protocol inbound all
 user privilege level 15

可选:
ssh server port 1025  //修改ssh的端口为1025
display rsa local-key-pair public

 H3C 交换机配置ssh登陆
1.开启ssh服务,创建密钥。
system-view
ssh server enable //开启ssh服务
public-key local create rsa //创建rsa密钥
public-key local create dsa //创建dsa密钥
2.配置vty虚拟接口。
user-interface vty 4 //进入vty配置
authentication-mode scheme //设置认证模式
protocol inbound ssh //设置登陆协议为ssh,
protocol inbound all// 默认为all
quit //退出vty模式
3.创建配置用户。
local-user wzl //创建用户iautos
password simple P@ssw0rdxxx //设置密码P@ssw0rdxxx
service-type ssh //设置用户登陆权限为ssh
authorization-attribute user-role level-15//设置用户级别为15
quit //退出用户配置模式
save    //保存配置

cisco交换机
VLAN中一次添加多个端口的命令
 Switch(config)#interface range fastethernet 0/1 - 48
Switch(config-range)#switchport access vlan 10

锐捷交换机

设置时间

Ruijie>enable
Ruijie#clock set 10:00:00 12 1 2012     ------>clock set 小时:分:秒   月  日 年
Ruijie#configure terminal        ------>进入全局配置模式
Ruijie(config)#clock timezone beijing 8    ------>设置交换机的时区
Ruijie(config)#end
Ruijie#write           ------>确认配置正确,保存配置

猜你喜欢

转载自blog.csdn.net/wzlsunice88/article/details/103972456
今日推荐