Forum archive
500 Internal Server Error - Django appliance
I just installed the Django appliance using all the default settings. Upon complete installation I try to access the sample Django site, but get "500 Internal Server Error".
I then try to upload a simple, static HTML file to the /var/www folder, but get the same error.
While I am technically skilled, I have little/no experience with Linux and web-development in general - just getting started - so I need "babysteps assistance".
I browsed the forums, found others had similar problems, but found no solutions....
Kind regards,
Morten F. Thomsen
Norway
excerpt from apache log:
[Mon Feb 27 10:08:08 2012] [error] Exception KeyError: KeyError(-1220257136,) in <module 'threading' from '/usr/lib/python2.6/threading.pyc'> ignored [Mon Feb 27 10:08:08 2012] [error] Exception KeyError: KeyError(-1220257136,) in <module 'threading' from '/usr/lib/python2.6/threading.pyc'> ignored [Mon Feb 27 10:08:09 2012] [notice] caught SIGTERM, shutting down [Mon Feb 27 10:08:09 2012] [error] Exception KeyError: KeyError(-1220257136,) in <module 'threading' from '/usr/lib/python2.6/threading.pyc'> ignored [Mon Feb 27 10:08:24 2012] [warn] RSA server certificate is a CA certificate (BasicConstraints: CA == TRUE !?) [Mon Feb 27 10:08:24 2012] [warn] RSA server certificate is a CA certificate (BasicConstraints: CA == TRUE !?) [Mon Feb 27 10:08:24 2012] [notice] Apache/2.2.14 (Ubuntu) mod_ssl/2.2.14 OpenSSL/0.9.8k mod_wsgi/2.8 Python/2.6.5 configured -- resuming normal operations [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] mod_wsgi (pid=2861): Exception occurred processing WSGI script '/var/www/project/wsgi_handler.py'. [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] Traceback (most recent call last): [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] File "/usr/lib/pymodules/python2.6/django/core/handlers/wsgi.py", line 241, in __call__ [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] response = self.get_response(request) [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] File "/usr/lib/pymodules/python2.6/django/core/handlers/base.py", line 122, in get_response [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] return self.handle_uncaught_exception(request, resolver, sys.exc_info()) [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] File "/usr/lib/pymodules/python2.6/django/core/handlers/base.py", line 166, in handle_uncaught_exception [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] return callback(request, **param_dict) [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] File "/usr/lib/pymodules/python2.6/django/views/defaults.py", line 23, in server_error [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] t = loader.get_template(template_name) # You need to create a 500.html template. [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] File "/usr/lib/pymodules/python2.6/django/template/loader.py", line 81, in get_template [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] source, origin = find_template_source(template_name) [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] File "/usr/lib/pymodules/python2.6/django/template/loader.py", line 74, in find_template_source [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] raise TemplateDoesNotExist, name [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] TemplateDoesNotExist: 500.html [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] mod_wsgi (pid=2861): Exception occurred processing WSGI script '/var/www/project/wsgi_handler.py'. [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] Traceback (most recent call last): [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] File "/usr/lib/pymodules/python2.6/django/core/handlers/wsgi.py", line 241, in __call__ [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] response = self.get_response(request) [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] File "/usr/lib/pymodules/python2.6/django/core/handlers/base.py", line 122, in get_response [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] return self.handle_uncaught_exception(request, resolver, sys.exc_info()) [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] File "/usr/lib/pymodules/python2.6/django/core/handlers/base.py", line 166, in handle_uncaught_exception [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] return callback(request, **param_dict) [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] File "/usr/lib/pymodules/python2.6/django/views/defaults.py", line 23, in server_error [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] t = loader.get_template(template_name) # You need to create a 500.html template. [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] File "/usr/lib/pymodules/python2.6/django/template/loader.py", line 81, in get_template [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] source, origin = find_template_source(template_name) [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] File "/usr/lib/pymodules/python2.6/django/template/loader.py", line 74, in find_template_source [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] raise TemplateDoesNotExist, name [Mon Feb 27 10:08:46 2012] [error] [client 192.168.0.103] TemplateDoesNotExist: 500.html
I get the same error code with the lamp module.
I have found it to be the .htaccess file.
I believe you will have one in your WWW directory. If so, cripple the extension and test.
This is as much as I can help you at the moment, but if this is the case and I find a solution, I will write again.
Regards