m.dr (70) [Avatar] Offline
#1
Hello Cody -

Thank you for your OpenStack book!

I was installing DevStack using Vagrant and a script that git clones the devstack repo and script is listed below.

It works fine, I log into the Vagrant box and go to the devstack directory and run script.sh.

Which then starts downloading and installing: cinder, glance, keystone, noVNC, wheelhouse and such.

But when it comes to nova it cannot do a git pull and fails, error below.

...
It has happened a couple of times now and just can't get beyond this, although when I initially tried about 2 weeks ago it all worked fine.

Then I destroyed the box and tried to rebuild it but has not happened since.

I know you provided a box and that has started up fine - but I wanted to do a basic install and set up myself so was trying this from a Vagrant box I found on the web.

I tried a git pull manually as well using git clone git://git.openstack.org/openstack/nova.git /opt/stack/nova (same as being run from script) does not work. Does not work, even if I pre-emptively create the /opt/stack/nova directory.
vagrant@devstack:/opt/stack/nova$ git clone git://git.openstack.org/openstack/nova.git
Cloning into 'nova'...
fatal: The remote end hung up unexpectedly


However a git clone in the /home/vagrant directory works fine!
vagrant@devstack:~$ git clone git://git.openstack.org/openstack/nova.git
Cloning into 'nova'...
remote: Counting objects: 326364, done.
remote: Compressing objects: 91% (128338/140106)

All permissions are fine, set to Vagrant. In fact in the script it pulls into cinder, glance, keystone, noVNC, wheelhouse directories. No problem in creating them.

Its just the nova that is behaving so unexpectedly - in fact not sure what is going on as it seems like a specfic git issue. Again, I checked permissions in directory and such.

Any suggestions with this weird issue will be very helpful, although I understand this is likely not in the scope of your book. But I have tried all I think I can.

Btw would you know if Vagrant can install DevStack directly w/o having to need a script, like it can do for SaltStack and Ansible?

Thank you.

------------------------ Git pull fails on Nova ---------------------------

2015-03-11 18:15:14.007 | + [[ 128 -ne 124 ]]
2015-03-11 18:15:14.007 | + die 689 'git call failed: [git clone' git://git.openstack.org/openstack/nova.git '/opt/stack/nova]'
2015-03-11 18:15:14.008 | + local exitcode=0
2015-03-11 18:15:14.008 | [Call Trace]
2015-03-11 18:15:14.009 | ./stack.sh:772:stack_install_service
2015-03-11 18:15:14.009 | /home/vagrant/devstack/lib/stack:24:install_nova
2015-03-11 18:15:14.009 | /home/vagrant/devstack/lib/nova:689:git_clone
2015-03-11 18:15:14.010 | /home/vagrant/devstack/functions-common:623:git_timed
2015-03-11 18:15:14.010 | /home/vagrant/devstack/functions-common:689:die
2015-03-11 18:15:14.013 | [ERROR] /home/vagrant/devstack/functions-common:689 git call failed: [git clone git://git.openstack.org/openstack/nova.git /opt/stack/nova]
2015-03-11 18:15:15.018 | Error on exit

------------------------ Script (for reference) ---------------------------

# download required packages
sudo apt-get update
sudo apt-get -y install git vim-gtk libxml2-dev libxslt1-dev libpq-dev python-pip libsqlite3-dev
sudo apt-get -y build-dep python-mysqldb
sudo pip install git-review tox

# download devstack
git clone git://git.openstack.org/openstack-dev/devstack
chown -R vagrant:vagrant devstack

# create minimal localrc
cat <<_LOCALRC > devstack/localrc
ADMIN_PASSWORD=password
MYSQL_PASSWORD=password
RABBIT_PASSWORD=password
SERVICE_PASSWORD=password
SERVICE_TOKEN=tokentoken

LOGFILE=stack.sh.log
LOGDAYS=1

# data must not be inside NFS share
# because devstack tries to chown directories
# and NFS doesn't allow it
DATA_DIR=/opt/data
_LOCALRC
fkautz (1) [Avatar] Offline
#2
Try adding this to your local.conf:

GIT_BASE=http://github.com


It'll download from github rather than openstack's build infrastructure.
420940 (1) [Avatar] Offline
#3
Thanks for the tip! Switching from git.openstack.org to github.com fixed the issue I was having with Nova.