multi-node setup fails to create glance cache directory
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
devstack |
Fix Released
|
Undecided
|
Daniel Gonzalez Nothnagel |
Bug Description
When creating a multi-node setup (as explained in the readme) the stack.sh run fails because g-api fails to start:
+ service_check
+ local service
+ local failures
+ SCREEN_NAME=stack
+ SERVICE_
+ [[ ! -d /opt/stack/
++ ls /opt/stack/
+ failures=
+ for service in '$failures'
++ basename /opt/stack/
+ service=
+ service=g-api
+ echo 'Error: Service g-api is not running'
Error: Service g-api is not running
+ '[' -n /opt/stack/
+ die 1376 'More details about the above errors can be found with screen, with ./rejoin-stack.sh'
+ local exitcode=0
+ set +o xtrace
[Call Trace]
./stack.
/home/vagrant/
[ERROR] /home/vagrant/
Error on exit
World dumping... see /opt/stack/
In the g-api screen session the following stack trace is printed:
2015-04-07 14:32:26.500 CRITICAL glance [-] OSError: [Errno 13] Permission denied: '/var/cache/glance'
2015-04-07 14:32:26.500 TRACE glance Traceback (most recent call last):
2015-04-07 14:32:26.500 TRACE glance File "/usr/local/
2015-04-07 14:32:26.500 TRACE glance sys.exit(main())
2015-04-07 14:32:26.500 TRACE glance File "/opt/stack/
2015-04-07 14:32:26.500 TRACE glance server.
2015-04-07 14:32:26.500 TRACE glance File "/opt/stack/
2015-04-07 14:32:26.500 TRACE glance app = deploy.
2015-04-07 14:32:26.500 TRACE glance File "/usr/local/
2015-04-07 14:32:26.500 TRACE glance return loadobj(APP, uri, name=name, **kw)
2015-04-07 14:32:26.500 TRACE glance File "/usr/local/
2015-04-07 14:32:26.500 TRACE glance return context.create()
2015-04-07 14:32:26.500 TRACE glance File "/usr/local/
2015-04-07 14:32:26.500 TRACE glance return self.object_
2015-04-07 14:32:26.500 TRACE glance File "/usr/local/
2015-04-07 14:32:26.500 TRACE glance app = filter(app)
2015-04-07 14:32:26.500 TRACE glance File "/usr/local/
2015-04-07 14:32:26.500 TRACE glance return AuthProtocol(app, conf)
2015-04-07 14:32:26.500 TRACE glance File "/usr/local/
2015-04-07 14:32:26.500 TRACE glance directory_
2015-04-07 14:32:26.500 TRACE glance File "/usr/local/
2015-04-07 14:32:26.500 TRACE glance self._verify_
2015-04-07 14:32:26.500 TRACE glance File "/usr/local/
2015-04-07 14:32:26.500 TRACE glance os.makedirs(
2015-04-07 14:32:26.500 TRACE glance File "/usr/lib/
2015-04-07 14:32:26.500 TRACE glance makedirs(head, mode)
2015-04-07 14:32:26.500 TRACE glance File "/usr/lib/
2015-04-07 14:32:26.500 TRACE glance mkdir(name, mode)
2015-04-07 14:32:26.500 TRACE glance OSError: [Errno 13] Permission denied: '/var/cache/glance'
2015-04-07 14:32:26.500 TRACE glance
g-api failed to start
I think the problem is that the init_glance function (which creates the cache directory) only gets called if g-reg is enabled, but not if g-api is enabled.
Fix proposed to branch: master /review. openstack. org/171239
Review: https:/