Revision history [back]

click to hide/show revision 1
initial version

Howto setup dashboard for Swift

My environment is a Virtual Machine : ubuntu-11.04-server-i386 installed newest swift+keystone+dashboard all in one

I'm follow the tutorial Swift Integration - Quick Start install keystone for swift

root@swift-proxy:~# keystone Starting the RAX-KEY extension Starting the Legacy Authentication component Service API listening on 0.0.0.0:5000 Admin API listening on 0.0.0.0:35357

cd ~/keystone/bin && ./sampledata ...... SUCCESS: Created EndpointTemplates for swift pointing to http://127.0.0.1:8888/v1/AUTH_%tenant_id%. SUCCESS: Created EndpointTemplates for nova_compat pointing to http://nova.publicinternets.com/v1.0/. SUCCESS: Created EndpointTemplates for nova pointing to http://nova.publicinternets.com/v1.1/. SUCCESS: Created EndpointTemplates for glance pointing to http://glance.publicinternets.com/v1.1/%tenant_id%. SUCCESS: Created EndpointTemplates for cdn pointing to http://cdn.publicinternets.com/v1.1/%tenant_id%. SUCCESS: Created EndpointTemplates for swift pointing to http://127.0.0.1:8888/v1/AUTH_%tenant_id%. SUCCESS: Created EndpointTemplates for nova pointing to http://nova.publicinternets.com/v1.0/. SUCCESS: Created EndpointTemplates for nova_compat pointing to http://nova.publicinternets.com/v1.1/. SUCCESS: Created EndpointTemplates for glance pointing to http://glance.publicinternets.com/v1.1/%tenant_id%. SUCCESS: Created EndpointTemplates for cdn pointing to http://cdn.publicinternets.com/v1.1/%tenant_id%. SUCCESS: Created EndpointTemplates for identity pointing to http://keystone.publicinternets.com/v2.0. ......

root@swift-proxy:/usr/src# swift -A http://127.0.0.1:5000/v1.0 -U joeuser -K secrete stat -v StorageURL: http://127.0.0.1:8888/v1/AUTH_1 Auth Token: 887665443383838 Account: AUTH_1 Containers: 2 Objects: 24 Bytes: 179853 Accept-Ranges: bytes X-Trans-Id: txb3cef26bdc98483782d7f18a25f5a34b return is OK!

after successful login as 'joeuser' at dashboard , but 'click' the button 'Manage Object Store - Containers' then meets follow errors:

ResponseError at /dash/1/containers/ 302: Found Request Method: GET Request URL: http://192.168.1.58:8000/dash/1/containers/ Django Version: 1.3 Exception Type: ResponseError Exception Value: 302: Found Exception Location: /root/openstack-dashboard/openstack-dashboard/.dashboard-venv/local/lib/python2.7/site-packages/cloudfiles/connection.py in list_containers_info, line 386 Python Executable: /root/openstack-dashboard/openstack-dashboard/.dashboard-venv/bin/python

at the console for tools/with_venv.sh dashboard/manage.py runserver 0.0.0.0:8000 ruturn follow informations

DEBUG:django.db.backends:(0.001) SELECT "django_session"."session_key", "django_session"."session_data", "django_session"."expire_date" FROM "django_session" WHERE ("django_session"."session_key" = d159ef1a15bfc54ba222f79bf5c1c8d6 AND "django_session"."expire_date" > 2011-10-09 09:23:18.310410 ); args=('d159ef1a15bfc54ba222f79bf5c1c8d6', u'2011-10-09 09:23:18.310410') DEBUG:django_openstack.api:object store connection created using token "887665443383838" and url "http://127.0.0.1:8080/v1/AUTH_1" CRITICAL:openstack_dashboard:Unhandled Exception in of type "<class 'cloudfiles.errors.responseerror'="">" in dashboard. Traceback (most recent call last): File "/root/openstack-dashboard/openstack-dashboard/.dashboard-venv/local/lib/python2.7/site-packages/django/core/handlers/base.py", line 111, in get_response response = callback(request, callback_args, callback_kwargs) File "/root/openstack-dashboard/openstack-dashboard/.dashboard-venv/local/lib/python2.7/site-packages/django/contrib/auth/decorators.py", line 23, in _wrapped_view return view_func(request, *args, *kwargs) File "/root/openstack-dashboard/django-openstack/django_openstack/dash/views/containers.py", line 74, in index containers = api.swift_get_containers(request) File "/root/openstack-dashboard/django-openstack/django_openstack/api.py", line 771, in swift_get_containers return [Container(c) for c in swift_api(request).get_all_containers()] File "/root/openstack-dashboard/openstack-dashboard/.dashboard-venv/local/lib/python2.7/site-packages/cloudfiles/connection.py", line 303, in get_all_containers return ContainerResults(self, self.list_containers_info(parms)) File "/root/openstack-dashboard/openstack-dashboard/.dashboard-venv/local/lib/python2.7/site-packages/cloudfiles/connection.py", line 386, in list_containers_info raise ResponseError(response.status, response.reason) ResponseError: 302: Found [09/Oct/2011 09:23:18] "GET /dash/1/containers/ HTTP/1.1" 500 85455 DEBUG:django.db.backends:(0.000) SELECT "django_session"."session_key", "django_session"."session_data", "django_session"."expire_date" FROM "django_session" WHERE ("django_session"."session_key" = d159ef1a15bfc54ba222f79bf5c1c8d6 AND "django_session"."expire_date" > 2011-10-09 09:23:18.495769 ); args=('d159ef1a15bfc54ba222f79bf5c1c8d6', u'2011-10-09 09:23:18.495769')