Does /etc/glance/policy.json exist? Is is readable?
----- Original Message ----- > From: ".。o 0 O泡泡" <[email protected]> > To: "openstack" <[email protected]> > Sent: Wednesday, 7 March, 2012 2:06:50 PM > Subject: [Openstack] can not start glance-api in glance E4 > > > hi all: > > In glance E4 ,when I enter follows: > sudo glance-api glance-api.conf --debug & > It returns : > 2012-03-07 21:53:50 26589 ERROR [glance.store.filesystem] Could not > find filesystem_store_datadir in configuration options. > 2012-03-07 21:53:50 26589 ERROR [glance.store.base] Failed to > configure store correctly. Disabling add method. > 2012-03-07 21:53:50 26589 ERROR [glance.store.s3] Could not find > s3_store_host in configuration options. > 2012-03-07 21:53:50 26589 ERROR [glance.store.base] Failed to > configure store correctly. Disabling add method. > 2012-03-07 21:53:50 26589 ERROR [glance.store.swift] Could not find > swift_store_auth_address in configuration options. > 2012-03-07 21:53:50 26589 ERROR [glance.store.base] Failed to > configure store correctly. Disabling add method. > Traceback (most recent call last): > File "/usr/local/bin/glance-api", line 5, in <module> > pkg_resources.run_script('glance==2012.1', 'glance-api') > File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 467, > in run_script > self.require(requires)[0].run_script(script_name, ns) > File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 1200, > in run_script > execfile(script_filename, namespace, namespace) > File > "/usr/local/lib/python2.7/dist-packages/glance-2012.1-py2.7.egg/EGG-INFO/scripts/glance-api", > line 48, in <module> > app = config.load_paste_app(conf) > File > "/usr/local/lib/python2.7/dist-packages/glance-2012.1-py2.7.egg/glance/common/config.py", > line 174, in load_paste_app > app = wsgi.paste_deploy_app(conf_file, app_name, conf) > File > "/usr/local/lib/python2.7/dist-packages/glance-2012.1-py2.7.egg/glance/common/wsgi.py", > line 647, in paste_deploy_app > return deploy.loadapp("config:%s" % paste_config_file, name=app_name) > File "/usr/lib/python2.7/dist-packages/paste/deploy/loadwsgi.py", > line 247, in loadapp > return loadobj(APP, uri, name=name, **kw) > File "/usr/lib/python2.7/dist-packages/paste/deploy/loadwsgi.py", > line 272, in loadobj > return context.create() > File "/usr/lib/python2.7/dist-packages/paste/deploy/loadwsgi.py", > line 710, in create > return self.object_type.invoke(self) > File "/usr/lib/python2.7/dist-packages/paste/deploy/loadwsgi.py", > line 203, in invoke > app = context.app_context.create() > File "/usr/lib/python2.7/dist-packages/paste/deploy/loadwsgi.py", > line 710, in create > return self.object_type.invoke(self) > File "/usr/lib/python2.7/dist-packages/paste/deploy/loadwsgi.py", > line 146, in invoke > return fix_call(context.object, context.global_conf, > **context.local_conf) > File "/usr/lib/python2.7/dist-packages/paste/deploy/util.py", line > 56, in fix_call > val = callable(*args, **kw) > File > "/usr/local/lib/python2.7/dist-packages/glance-2012.1-py2.7.egg/glance/common/wsgi.py", > line 573, in __call__ > return factory(self.conf, **local_conf) > File > "/usr/local/lib/python2.7/dist-packages/glance-2012.1-py2.7.egg/glance/api/v1/router.py", > line 37, in __init__ > images_resource = images.create_resource(conf) > File > "/usr/local/lib/python2.7/dist-packages/glance-2012.1-py2.7.egg/glance/api/v1/images.py", > line 965, in create_resource > return wsgi.Resource(Controller(conf), deserializer, serializer) > File > "/usr/local/lib/python2.7/dist-packages/glance-2012.1-py2.7.egg/glance/api/v1/images.py", > line 100, in __init__ > self.policy = policy.Enforcer(conf) > File > "/usr/local/lib/python2.7/dist-packages/glance-2012.1-py2.7.egg/glance/api/policy.py", > line 41, in __init__ > self.policy_path = self._find_policy_file(conf) > File > "/usr/local/lib/python2.7/dist-packages/glance-2012.1-py2.7.egg/glance/api/policy.py", > line 66, in _find_policy_file > raise cfg.ConfigFilesNotFoundError(('policy.json',)) > glance.common.cfg.ConfigFilesNotFoundError: Failed to read some > config files: policy.json > > > because I don't want to use swift and s3,I add "#" in the head of > every line about swift and s3..and configure " > filesystem_store_datadir = /var/lib/glance/images/".. > but It still the same return when I enter the cmd again.. > and now ,I have no idea of how to get it start .. > Looking for anyone's help :) > thanks a lot.. > > _______________________________________________ > Mailing list: https://launchpad.net/~openstack > Post to : [email protected] > Unsubscribe : https://launchpad.net/~openstack > More help : https://help.launchpad.net/ListHelp > _______________________________________________ Mailing list: https://launchpad.net/~openstack Post to : [email protected] Unsubscribe : https://launchpad.net/~openstack More help : https://help.launchpad.net/ListHelp

