Closed Nukete closed 7 years ago
which CloudEngine branch or releases did you used? ansible 2.3.x: https://github.com/HuaweiSwitch/CloudEngine-Ansible/tree/devel-2.3 ansible 2.2.x: https://github.com/HuaweiSwitch/CloudEngine-Ansible/tree/devel-2.2 ansbile 2.4.x: No additional installation is required, and the Cloudengine modules already contains.
Can SSH login switch?
ssh username@xxx.xxx.xxx -p sshport
ansible 2.2 and 2.3 install way is defferent, you can install it by this script on Ubunbu or manually run step by step on other platforms, according to this script:
ansible 2.3.x: https://github.com/HuaweiSwitch/CloudEngine-Ansible/blob/devel-2.3/install.sh
constants.py
is already configured
$ANSIBLE_PATH/constants.py
ce
must add on macro NETWORK_GROUP_MODULES
, just like:
https://github.com/HuaweiSwitch/CloudEngine-Ansible/blob/devel-2.3/constants.py
NETWORK_GROUP_MODULES = get_config(p, DEFAULTS, 'network_group_modules','NETWORK_GROUP_MODULES', ['eos', 'nxos', 'ios', 'iosxr', 'junos', 'ce',
'vyos', 'sros', 'dellos9', 'dellos10', 'dellos6'],
Hello,
thanks for your support
Finally I managed to solve problem: 1.- I deployed a new fresh Ansible install
adaroma@adaroma-PC:~/CloudEngine-Ansible$ ansible --version ansible 2.3.1.0 config file = /etc/ansible/ansible.cfg configured module search path = Default w/o overrides python version = 2.7.12 (default, Nov 19 2016, 06:48:10) [GCC 5.4.0 20160609]
2.- Used script to install CloudEngine modules (thanks for clarification in previous post :+1:): https://github.com/HuaweiSwitch/CloudEngine-Ansible/blob/devel-2.3/install.sh
3.- Just for reference: I've found another problem related to paramiko func:
2017-06-16 12:43:17,658 paramiko.transport Unknown exception: Use module Crypto.Signature.pkcs1_15 instead
192.168.3.120 | FAILED! => { "changed": false, "failed": true, "msg": "unable to open shell. Please see: https://docs.ansible.com/ansible/network_debug_troubleshooting.html#unable-to-open-shell", "rc": 255
My previous paramiko version: paramiko-1.16.0
I've upgraded it to paramiko-2.2.1
and all is ok:
192.168.3.120 | SUCCESS => { "changed": false, "stdout": [ "Static vlan:\nTotal 3 static vlan.\n 1 54 705 \n\nDynamic vlan:\nTotal 0 dynamic vlan.\n\nReserved vlan:\nTotal 0 reserved vlan." ], "stdout_lines": [ [ "Static vlan:", "Total 3 static vlan.", " 1 54 705 ", "", "Dynamic vlan:", "Total 0 dynamic vlan.", "", "Reserved vlan:", "Total 0 reserved vlan." ] ]
OK, have a nice day!
Hi,
following this guide install is ok: CloudEngine-Huawei when trying to execute command as follows: (Using default command in example)
ssh to switch granted and tested through radius user
root@localhost:~# ansible -m ce_command -a "commands='display vlan summary' transport='cli' host=10.100.1.29 port=22 username=blabla password=blabla" localhost --connection local
FYI: