Revision history [back]

click to hide/show revision 1
initial version

Getting 500 internal server error while accessing horizon dashboard in ubuntu icehouse

Hi, While accessing horizon dashboard(ubuntu:icehouse) I am getting 500 internal server error. apache2 log file gives following error:

File "/usr/lib/python2.7/dist-packages/horizon/utils/secret_key.py", line 65, in generate_or_read_from_file
     with open(key_file, 'r') as f:
IOError: [Errno 13] Permission denied: '/var/lib/openstack-dashboard/secret_key'
[error] [client 10.0.0.70] File does not exist: /var/www/favicon.ico

I have gone through similar posts for 500 internal error but none seems to related to this scenario (i.e. permission denied). Any clue!

Full backtrace:

[Tue May 20 10:00:56 2014] [warn] mod_wsgi: Compiled for Python/2.7.2+.
[Tue May 20 10:00:56 2014] [warn] mod_wsgi: Runtime using Python/2.7.3.
[Tue May 20 10:00:56 2014] [notice] Apache/2.2.22 (Ubuntu) mod_wsgi/3.3 Python/2.7.3 configured -- resuming normal operations
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151] mod_wsgi (pid=17310): Exception occurred processing WSGI script '/usr/share/openstack-dashboard
/openstack_dashboard/wsgi/django.wsgi'.
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151] Traceback (most recent call last):
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]   File "/usr/lib/python2.7/dist-packages/django/core/handlers/wsgi.py", line 187, in __call__
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]     self.load_middleware()
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]   File "/usr/lib/python2.7/dist-packages/django/core/handlers/base.py", line 46, in load_middle
ware
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]     for middleware_path in settings.MIDDLEWARE_CLASSES:
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]   File "/usr/lib/python2.7/dist-packages/django/conf/__init__.py", line 54, in __getattr__
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]     self._setup(name)
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]   File "/usr/lib/python2.7/dist-packages/django/conf/__init__.py", line 49, in _setup
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]     self._wrapped = Settings(settings_module)
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]   File "/usr/lib/python2.7/dist-packages/django/conf/__init__.py", line 128, in __init__
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]     mod = importlib.import_module(self.SETTINGS_MODULE)
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]   File "/usr/lib/python2.7/dist-packages/django/utils/importlib.py", line 40, in import_module
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]     __import__(name)
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]   File "/usr/share/openstack-dashboard/openstack_dashboard/wsgi/../../openstack_dashboard/setti
ngs.py", line 219, in <module>
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]     from local.local_settings import *  # noqa
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]   File "/usr/share/openstack-dashboard/openstack_dashboard/wsgi/../../openstack_dashboard/local
/local_settings.py", line 93, in <module>
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]     SECRET_KEY = secret_key.generate_or_read_from_file('/var/lib/openstack-dashboard/secret_key
')
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]   File "/usr/lib/python2.7/dist-packages/horizon/utils/secret_key.py", line 65, in generate_or_
read_from_file
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151]     with open(key_file, 'r') as f:
[Tue May 20 10:01:16 2014] [error] [client 10.0.8.151] IOError: [Errno 13] Permission denied: '/var/lib/openstack-dashboard/secret_key'
[Tue May 20 10:01:18 2014] [error] [client 10.0.8.151] mod_wsgi (pid=17311): Exception occurred processing WSGI script '/usr/share/openstack-dashboard/openstack_dashboard/wsgi/django.wsgi'.
[Tue May 20 10:01:18 2014] [error] [client 10.0.8.151] Traceback (most recent call last):
[Tue May 20 10:01:18 2014] [error] [client 10.0.8.151]   File "/usr/lib/python2.7/dist-packages/django/core/handlers/wsgi.py", line 187, in __call__
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]     self.load_middleware()
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]   File "/usr/lib/python2.7/dist-packages/django/core/handlers/base.py", line 46, in load_middleware
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]     for middleware_path in settings.MIDDLEWARE_CLASSES:
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]   File "/usr/lib/python2.7/dist-packages/django/conf/__init__.py", line 54, in __getattr__
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]     self._setup(name)
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]   File "/usr/lib/python2.7/dist-packages/django/conf/__init__.py", line 49, in _setup
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]     self._wrapped = Settings(settings_module)
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]   File "/usr/lib/python2.7/dist-packages/django/conf/__init__.py", line 128, in __init__
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]     mod = importlib.import_module(self.SETTINGS_MODULE)
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]   File "/usr/lib/python2.7/dist-packages/django/utils/importlib.py", line 40, in import_module
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]     __import__(name)
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]   File "/usr/share/openstack-dashboard/openstack_dashboard/wsgi/../../openstack_dashboard/settings.py", line 219, in <module>
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]     from local.local_settings import *  # noqa
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]   File "/usr/share/openstack-dashboard/openstack_dashboard/wsgi/../../openstack_dashboard/local/local_settings.py", line 93, in <module>
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]     SECRET_KEY = secret_key.generate_or_read_from_file('/var/lib/openstack-dashboard/secret_key')
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]   File "/usr/lib/python2.7/dist-packages/horizon/utils/secret_key.py", line 65, in generate_or_read_from_file
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70]     with open(key_file, 'r') as f:
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70] IOError: [Errno 13] Permission denied: '/var/lib/openstack-dashboard/secret_key'
[Tue May 20 10:19:01 2014] [error] [client 10.0.0.70] File does not exist: /var/www/favicon.ico