Open opoplawski opened 5 years ago
Got the same issue after upgrading my Ansible/Mitogen setup
Ansible: 2.9.4 Mitogen: 0.2.9 Python: 2.7.17
bump. having same issue on ansible 2.9.11 and mitogen current master.
fatal: [XXX.XXX.XXX.XXX]: UNREACHABLE! => {
"changed": false,
"msg": "could not recover task_vars. This means some connection settings may erroneously be reset to their defaults. Please report a bug if you encounter this message.",
"unreachable": true
I don't have a cisco setup available; is there a docker image somewhere that would be a good test of the enable
become method? I've never used that one before 🤔
Which version of Ansible are you running? 2.8.4 mitogen 0.2.8
Is your version of Ansible patched in any way? no
Are you running with any custom modules, or
module_utils
loaded? noHave you tried the latest master version from Git? no
Do you have some idea of what the underlying problem may be? It seems like mitogen does not implement the "enable" ansible_become_method.
Mention your host and target OS and versions Host is EL 7.7, target is IOS 15.0
Mention your host and target Python versions python 2.7.5
[WARNING]: [task 2376] 14:43:36.073559 W ansible_mitogen.connection: could not recover task_vars. This means some connection settings may erroneously be reset to their defaults. Please report a bug if you encounter this message.
[WARNING]: [task 2376] 14:43:36.074017 W ansible_mitogen.connection: could not recover task_vars. This means some connection settings may erroneously be reset to their defaults. Please report a bug if you encounter this message. [WARNING]: Unhandled error in Python interpreter discovery for host switch- cisco-4948-1.cora.nwra.com: u'enable'
Using module file /usr/lib/python2.7/site-packages/ansible/modules/network/ios/ios_facts.py Pipelining is enabled.
[WARNING]: [task 2376] 14:43:36.080669 W ansible_mitogen.connection: could not recover task_vars. This means some connection settings may erroneously be reset to their defaults. Please report a bug if you encounter this message.
[WARNING]: [task 2376] 14:43:36.080922 W ansible_mitogen.connection: could not recover task_vars. This means some connection settings may erroneously be reset to their defaults. Please report a bug if you encounter this message. The full traceback is: Traceback (most recent call last): File "/usr/lib/python2.7/site-packages/ansible/executor/task_executor.py", line 145, in run res = self._execute() File "/usr/lib/python2.7/site-packages/ansible/executor/task_executor.py", line 664, in _execute result = self._handler.run(task_vars=variables) File "/usr/lib/python2.7/site-packages/ansible/plugins/action/ios.py", line 95, in run result = super(ActionModule, self).run(task_vars=task_vars) File "/usr/lib/python2.7/site-packages/ansible/plugins/action/network.py", line 48, in run result = super(ActionModule, self).run(task_vars=task_vars) File "/usr/lib/python2.7/site-packages/ansible/plugins/action/normal.py", line 46, in run result = merge_hash(result, self._execute_module(task_vars=task_vars, wrap_async=wrap_async)) File "/usr/lib/python2.7/site-packages/ansible/plugins/action/init.py", line 917, in _execute_module
res = self._low_level_execute_command(cmd, sudoable=sudoable, in_data=in_data) File "/usr/lib/python2.7/site-packages/ansible/plugins/action/init.py", line 1062, in _low_level_execute_command
rc, stdout, stderr = self._connection.exec_command(cmd, in_data=in_data, sudoable=sudoable) File "/usr/lib/python2.7/site-packages/ansible/plugins/connection/network_cli.py", line 289, in exec_command
return super(Connection, self).exec_command(cmd, in_data, sudoable) File "/usr/lib/python2.7/site-packages/ansible/plugins/connection/init.py", line 304, in exec_command
return self._local.exec_command(cmd, in_data, sudoable) File "/export/home/orion-admin/ansible-boulder/mitogen-0.2.8/ansible_mitogen/connection.py", line 929, in exec_command
rc, stdout, stderr = self.get_chain().call( File "/export/home/orion-admin/ansible-boulder/mitogen-0.2.8/ansible_mitogen/connection.py", line 875, in get_chain
self._connect() File "/export/home/orion-admin/ansible-boulder/mitogen-0.2.8/ansible_mitogen/connection.py", line 779, in _connect inventory_name, stack = self._build_stack() File "/export/home/orion-admin/ansible-boulder/mitogen-0.2.8/ansible_mitogen/connection.py", line 717, in _build_stack stack = self._stack_from_spec(spec) File "/export/home/orion-admin/ansible-boulder/mitogen-0.2.8/ansible_mitogen/connection.py", line 700, in _stack_from_spec stack += (CONNECTION_METHODspec.become_method(),) KeyError: u'enable'
TASK [Gather facts] *** task path: /export/home/orion-admin/ansible-boulder/playbooks/cisco_portfast.yml:5 Tuesday 27 August 2019 14:48:56 -0600 (0:00:00.522) 0:00:00.522 **** [task 3558] 14:48:56.758255 D ansible_mitogen.affinity: CPU mask for WorkerProcess: 0x000004