update of ansible seems to be inconsistent

316 views
Skip to first unread message

Sebastian S.

unread,
Dec 7, 2016, 9:31:11 AM12/7/16
to Ansible Project
Hello folks,

we have a Ubuntu 14.04 box running Ansible and Ansible-Tower on it. The packages are updates regularly. The Ansible mirror is also listed in the sources.list, so it gets updates too. But there seem to be something wrong. I'm thinking this because

1. When I do a ansible --version it shows 2.0.0.2

ansible@DE9899S76 ~ % ansible --version
ansible 2.0.0.2
  config file = /etc/ansible/ansible.cfg
  configured module search path = Default w/o overrides

2. apt-get -u -V upgrade says there are no upgrade pending. The ansible package is not locked or pinned in apt.

3. apt-cache --showpkg ansible says it' 2.2.0.0

4. Playbooks with the synchronize module have a problem that has been solved in version 2.1, as far as I've read. When you use this module with become: yes, sudo is not used on the remote machine but on the ansible server.

So it looks to me like some parts have been updated to version 2.2.0.0 and others not. Can anybody explain this to me or has any tips for me to get this riddle solved? Any help would be appreciated :)


Andreas Olsson

unread,
Dec 7, 2016, 9:51:23 AM12/7/16
to ansible...@googlegroups.com
ons 2016-12-07 klockan 03:52 -0800 skrev Sebastian S.:
> ansible@DE9899S76 ~ % ansible --version
> ansible 2.0.0.2
> ....
> 3. apt-cache --showpkg ansible says it' 2.2.0.0

What does `which ansible` say?

That is, any chance that you have an additional version of Ansible
installed, in addition to what is provided by the package manager?

// Andreas

Sebastian S.

unread,
Dec 8, 2016, 2:40:30 AM12/8/16
to Ansible Project
Hi,

which ansible says: /usr/local/bin/ansible

I did a apt-get remove for ansible-tower and ansible and reinstalled both with the bundled installer, no difference.
Didn't wanted to make a apt-get purge, because I do not want to configure everything again, but meanwhile i think about a complete new installation...

Andreas Olsson

unread,
Dec 8, 2016, 3:02:31 AM12/8/16
to ansible...@googlegroups.com
ons 2016-12-07 klockan 23:40 -0800 skrev Sebastian S.:
> which ansible says: /usr/local/bin/ansible

That looks more like somewhere where Pip would install Ansible, or
where someone would install Ansible manually. Any chance that you also
have a /usr/bin/ansible, which better match the apt version?

// Andreas

Sebastian S.

unread,
Dec 8, 2016, 7:44:35 AM12/8/16
to Ansible Project
In fact there is one. But when I run this one something goes wrong:

ansible@DE9899S76 /etc/ansible/roles % /usr/bin/ansible          
Traceback (most recent call last):
  File "/usr/bin/ansible", line 46, in <module>
    from ansible.module_utils._text import to_text
ImportError: No module named _text

Sebastian S.

unread,
Dec 12, 2016, 7:53:28 AM12/12/16
to Ansible Project
You were right. There was a ansible pip installation. I uninstalled it and ansible --version is now correct. Thank you!! ^^ 

Gildas Cotomale

unread,
Dec 12, 2016, 8:16:50 AM12/12/16
to Ansible Project
I don't know how much different Debian and Ubuntu can be there.
My Debian installation, done with Pip gives the same answer.


Mike Gracy

unread,
Dec 13, 2016, 5:53:24 PM12/13/16
to Ansible Project
When you are installing from pip, you are platform independent for the most part (except assmblr/C/etc.. compiles). 
When you install via a package manager, it's a package tweaked specifically for you platform (install location mostly).
Reply all
Reply to author
Forward
0 new messages