stack.sh stable/havana fails on Ubuntu 12.04.2

Bug #1328530 reported by Joel Wright
34
This bug affects 6 people
Affects Status Importance Assigned to Milestone
devstack
Invalid
Undecided
Unassigned

Bug Description

stack.sh fails to complete using the stable/havana branch on Ubuntu 12.04.2. The log shows lots of errors regarding the six dependency:

Traceback (most recent call last):
 File "/usr/local/bin/swift-init", line 4, in <module>
   from pkg_resources import require; require('swift==1.10.0.7.gf9c44df')
 File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 2707, in <module>
   working_set.require(__requires__)
 File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 686, in require
   needed = self.resolve(parse_requirements(requirements))
 File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 584, in resolve
   raise DistributionNotFound(req)
pkg_resources.DistributionNotFound: six>=1.4.1

The script ultimately fails attempting to create glance images:

 glance --os-auth-token <snip> --os-image-url http://192.168.42.23:9292 image-create --name cirros-0.3.1-x86_64-uec --is-public True --container-format ami --disk-format ami
400 Bad Request
Client disconnected before sending all data to backend
    (HTTP 400)
++ failed
++ local r=1
+++ jobs -p
++ kill
++ set +o xtrace

Revision history for this message
Joel Wright (joel-wright-k) wrote :

commit e4dda729ef9670927978f49c9d21f160c0457efb works fine, so this seems to have been caused by one of the following:

"be opinionated: only use get-pip.py" (commit 6bb36694994ce051798f8a0e975de1b82e62f831)
"make get-pip.py download failures more clear" (commit 4c8b249d01632e8090abe758dbb681a0ee68a8b9)

Revision history for this message
Amina Mseddi (amina-mseddi) wrote :

Try to upgrade setuptools to the newest version. It worked for me.

Revision history for this message
Joel Wright (joel-wright-k) wrote :

If that works it would still need to be included in the devstack stack.sh script. I'll try it, but I would expect stack.sh to "just work" on a clean install of a supported system.

Revision history for this message
Joel Wright (joel-wright-k) wrote :

I forgot to mention, I received the same failure on 2 clean virtual machines running a fully updated version of Ubuntu Server 12.04.2.

Will try again after also running pip install --upgrade setuptools for the system.

Revision history for this message
Joel Wright (joel-wright-k) wrote :

Ok, I can confirm that running 'pip install --upgrade setuptools' as root before running stack.sh on a clean install of Ubuntu Server 12.04.2 allows the script to complete successfully, but leaving that step out causes the script to fail.

Revision history for this message
Gary Duan (gduan) wrote :

Upgrade setuptools doesn't seem to resolve the problem in me environment. I got the following error. Even I manually install pip 1.4.1, it is uninstalled by devstack and 1.5.6 is put on.

+ install_get_pip
+ [[ ! -r /home/varmour/workspace/devstack/files/get-pip.py ]]
+ sudo -E python /home/varmour/workspace/devstack/files/get-pip.py
/usr/lib/python2.7/dist-packages/setuptools/command/install_scripts.py:3: UserWarning: Module pip was already imported from /tmp/tmpXQI4XG/pip.zip/pip/__init__.py, but /usr/local/lib/python2.7/dist-packages/pip-1.4.1-py2.7.egg is being added to sys.path
  from pkg_resources import Distribution, PathMetadata, ensure_directory
Downloading/unpacking pip from https://pypi.python.org/packages/py2.py3/p/pip/pip-1.5.6-py2.py3-none-any.whl#md5=4d4fb4b69df6731c7aeaadd6300bc1f2
Installing collected packages: pip
  Found existing installation: pip 1.4.1
    Uninstalling pip:
      Successfully uninstalled pip
Successfully installed pip
Cleaning up...
+ get_versions
++ which pip
+ PIP=/usr/local/bin/pip
+ [[ -n /usr/local/bin/pip ]]
++ /usr/local/bin/pip --version
++ awk '{ print $2}'
Traceback (most recent call last):
  File "/usr/local/bin/pip", line 5, in <module>
    from pkg_resources import load_entry_point
  File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 2707, in <module>
    working_set.require(__requires__)
  File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 686, in require
    needed = self.resolve(parse_requirements(requirements))
  File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 584, in resolve
    raise DistributionNotFound(req)
pkg_resources.DistributionNotFound: pip==1.4.1
+ PIP_VERSION=
+ echo 'pip: '
pip:

Revision history for this message
prof haury (prof-haury) wrote :

This issue presented itself between multiple installs, with the initial installs working fine and then all of a sudden the stack.sh failing at the downloading images section with the "400 Bad Request / Client disconnected before sending all data to backend" message. Ran "wget https://bootstrap.pypa.io/ez_setup.py -O - | sudo python" after a ./clean.sh and the stack.sh completed successsfully with the images display with nova image -list.

Revision history for this message
Parashuram Hallur (hallur-p-t) wrote :

(As a root) Pip install and upgrade of setuptools helped me fix this issue.

Revision history for this message
Sean Dague (sdague) wrote :

This devstack bug was last updated over 180 days ago, as devstack
is a fast moving project and we'd like to get the tracker down to
currently actionable bugs, this is getting marked as Invalid. If the
issue still exists, please feel free to reopen it.

Changed in devstack:
status: New → Invalid
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.