I had been attempting to deploy django on the shared webhost which isn't django specific. Host offers old version of python installed, consider I've ssh access ability, I have handled to increase python installation with modules I want (including django) by setting up them in your area during my home folder. Ok, so I have produced django project, did tweaks that required to do (establishing PYTHONPATH and PATH globals etc.), made django.fcgi script which begins django and did ./django.fcgi from spend. This is actually the response:

WSGIServer: missing FastCGI param REQUEST_METHOD needed by WSGI!

WSGIServer: missing FastCGI param SERVER_Title needed by WSGI!

WSGIServer: missing FastCGI param SERVER_PORT needed by WSGI!

WSGIServer: missing FastCGI param SERVER_PROTOCOL needed by WSGI!

Traceback (newest call last):

  File "/home/tentacle/lib/python2.4/site-packages/flup-1..3.dev_20110405-py2.4.egg/flup/server/fcgi_base.py", line 574, in run

    protocolStatus, appStatus = self.server.handler(self)

  File "/home/tentacle/lib/python2.4/site-packages/flup-1..3.dev_20110405-py2.4.egg/flup/server/fcgi_base.py", line 1159, in handler

    result = self.application(environ, start_response)

  File "/home/tentacle/lib/python2.4/site-packages/django/core/handlers/wsgi.py", line 272, in __call__

    response = self.get_response(request)

  File "/home/tentacle/lib/python2.4/site-packages/django/core/handlers/base.py", line 169, in get_response

    response = self.handle_uncaught_exception(request, resolver, sys.exc_info())

  File "/home/tentacle/lib/python2.4/site-packages/django/core/handlers/base.py", line 202, in handle_uncaught_exception

    from django.sights import debug

  File "/home/tentacle/lib/python2.4/site-packages/django/sights/debug.py", line 9, in <module>

    from django.template import (Template, Context, TemplateDoesNotExist,

  File "/home/tentacle/lib/python2.4/site-packages/django/template/__init__.py", line 53, in <module>

    from django.template.base import (Permitted_VARIABLE_CHARS, BLOCK_TAG_Finish,


Status: 500 Internal Server Error

Content-Type: text/html



<title>Unhandled Exception</title>


<h1>Unhandled Exception</h1>

<p>An unhandled exception was tossed through the application.</p>


So, I am conscious that this problem is all about limited memory for my user (wrong?), but could it be so low which i cannot run bare django? Only for items to be worse, last month exactly the same provider offered me a test account, along with a managed not just in run django, but to set up in your area more recent version of python and run it nice. Used to do requested my hosting company support for help, however i did not got any functional answer. Also being that they are merchants I am not so sure just how much they assist.

It is possible to method to overcome this issue? Any suggestion is welcome.

Thanks ahead of time



import os, sys

sys.path.place(, "/home/<username>/djangoprojects")

sys.path.place(, "/home/<username>/djangoprojects/testproject")

os.environ['PATH']= "/home/<username>/bin:"+os.environ['PATH']

os.environ['DJANGO_Configurations_MODULE'] = 'testproject.settings'

from django.core.servers.fastcgi import runfastcgi

runfastcgi(method="threaded", daemonize="false")

This is the way seem like my configuration. I have to admit that there is just a little error (interpreter path), but 'settings' file path was good.

After fixing the interpreter road to correct one, First I have got StringError (some triple cited doc string in a single of djangos files wasn't closed - hm, hardly), compared to next run MemoryError, and again MemoryError and so forth. Before long (an hour or so) I attempted to complete script again (no further changes made) and constantly winding up with Segmentation fault (core left).

Any suggestions?

When running it in the command line, you have to specify the Django parameters clearly. Presuming you're running the script in the same folder as the configurations.py is within:

import os, sys


os.environ['DJANGO_Configurations_MODULE'] = 'settings'

# ... relaxation of the startup script...

Also, see if your .htaccess file continues to have a proper RewriteRule for your .fcgi script.