sky 发表于 2015-12-30 18:04:10

jumpserver-管理网络设备-Huawei

一、设备配置SSH登录

1.生成本地密钥对

rsa local-key-pair create

The key name will be: Huawei_Host

The range of public key size is (512 ~ 2048).

NOTES: If the key modulus is greater than 512,

it will take a few minutes.

Input the bits in the modulus:1024

Generating keys...

............................++++++

...++++++

..++++++++

......++++++++

2.配置VTY用户界面

user-interface vty 0 4

authentication-mode aaa

protocol inbound ssh

quit

    3.配置SSH用户的用户名和密码

aaa

local-user admin password cipher admin123

Info: Add a new user.

local-user admin privilege level 3

local-user admin service-type ssh

quit

4.创建SSH用户,并配置用户的认证方式为password

ssh user admin authentication-type password

5.使能STelent功能,并配置用户的服务类型为STelnet

stelnet server enable

Info: Succeeded in starting the Stelnet server.

6. ssh登录测试




二、添加资产,登录方式选择MAP,这里的用户名和密码是刚才设备上创建的。


三、登录设备



注:登录如果报paramiko.ssh_exception.SSHException: No existing session
解决:
/opt/jumpserver 目录下 vim connect.py在296行添加 allow_agent=False,look_for_keys=False

ssh.connect(host, port=port, username=username, password=password, compress=True, allow_agent=False,look_for_keys=False )

实时监控


页: [1]
查看完整版本: jumpserver-管理网络设备-Huawei