easy_install doesn't exist in 18.04

Bug #1813492 reported by Nick Wilburn
42
This bug affects 9 people
Affects Status Importance Assigned to Milestone
kolla-ansible
Fix Released
High
Mark Goddard
Rocky
New
Undecided
Unassigned
Stein
Fix Released
High
Mark Goddard
Train
Fix Released
High
Mark Goddard

Bug Description

Kolla Version: 7.0.1
Install Type: Binary
Distro: Ubuntu 18.04

I am going through a kolla-ansible all-in-one installation following the documentation listed here: https://docs.openstack.org/kolla-ansible/latest/user/quickstart.html

Running kolla-ansible -i ./all-in-one bootstrap-servers will error out in the baremetal role here: https://github.com/openstack/kolla-ansible/blob/master/ansible/roles/baremetal/tasks/install.yml#L110

The easy_install task errors out on ubuntu18.04 because easy_install isn't install-able in Ubuntu 18.04 see here: https://bugs.launchpad.net/ubuntu/+source/python-setuptools/+bug/1774419

There are several workarounds while this bug is still open which I think should be applied. Currently the installation does not work without modifying the role which feels very dirty and offputting.

1) Check for the existence of Pip and document its requirement before installation. If pip exists we don't need easy_install to download it and we can proceed. If it doesn't we can error out with a helpful error message.

2) Install pip directly using `curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py`
This is less optimal as it obviously won't work for offline environments. We could allow the configuration of a "get-pip" URL which would default to bootstrap.pypa.io, but it would be easier to just use option #1.

I'm more than happy to make a PR for either of these options. Please let me know your thoughts.

- Nick

Revision history for this message
Mikael Johansson (mikjoh) wrote :

We used the following workaround, yes it's a matter of changing in the baremetal role tasks (quick n dirty). We're also running version 7.0.1 of kolla-ansible and have tried to deploy new compute hosts on 18.04.

Besides hitting and backporting the fix for this bug: https://bugs.launchpad.net/kolla-ansible/+bug/1791355, we did the following:

1. Removed the "Install pip" task in baremetal/tasks/install.yml
2. Added "python-pip" package to debian_pkg_install in baremetal/defaults/main.yml

Revision history for this message
Vladimir Franciz S. Blando (vblando) wrote :

I also encountered this bug on my Ubuntu 18 and what I did was change "easy_install" to "package" on the baremetal role.

Revision history for this message
Igor D.C. (igordc) wrote :

Ubuntu 18.04 here, same issue. Using "package" didn't solve it for me though, as it failed for a different reason. Instead, I used "pip" instead of "easy_install".

Mark Goddard (mgoddard)
Changed in kolla-ansible:
status: New → Confirmed
importance: Undecided → High
Revision history for this message
Mark Goddard (mgoddard) wrote :

I proposed this as a solution: https://review.openstack.org/651136

It installs the python-pip package and skips easy_install task on ubuntu 18.04+.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to kolla-ansible (master)

Reviewed: https://review.openstack.org/651136
Committed: https://git.openstack.org/cgit/openstack/kolla-ansible/commit/?id=c1c02f67dcb28a8722d505ddf6a24a37c1f874d7
Submitter: Zuul
Branch: master

commit c1c02f67dcb28a8722d505ddf6a24a37c1f874d7
Author: Mark Goddard <email address hidden>
Date: Tue Apr 9 09:23:14 2019 +0100

    Don't use easy_install on Ubuntu 18+

    Currently easy_install is not available on Ubuntu 18+ due to [1]. In
    that case, install pip via apt rather than easy_install.

    [1]
    https://bugs.launchpad.net/ubuntu/+source/python-setuptools/+bug/1774419

    Change-Id: Id358fdb655d71490b0915680dff131cfe33f4a40
    Closes-Bug: #1813492

Changed in kolla-ansible:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to kolla-ansible (stable/stein)

Fix proposed to branch: stable/stein
Review: https://review.openstack.org/651481

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to kolla-ansible (stable/rocky)

Fix proposed to branch: stable/rocky
Review: https://review.openstack.org/651482

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to kolla-ansible (master)

Related fix proposed to branch: master
Review: https://review.openstack.org/651498

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to kolla-ansible (master)

Reviewed: https://review.openstack.org/651498
Committed: https://git.openstack.org/cgit/openstack/kolla-ansible/commit/?id=88bf4075bd711de99d86565487f538aa63a7f973
Submitter: Zuul
Branch: master

commit 88bf4075bd711de99d86565487f538aa63a7f973
Author: Mark Goddard <email address hidden>
Date: Wed Apr 10 12:07:33 2019 +0100

    Don't install empty package name on old Ubuntu

    Follow up to https://review.openstack.org/#/c/651136/, which fails on
    Ubuntu versions prior to 18.04.

    Change-Id: I74a85dec95ceed7c6eeafb9eb1920c7c30b3e64a
    Related-Bug: #1813492

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to kolla-ansible (stable/stein)

Reviewed: https://review.openstack.org/651481
Committed: https://git.openstack.org/cgit/openstack/kolla-ansible/commit/?id=17a634af581742a4d4935cf4bf01fe403e3c6831
Submitter: Zuul
Branch: stable/stein

commit 17a634af581742a4d4935cf4bf01fe403e3c6831
Author: Mark Goddard <email address hidden>
Date: Tue Apr 9 09:23:14 2019 +0100

    Don't use easy_install on Ubuntu 18+

    Currently easy_install is not available on Ubuntu 18+ due to [1]. In
    that case, install pip via apt rather than easy_install.

    [1]
    https://bugs.launchpad.net/ubuntu/+source/python-setuptools/+bug/1774419

    Change-Id: Id358fdb655d71490b0915680dff131cfe33f4a40
    Closes-Bug: #1813492
    (cherry picked from commit c1c02f67dcb28a8722d505ddf6a24a37c1f874d7)

tags: added: in-stable-stein
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to kolla-ansible (stable/rocky)

Reviewed: https://review.openstack.org/651482
Committed: https://git.openstack.org/cgit/openstack/kolla-ansible/commit/?id=3203d19c38eabafde047753b805c31174ec33b17
Submitter: Zuul
Branch: stable/rocky

commit 3203d19c38eabafde047753b805c31174ec33b17
Author: Mark Goddard <email address hidden>
Date: Tue Apr 9 09:23:14 2019 +0100

    Don't use easy_install on Ubuntu 18+

    Currently easy_install is not available on Ubuntu 18+ due to [1]. In
    that case, install pip via apt rather than easy_install.

    [1]
    https://bugs.launchpad.net/ubuntu/+source/python-setuptools/+bug/1774419

    Change-Id: Id358fdb655d71490b0915680dff131cfe33f4a40
    Closes-Bug: #1813492
    (cherry picked from commit c1c02f67dcb28a8722d505ddf6a24a37c1f874d7)

tags: added: in-stable-rocky
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/kolla-ansible 7.1.1

This issue was fixed in the openstack/kolla-ansible 7.1.1 release.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/kolla-ansible 8.0.0.0rc2

This issue was fixed in the openstack/kolla-ansible 8.0.0.0rc2 release candidate.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/kolla-ansible 9.0.0.0rc1

This issue was fixed in the openstack/kolla-ansible 9.0.0.0rc1 release candidate.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.