It sounds like you have a `_io.so` file that was compiled against a different python version, from that which is attempting to use it.
Using python from an SCL as your ansible_python_interpreter is not just an easy 1 and done, by using the correct path. An SCL sets things like LD_LIBRARY_PATH and such when you enable it, that is not achieved by simply calling the binary in its place. It looks like you are using `localhost`, which I will assume is "implicit localhost"[1] which automatically selects the python interpreter used by the playbook process, but since that work happens in a fork, I imagine it loses the SCL env vars required to use that SCL. Overall, I'd probably recommend not using an SCL. Otherwise, you are going to have to jump through some hoops that are going to require that you better understand what needs to be done. [1] https://docs.ansible.com/ansible/latest/inventory/implicit_localhost.html On Mon, Jul 20, 2020 at 10:59 AM Nagesh sheregar <[email protected]> wrote: > Hi Team, > > did anyone face this issue, it was working fine but today i am getting > below error not sure what happened: > > fatal: [localhost]: FAILED! => { > "ansible_facts": {}, > "changed": false, > "failed_modules": { > "setup": { > "exception": "Traceback (most recent call last):\n File > \"/root/.ansible/tmp/ansible-tmp-1595260298.32-3449-114062721166446/AnsiballZ_setup.py\", > line 102, in <module>\n _ansiballz_main()\n File > \"/root/.ansible/tmp/ansible-tmp-1595260298.32-3449-114062721166446/AnsiballZ_setup.py\", > line 20, in _ansiballz_main\n import tempfile\n File > \"/opt/rh/python27/root/usr/lib64/python2.7/tempfile.py\", line 32, in > <module>\n import io as _io\n File > \"/opt/rh/python27/root/usr/lib64/python2.7/io.py\", line 51, in > <module>\n import _io\nImportError: > /opt/rh/python27/root/usr/lib64/python2.7/lib-dynload/_io.so: undefined > symbol: _PyErr_ReplaceException\n", > "failed": true, > "module_stderr": "Traceback (most recent call last):\n File > \"/root/.ansible/tmp/ansible-tmp-1595260298.32-3449-114062721166446/AnsiballZ_setup.py\", > line 102, in <module>\n _ansiballz_main()\n File > \"/root/.ansible/tmp/ansible-tmp-1595260298.32-3449-114062721166446/AnsiballZ_setup.py\", > line 20, in _ansiballz_main\n import tempfile\n File > \"/opt/rh/python27/root/usr/lib64/python2.7/tempfile.py\", line 32, in > <module>\n import io as _io\n File > \"/opt/rh/python27/root/usr/lib64/python2.7/io.py\", line 51, in > <module>\n import _io\nImportError: > /opt/rh/python27/root/usr/lib64/python2.7/lib-dynload/_io.so: undefined > symbol: _PyErr_ReplaceException\n", > "module_stdout": "", > "msg": "MODULE FAILURE\nSee stdout/stderr for the exact error", > "rc": 1 > } > }, > "msg": "The following modules failed to execute: setup\n" > } > > -- > You received this message because you are subscribed to the Google Groups > "Ansible Project" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/ansible-project/a78635ad-4bae-4a07-b8c4-6ff0e88ff6beo%40googlegroups.com > <https://groups.google.com/d/msgid/ansible-project/a78635ad-4bae-4a07-b8c4-6ff0e88ff6beo%40googlegroups.com?utm_medium=email&utm_source=footer> > . > -- Matt Martz @sivel sivel.net -- You received this message because you are subscribed to the Google Groups "Ansible Project" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/ansible-project/CAD8N0v_%2BkaNhZ9Pp_oJLzGXHr8OfUrXemE1cT1BQsxODhAM9OA%40mail.gmail.com.
