f5-ansible-bigip
f5-ansible-bigip copied to clipboard
v16.1.x ucs_fetch urllib.error.URLError: <urlopen error timed out>
I've tried a number of playbooks ucs_fetch, bigip_qkview both imperative and declarative and I get errors. If I revert to 15.1.8 they work fine.
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: urllib.error.URLError:
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/home/centos/.ansible/tmp/ansible-tmp-1669045074.1295142-18969-255249079795967/AnsiballZ_bigip_qkview.py", line 107, in <module>
_ansiballz_main()
File "/home/centos/.ansible/tmp/ansible-tmp-1669045074.1295142-18969-255249079795967/AnsiballZ_bigip_qkview.py", line 99, in _ansiballz_main
invoke_module(zipped_mod, temp_path, ANSIBALLZ_PARAMS)
File "/home/centos/.ansible/tmp/ansible-tmp-1669045074.1295142-18969-255249079795967/AnsiballZ_bigip_qkview.py", line 47, in invoke_module
runpy.run_module(mod_name='ansible_collections.f5networks.f5_modules.plugins.modules.bigip_qkview', init_globals=dict(_module_fqn='ansible_collections.f5networks.f5_modules.plugins.modules.bigip_qkview', _modlib_path=modlib_path),
File "/usr/local/lib/python3.8/runpy.py", line 207, in run_module
return _run_module_code(code, init_globals, run_name, mod_spec)
File "/usr/local/lib/python3.8/runpy.py", line 97, in _run_module_code
_run_code(code, mod_globals, init_globals,
File "/usr/local/lib/python3.8/runpy.py", line 87, in _run_code
exec(code, run_globals)
File "/tmp/ansible_bigip_qkview_payload_swf1ab3w/ansible_bigip_qkview_payload.zip/ansible_collections/f5networks/f5_modules/plugins/modules/bigip_qkview.py", line 607, in <module>
File "/tmp/ansible_bigip_qkview_payload_swf1ab3w/ansible_bigip_qkview_payload.zip/ansible_collections/f5networks/f5_modules/plugins/modules/bigip_qkview.py", line 600, in main
File "/tmp/ansible_bigip_qkview_payload_swf1ab3w/ansible_bigip_qkview_payload.zip/ansible_collections/f5networks/f5_modules/plugins/modules/bigip_qkview.py", line 224, in exec_module
File "/tmp/ansible_bigip_qkview_payload_swf1ab3w/ansible_bigip_qkview_payload.zip/ansible_collections/f5networks/f5_modules/plugins/modules/bigip_qkview.py", line 237, in is_version_less_than_14
File "/tmp/ansible_bigip_qkview_payload_swf1ab3w/ansible_bigip_qkview_payload.zip/ansible_collections/f5networks/f5_modules/plugins/module_utils/icontrol.py", line 551, in tmos_version
File "/tmp/ansible_bigip_qkview_payload_swf1ab3w/ansible_bigip_qkview_payload.zip/ansible_collections/f5networks/f5_modules/plugins/module_utils/bigip.py", line 31, in api
File "/tmp/ansible_bigip_qkview_payload_swf1ab3w/ansible_bigip_qkview_payload.zip/ansible_collections/f5networks/f5_modules/plugins/module_utils/bigip.py", line 52, in connect_via_token_auth
File "/tmp/ansible_bigip_qkview_payload_swf1ab3w/ansible_bigip_qkview_payload.zip/ansible_collections/f5networks/f5_modules/plugins/module_utils/icontrol.py", line 239, in post
File "/tmp/ansible_bigip_qkview_payload_swf1ab3w/ansible_bigip_qkview_payload.zip/ansible_collections/f5networks/f5_modules/plugins/module_utils/icontrol.py", line 194, in send
File "/tmp/ansible_bigip_qkview_payload_swf1ab3w/ansible_bigip_qkview_payload.zip/ansible/module_utils/urls.py", line 1446, in open
File "/usr/local/lib/python3.8/urllib/request.py", line 222, in urlopen
return opener.open(url, data, timeout)
File "/usr/local/lib/python3.8/urllib/request.py", line 525, in open
response = self._open(req, data)
File "/usr/local/lib/python3.8/urllib/request.py", line 542, in _open
result = self._call_chain(self.handle_open, protocol, protocol +
File "/usr/local/lib/python3.8/urllib/request.py", line 502, in _call_chain
result = func(*args)
File "/tmp/ansible_bigip_qkview_payload_swf1ab3w/ansible_bigip_qkview_payload.zip/ansible/module_utils/urls.py", line 582, in https_open
File "/usr/local/lib/python3.8/urllib/request.py", line 1357, in do_open
raise URLError(err)
urllib.error.URLError: <urlopen error timed out>
module_stdout: '' msg: |- MODULE FAILURE See stdout/stderr for the exact error rc: 1
-
name: Only create new UCS, no download hosts: f5 gather_facts: false connection: local
vars: provider: password: "{{ ansible_ssh_pass }}" server: "{{ private_ip }}" user: "{{ ansible_user }}" validate_certs: "no" timeout: 1600 tasks:
- name: Fetch a qkview from the remote device bigip_qkview: only_create_file: yes exclude: - audit - secure dest: /tmp/localhost.localdomain.qkview provider: "{{ provider }}" delegate_to: localhost
[centos@ansible networking-workshop]$ cat ucs_fetch_simple.yml
-
name: Only create new UCS, no download hosts: f5 gather_facts: false connection: local
vars: provider: password: "{{ ansible_ssh_pass }}" server: "{{ private_ip }}" user: "{{ ansible_user }}" validate_certs: "no" timeout: 1600 tasks:
- name: Fetch a qkview from the remote device bigip_qkview: only_create_file: yes exclude: - audit - secure dest: /tmp/localhost.localdomain.qkview provider: "{{ provider }}" delegate_to: localhost [centos@ansible networking-workshop]$ cat ucs_fetch.yml
-
name: Fetch BIG-IP UCS hosts: f5 connection: local gather_facts: False vars: provider: password: "{{ ansible_ssh_pass }}" server: "{{ private_ip }}" user: "{{ ansible_user }}" validate_certs: False
tasks:
-
name: get current time on localhost command: date "+%H%M%S-%m%d%y" register: date delegate_to: localhost run_once: True
-
name: set filename var set_fact: ucs: "{{ 'test' + '-' + date.stdout + '-backup.ucs' }}"
-
name: Download a new UCS bigip_ucs_fetch: src: "{{ ucs }}" dest: "{{ '/tmp/ucs/' + ucs }}" provider: "{{ provider }}" delegate_to: localhost
-
Hi, internal ID to track this item is: INFRAANO-976, thanks!
any update on this bug?
Can you tell us what version of TMOS are you using when this issue is being presented?
Hi,
To troubleshoot the connection issue, could you do a tcpdump with decryption so that we can determine whether it's the BIG-IP or the Ansible client that's reseting the connection. If you need help, you can open a ticket at https://my.f5.com/.