-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I can not seem to access any of my switches using this collection #55
Comments
Hi, What switch firmware and model ? Do you have check the log of the switch and also this part of doc ? https://github.com/aruba/aos-switch-ansible-collection#setting-environment-variables |
show versionImage stamp: /ws/swbuildm/rel_beluru_qaoff/code/build/lvm(swbuildm_rel_beluru_qaoff_rel_beluru) Boot ROM Version: WC.16.01.0010 It's a 2930F |
And I am setting the environment variable: ANSIBLE_NETWORK_GROUP_MODULES=arubaoss ansible-playbook $ grep NETWORK /etc/ansible/ansible.cfg |
I can log into the switch manually using ssh. |
I find I can use the arubaoss_vlan module as documented using both: I can't use the arubaoss_config or arubaoss_command modules as per the documentation. When I use the arubaoss_command module, with any set of commands e.g. show version When I use the arubaoss_config module as follows to save the running configuration:
I receive the error:
The test switch is as follows:
Any ideas what I can do to get the running configuration file for a AOS switch? |
ansible run on linux ? windows ? on the ansible runner, you can make ssh connection to the switch ? do you have check switch log ? |
There is definitely an ssh connection to the switch as I can perform the vlan and ntp commands fine.
|
I've now tried to use the config and command modules with ansible on an Ubuntu 20.04 machine. The same problem exists. The modules fail in a slightly different manner, but they still fail. The other modules e.g. the NTP ones work find in network_cli mode. |
@quistian you should be using |
That's what I am doing i.e. using network_cli and using arubaoss_command as follows: hosts: aos_sws tasks: The error message is as follows: |
Update to 16.11 or 16.10 |
Do you have The reason I ask Is I've been having issues with running command / config ansible playbooks and got the same error above: From my testing (using a radius auth user) I was able to get it working by disabling the password config-control. This is on both 16.10 & 16.11 |
When I try to do a simple "show run" "show version" I get the error:
No existing session.
I have the connection set to network_cli
hosts: aos_test
gather_facts: True
collections:
vars:
ansible_network_os: arubanetworks.aos_switch.arubaoss
ansible_connection: network_cli
ansible_user: ***
ansible_password: ***
tasks:
name: Execute show version on the switch
arubaoss_command:
commands:
- show run
- show version
output_file: "./config/{{ inventory_hostname }}-aos-running-config.txt"
tags:
ok: [aos_test_sw] => { "changed": false, "invocation": { "module_args": { "api_version": "None", "commands": [ "show run", "show version" ], "host": null, "interval": 1, "match": "all", "output_file": "./config/aos_test_sw-aos-running-config.txt", "password": null, "port": null, "provider": { "api_version": null, "host": "10.5.9.18", "password": "VALUE_SPECIFIED_IN_NO_LOG_PARAMETER", "port": 80, "ssh_keyfile": null, "timeout": 30, "transport": "aossapi", "use_proxy": false, "use_ssl": false, "username": "swbackup", "validate_certs": false }, "retries": 10, "ssh_keyfile": null, "timeout": null, "use_ssl": null, "username": null, "validate_certs": false, "wait_for": null } }, "stdout": [ "No existing session", "No existing session" ], "stdout_lines": [ [ "No existing session" ], [ "No existing session" ] ] }
The text was updated successfully, but these errors were encountered: