You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When trying to write the configuration on a SLX9640, it fails with the following message:
% ansible-playbook -i inventory/inventory -u XXX -k playbooks/slx_wr.yml -l XXX
SSH password:
PLAY [slx] ***************************************************************************************************************************************************
TASK [save the running config unconditionally] ***************************************************************************************************************
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: See the timeout setting options in the Network Debug and Troubleshooting Guide.
fatal: [XXX]: FAILED! => {"changed": false, "module_stderr": "Traceback (most recent call last):\n File \"/Users/xxx/.ansible/tmp/ansible-local-36617u_7ihkbh/ansible-tmp-1642762121.865495-36620-19882093940858/AnsiballZ_slxos_config.py\", line 100, in <module>\n _ansiballz_main()\n File \"/Users/xxx/.ansible/tmp/ansible-local-36617u_7ihkbh/ansible-tmp-1642762121.865495-36620-19882093940858/AnsiballZ_slxos_config.py\", line 92, in _ansiballz_main\n invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)\n File \"/Users/xxx/.ansible/tmp/ansible-local-36617u_7ihkbh/ansible-tmp-1642762121.865495-36620-19882093940858/AnsiballZ_slxos_config.py\", line 40, in invoke_module\n runpy.run_module(mod_name='ansible_collections.community.network.plugins.modules.slxos_config', init_globals=dict(_module_fqn='ansible_collections.community.network.plugins.modules.slxos_config', _modlib_path=modlib_path),\n File \"/opt/homebrew/Cellar/[email protected]/3.10.0_2/Frameworks/Python.framework/Versions/3.10/lib/python3.10/runpy.py\", line 209, in run_module\n return _run_module_code(code, init_globals, run_name, mod_spec)\n File \"/opt/homebrew/Cellar/[email protected]/3.10.0_2/Frameworks/Python.framework/Versions/3.10/lib/python3.10/runpy.py\", line 96, in _run_module_code\n _run_code(code, mod_globals, init_globals,\n File \"/opt/homebrew/Cellar/[email protected]/3.10.0_2/Frameworks/Python.framework/Versions/3.10/lib/python3.10/runpy.py\", line 86, in _run_code\n exec(code, run_globals)\n File \"/var/folders/3b/6d40b40932g971mcc2g563qc0000gn/T/ansible_community.network.slxos_config_payload_m182nvfl/ansible_community.network.slxos_config_payload.zip/ansible_collections/community/network/plugins/modules/slxos_config.py\", line 461, in <module>\n File \"/var/folders/3b/6d40b40932g971mcc2g563qc0000gn/T/ansible_community.network.slxos_config_payload_m182nvfl/ansible_community.network.slxos_config_payload.zip/ansible_collections/community/network/plugins/modules/slxos_config.py\", line 402, in main\n File \"/var/folders/3b/6d40b40932g971mcc2g563qc0000gn/T/ansible_community.network.slxos_config_payload_m182nvfl/ansible_community.network.slxos_config_payload.zip/ansible_collections/community/network/plugins/modules/slxos_config.py\", line 295, in save_config\n File \"/var/folders/3b/6d40b40932g971mcc2g563qc0000gn/T/ansible_community.network.slxos_config_payload_m182nvfl/ansible_community.network.slxos_config_payload.zip/ansible_collections/community/network/plugins/module_utils/network/slxos/slxos.py\", line 102, in run_commands\n File \"/var/folders/3b/6d40b40932g971mcc2g563qc0000gn/T/ansible_community.network.slxos_config_payload_m182nvfl/ansible_community.network.slxos_config_payload.zip/ansible/module_utils/connection.py\", line 200, in __rpc__\nansible.module_utils.connection.ConnectionError: command timeout triggered, timeout value is 30 secs.\nSee the timeout setting options in the Network Debug and Troubleshooting Guide.\n", "module_stdout": "", "msg": "MODULE FAILURE\nSee stdout/stderr for the exact error", "rc": 1}
PLAY RECAP ***************************************************************************************************************************************************
XXX. : ok=0 changed=0 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0
---
- hosts: slxgather_facts: notasks:
- name: save the running config unconditionallycommunity.network.slxos_config:
save_when: always
EXPECTED RESULTS
Saving the configuration.
ACTUAL RESULTS
The configuration was not saved. It took 30s until the task stops with an error.
The reason is that slxos_config.py expects a different text from the CLI.
slxos_config.py:293 "prompt": "This operation will modify your startup configuration. Do you want to continue", "answer": "y"}
On SLX-OS 20.3.4 the text reads: "This operation will back up the current configuration. Do you want to continue? [y/n]:"
The same text is seen on SLX-OS 20.1.x, 20.2.x and 20.3.x as far as I know.
ansible-playbook -i inventory/inventory -u xxx -k playbooks/slx_wr.yml -vvvv
ansible-playbook [core 2.11.6]
config file = /Users/xxx/ansible/ansible.cfg
configured module search path = ['/Users/xxx/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
ansible python module location = /opt/homebrew/Cellar/ansible/4.8.0/libexec/lib/python3.10/site-packages/ansible
ansible collection location = /Users/xxx/.ansible/collections:/usr/share/ansible/collections
executable location = /opt/homebrew/bin/ansible-playbook
python version = 3.10.0 (default, Oct 12 2021, 22:37:59) [Clang 13.0.0 (clang-1300.0.29.3)]
jinja version = 3.0.2
libyaml = True
Using /Users/xxx/ansible/ansible.cfg as config file
SSH password:
setting up inventory plugins
host_list declined parsing /Users/xxx/ansible/inventory/inventory_core as it did not pass its verify_file() method
script declined parsing /Users/xxx/ansible/inventory/inventory_core as it did not pass its verify_file() method
auto declined parsing /Users/xxx/ansible/inventory/inventory_core as it did not pass its verify_file() method
Parsed /Users/xxx/ansible/inventory/inventory_core inventory source with ini plugin
Loading collection community.network from /opt/homebrew/Cellar/ansible/4.8.0/libexec/lib/python3.10/site-packages/ansible_collections/community/network
Loading callback plugin default of type stdout, v2.0 from /opt/homebrew/Cellar/ansible/4.8.0/libexec/lib/python3.10/site-packages/ansible/plugins/callback/default.py
Skipping callback 'default', as we already have a stdout callback.
Skipping callback 'minimal', as we already have a stdout callback.
Skipping callback 'oneline', as we already have a stdout callback.
PLAYBOOK: slx_wr.yml *****************************************************************************************************************************************
Positional arguments: playbooks/slx_wr.yml
verbosity: 4
ask_pass: True
remote_user: xxx
connection: smart
timeout: 10
become_method: sudo
tags: ('all',)
inventory: ('/Users/xxx/ansible/inventory/inventory_core',)
subset: XXX
forks: 20
1 plays in playbooks/slx_wr.yml
PLAY [slx] ***************************************************************************************************************************************************
META: ran handlers
TASK [save the running config unconditionally] ***************************************************************************************************************
task path: /Users/xxx/ansible/playbooks/slx_wr.yml:6
redirecting (type: connection) ansible.builtin.network_cli to ansible.netcommon.network_cli
Loading collection ansible.netcommon from /Users/xxx/.ansible/collections/ansible_collections/ansible/netcommon
redirecting (type: terminal) ansible.builtin.slxos to community.network.slxos
redirecting (type: cliconf) ansible.builtin.slxos to community.network.slxos
<xxx> attempting to start connection
<xxx> using connection plugin ansible.netcommon.network_cli
Found ansible-connection at path /opt/homebrew/bin/ansible-connection
<xxx> local domain socket does not exist, starting it
<xxx> control socket path is /Users/xxx/.ansible/pc/fda2f68759
<xxx> redirecting (type: connection) ansible.builtin.network_cli to ansible.netcommon.network_cli
<xxx> Loading collection ansible.netcommon from /Users/xxx/.ansible/collections/ansible_collections/ansible/netcommon
<xxx> redirecting (type: terminal) ansible.builtin.slxos to community.network.slxos
<xxx> Loading collection community.network from /opt/homebrew/Cellar/ansible/4.8.0/libexec/lib/python3.10/site-packages/ansible_collections/community/network
<xxx> redirecting (type: cliconf) ansible.builtin.slxos to community.network.slxos
<xxx> local domain socket listeners started successfully
<xxx> loaded cliconf plugin ansible_collections.community.network.plugins.cliconf.slxos from path /opt/homebrew/Cellar/ansible/4.8.0/libexec/lib/python3.10/site-packages/ansible_collections/community/network/plugins/cliconf/slxos.py for network_os slxos
<xxx> ssh type is set to paramiko
<xxx>
<xxx> local domain socket path is /Users/xxx/.ansible/pc/fda2f68759
<xxx> Using network group action community.network.slxos for community.network.slxos_config
<xxx> ANSIBLE_NETWORK_IMPORT_MODULES: disabled
<xxx> ANSIBLE_NETWORK_IMPORT_MODULES: module execution time may be extended
<xxx> ESTABLISH LOCAL CONNECTION FOR USER: xxx
<xxx> EXEC /bin/sh -c '( umask 77 && mkdir -p "` echo /Users/xxxx/.ansible/tmp/ansible-local-36744s7c2jag2 `"&& mkdir "` echo /Users/xxx/.ansible/tmp/ansible-local-36744s7c2jag2/ansible-tmp-1642764873.889224-36747-56274197009268 `" && echo ansible-tmp-1642764873.889224-36747-56274197009268="` echo /Users/xxx/.ansible/tmp/ansible-local-36744s7c2jag2/ansible-tmp-1642764873.889224-36747-56274197009268 `" ) && sleep 0'
Using module file /opt/homebrew/Cellar/ansible/4.8.0/libexec/lib/python3.10/site-packages/ansible_collections/community/network/plugins/modules/slxos_config.py
<xxx> PUT /Users/xxx/.ansible/tmp/ansible-local-36744s7c2jag2/tmpcpw5snj4 TO /Users/xxx/.ansible/tmp/ansible-local-36744s7c2jag2/ansible-tmp-1642764873.889224-36747-56274197009268/AnsiballZ_slxos_config.py
<xxx> EXEC /bin/sh -c 'chmod u+x /Users/xxx/.ansible/tmp/ansible-local-36744s7c2jag2/ansible-tmp-1642764873.889224-36747-56274197009268/ /Users/xxx/.ansible/tmp/ansible-local-36744s7c2jag2/ansible-tmp-1642764873.889224-36747-56274197009268/AnsiballZ_slxos_config.py && sleep 0'
<xxx> EXEC /bin/sh -c '/opt/homebrew/Cellar/ansible/4.8.0/libexec/bin/python3.10 /Users/xxx/.ansible/tmp/ansible-local-36744s7c2jag2/ansible-tmp-1642764873.889224-36747-56274197009268/AnsiballZ_slxos_config.py && sleep 0'
<xxx> EXEC /bin/sh -c 'rm -f -r /Users/xxx/.ansible/tmp/ansible-local-36744s7c2jag2/ansible-tmp-1642764873.889224-36747-56274197009268/ > /dev/null 2>&1 && sleep 0'
The full traceback is:
Traceback (most recent call last):
File "/Users/xxx/.ansible/tmp/ansible-local-36744s7c2jag2/ansible-tmp-1642764873.889224-36747-56274197009268/AnsiballZ_slxos_config.py", line 100, in <module>
_ansiballz_main()
File "/Users/xxx/.ansible/tmp/ansible-local-36744s7c2jag2/ansible-tmp-1642764873.889224-36747-56274197009268/AnsiballZ_slxos_config.py", line 92, in _ansiballz_main
invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)
File "/Users/xxx/.ansible/tmp/ansible-local-36744s7c2jag2/ansible-tmp-1642764873.889224-36747-56274197009268/AnsiballZ_slxos_config.py", line 40, in invoke_module
runpy.run_module(mod_name='ansible_collections.community.network.plugins.modules.slxos_config', init_globals=dict(_module_fqn='ansible_collections.community.network.plugins.modules.slxos_config', _modlib_path=modlib_path),
File "/opt/homebrew/Cellar/[email protected]/3.10.0_2/Frameworks/Python.framework/Versions/3.10/lib/python3.10/runpy.py", line 209, in run_module
return _run_module_code(code, init_globals, run_name, mod_spec)
File "/opt/homebrew/Cellar/[email protected]/3.10.0_2/Frameworks/Python.framework/Versions/3.10/lib/python3.10/runpy.py", line 96, in _run_module_code
_run_code(code, mod_globals, init_globals,
File "/opt/homebrew/Cellar/[email protected]/3.10.0_2/Frameworks/Python.framework/Versions/3.10/lib/python3.10/runpy.py", line 86, in _run_code
exec(code, run_globals)
File "/var/folders/3b/6d40b40932g971mcc2g563qc0000gn/T/ansible_community.network.slxos_config_payload_4ql4p5jx/ansible_community.network.slxos_config_payload.zip/ansible_collections/community/network/plugins/modules/slxos_config.py", line 461, in <module>
File "/var/folders/3b/6d40b40932g971mcc2g563qc0000gn/T/ansible_community.network.slxos_config_payload_4ql4p5jx/ansible_community.network.slxos_config_payload.zip/ansible_collections/community/network/plugins/modules/slxos_config.py", line 402, in main
File "/var/folders/3b/6d40b40932g971mcc2g563qc0000gn/T/ansible_community.network.slxos_config_payload_4ql4p5jx/ansible_community.network.slxos_config_payload.zip/ansible_collections/community/network/plugins/modules/slxos_config.py", line 295, in save_config
File "/var/folders/3b/6d40b40932g971mcc2g563qc0000gn/T/ansible_community.network.slxos_config_payload_4ql4p5jx/ansible_community.network.slxos_config_payload.zip/ansible_collections/community/network/plugins/module_utils/network/slxos/slxos.py", line 102, in run_commands
File "/var/folders/3b/6d40b40932g971mcc2g563qc0000gn/T/ansible_community.network.slxos_config_payload_4ql4p5jx/ansible_community.network.slxos_config_payload.zip/ansible/module_utils/connection.py", line 200, in __rpc__
ansible.module_utils.connection.ConnectionError: command timeout triggered, timeout value is 30 secs.
See the timeout setting options in the Network Debug and Troubleshooting Guide.
fatal: [xxx]: FAILED! => {
"changed": false,
"module_stderr": "Traceback (most recent call last):\n File \"/Users/xxx/.ansible/tmp/ansible-local-36744s7c2jag2/ansible-tmp-1642764873.889224-36747-56274197009268/AnsiballZ_slxos_config.py\", line 100, in <module>\n _ansiballz_main()\n File \"/Users/xxx/.ansible/tmp/ansible-local-36744s7c2jag2/ansible-tmp-1642764873.889224-36747-56274197009268/AnsiballZ_slxos_config.py\", line 92, in _ansiballz_main\n invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)\n File \"/Users/xxx/.ansible/tmp/ansible-local-36744s7c2jag2/ansible-tmp-1642764873.889224-36747-56274197009268/AnsiballZ_slxos_config.py\", line 40, in invoke_module\n runpy.run_module(mod_name='ansible_collections.community.network.plugins.modules.slxos_config', init_globals=dict(_module_fqn='ansible_collections.community.network.plugins.modules.slxos_config', _modlib_path=modlib_path),\n File \"/opt/homebrew/Cellar/[email protected]/3.10.0_2/Frameworks/Python.framework/Versions/3.10/lib/python3.10/runpy.py\", line 209, in run_module\n return _run_module_code(code, init_globals, run_name, mod_spec)\n File \"/opt/homebrew/Cellar/[email protected]/3.10.0_2/Frameworks/Python.framework/Versions/3.10/lib/python3.10/runpy.py\", line 96, in _run_module_code\n _run_code(code, mod_globals, init_globals,\n File \"/opt/homebrew/Cellar/[email protected]/3.10.0_2/Frameworks/Python.framework/Versions/3.10/lib/python3.10/runpy.py\", line 86, in _run_code\n exec(code, run_globals)\n File \"/var/folders/3b/6d40b40932g971mcc2g563qc0000gn/T/ansible_community.network.slxos_config_payload_4ql4p5jx/ansible_community.network.slxos_config_payload.zip/ansible_collections/community/network/plugins/modules/slxos_config.py\", line 461, in <module>\n File \"/var/folders/3b/6d40b40932g971mcc2g563qc0000gn/T/ansible_community.network.slxos_config_payload_4ql4p5jx/ansible_community.network.slxos_config_payload.zip/ansible_collections/community/network/plugins/modules/slxos_config.py\", line 402, in main\n File \"/var/folders/3b/6d40b40932g971mcc2g563qc0000gn/T/ansible_community.network.slxos_config_payload_4ql4p5jx/ansible_community.network.slxos_config_payload.zip/ansible_collections/community/network/plugins/modules/slxos_config.py\", line 295, in save_config\n File \"/var/folders/3b/6d40b40932g971mcc2g563qc0000gn/T/ansible_community.network.slxos_config_payload_4ql4p5jx/ansible_community.network.slxos_config_payload.zip/ansible_collections/community/network/plugins/module_utils/network/slxos/slxos.py\", line 102, in run_commands\n File \"/var/folders/3b/6d40b40932g971mcc2g563qc0000gn/T/ansible_community.network.slxos_config_payload_4ql4p5jx/ansible_community.network.slxos_config_payload.zip/ansible/module_utils/connection.py\", line 200, in __rpc__\nansible.module_utils.connection.ConnectionError: command timeout triggered, timeout value is 30 secs.\nSee the timeout setting options in the Network Debug and Troubleshooting Guide.\n",
"module_stdout": "",
"msg": "MODULE FAILURE\nSee stdout/stderr for the exact error",
"rc": 1
}
PLAY RECAP ***************************************************************************************************************************************************
XXX : ok=0 changed=0 unreachable=0 failed=1 skipped=0 rescued=0 ignored=0
The text was updated successfully, but these errors were encountered:
SUMMARY
When trying to write the configuration on a SLX9640, it fails with the following message:
ISSUE TYPE
COMPONENT NAME
plugins/modules/network/slxos/slxos_config.py
ANSIBLE VERSION
COLLECTION VERSION
CONFIGURATION
OS / ENVIRONMENT
STEPS TO REPRODUCE
ansible-playbook -i inventory/inventory -u xxx -k playbooks/slx_wr.yml
EXPECTED RESULTS
Saving the configuration.
ACTUAL RESULTS
The configuration was not saved. It took 30s until the task stops with an error.
The reason is that slxos_config.py expects a different text from the CLI.
slxos_config.py:293 "prompt": "This operation will modify your startup configuration. Do you want to continue", "answer": "y"}
On SLX-OS 20.3.4 the text reads: "This operation will back up the current configuration. Do you want to continue? [y/n]:"
The same text is seen on SLX-OS 20.1.x, 20.2.x and 20.3.x as far as I know.
The text was updated successfully, but these errors were encountered: