python-2.7ubuntuopenstack-horizon

OpenStack horizon unable to find token


I am developing OpenStack horizon, and follow quick start at http://docs.openstack.org/developer/horizon/quickstart.html to begin. but as I add my backend service url to local_settings.py, and start server. It just throws error like:

Unauthorized: Could not find token, 99a3682bc1e3a0ca55cb51436a2ff766. (HTTP 401) Unable to retrieve project list. Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/openstack_auth/user.py", line 308, in authorized_tenants is_federated=self.is_federated) File "/usr/local/lib/python2.7/dist-packages/openstack_auth/utils.py", line 145, in wrapper result = func(*args, **kwargs) File "/usr/local/lib/python2.7/dist-packages/openstack_auth/utils.py", line 256, in get_project_list projects = client.tenants.list() File "/usr/local/lib/python2.7/dist-packages/keystoneclient/v2_0/tenants.py", line 123, in list tenant_list = self._list('/tenants%s' % query, 'tenants') File "/usr/local/lib/python2.7/dist-packages/keystoneclient/base.py", line 113, in _list resp, body = self.client.get(url, **kwargs) File "/usr/local/lib/python2.7/dist-packages/keystoneclient/adapter.py", line 170, in get return self.request(url, 'GET', **kwargs) File "/usr/local/lib/python2.7/dist-packages/keystoneclient/adapter.py", line 206, in request resp = super(LegacyJsonAdapter, self).request(*args, **kwargs) File "/usr/local/lib/python2.7/dist-packages/keystoneclient/adapter.py", line 95, in request return self.session.request(url, method, **kwargs) File "/usr/local/lib/python2.7/dist-packages/keystoneclient/utils.py", line 336, in inner return func(*args, **kwargs) File "/usr/local/lib/python2.7/dist-packages/keystoneclient/session.py", line 397, in request raise exceptions.from_response(resp, method, url) Unauthorized: Could not find token, 99a3682bc1e3a0ca55cb51436a2ff766. (HTTP 401) Unable to retrieve project list. Traceback (most recent call last):


Solution

  • Make sure that your Horizon can access to the 35357 (keystone admin) port of your Openstack deployment. If Horizon can't access to this port, it will show the same errors.