Skip to content
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

Opening for visibility: service_facts broken in Ubuntu 20.04 #274

Closed
rromanchuk opened this issue Apr 25, 2020 · 6 comments
Closed

Opening for visibility: service_facts broken in Ubuntu 20.04 #274

rromanchuk opened this issue Apr 25, 2020 · 6 comments

Comments

@rromanchuk
Copy link

ansible/ansible#68211

ansible/ansible#68536

@KSerrania
Copy link
Contributor

Hi @rromanchuk,

Thanks for reporting this! We'll add a note in the README about this issues and how to fix it by upgrading Ansible (once the mentioned fix is released).

@aplsms
Copy link

aplsms commented Jul 18, 2020

Any updates? I have the same issue.

@enys
Copy link

enys commented Jul 18, 2020

I can confirm this has been fixed. You only need to upgrade your version of ansible

@neilee
Copy link

neilee commented Oct 21, 2020

I can confirm this has been fixed. You only need to upgrade your version of ansible

Hi, could you kindly confirm which version you need to upgrade to? I still seem to get this issue on the latest (apt) install of ansible on focal 20.04, and the PPA still does not appear to have a focal release so I would consider this the latest release as per the install instructions on the Ansible website for Ubuntu.

Thanks in advance!!

neil@desk:~$ lsb_release -a
No LSB modules are available.
Distributor ID:	Ubuntu
Description:	Ubuntu 20.04.1 LTS
Release:	20.04
Codename:	focal

neil@desk:~$ ansible --version
ansible 2.9.6
  config file = /etc/ansible/ansible.cfg
  configured module search path = ['/home/neil/.ansible/plugins/modules', '/usr/share/ansible/plugins/modules']
  ansible python module location = /usr/lib/python3/dist-packages/ansible
  executable location = /usr/local/bin/ansible
  python version = 3.8.5 (default, Jul 28 2020, 12:59:40) [GCC 9.3.0]

neil@desk:~$ ansible -m service_facts localhost
localhost | FAILED! => {
    "changed": false,
    "msg": "Malformed output discovered from systemd list-unit-files: accounts-daemon.service                    enabled         enabled      "
}

@ghost
Copy link

ghost commented Oct 28, 2020

I replicate the error described by neilee.

@neilee
Copy link

neilee commented Oct 28, 2020

Just to update, this looks like it's fixed when you install ansible via pip (pip3 install ansible) instead of apt. The version in the focal repo needs to be updated.

As at 2020.10.28:

  • Version installed using apt: 2.9.6
  • Version installed by pip3: 2.10.2

So it's obviously been fixed after version 2.9.6.

cp -r /etc/ansible /etc/ansible.old
apt purge ansible
apt install python3-pip
pip3 install ansible

neil@desk:~$ ansible -m service_facts localhost | tail
            "[email protected]": {
                "name": "[email protected]",
                "source": "systemd",
                "state": "unknown",
                "status": "static"
            }
        }
    },
    "changed": false
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants