[mod_python] mod_wsgi (pid=88536): Unable to change working directory

Graham Dumpleton graham.dumpleton at gmail.com
Tue Jan 12 18:21:43 EST 2010

2010/1/13 mog <lists at elasticmind.net>:
> On 12/01/2010 22:55, Graham Dumpleton wrote:
>> By rights it perhaps shouldn't be an alert but a warning. You can ignore
>> it.
>> It occurs because in daemon mode mod_wsgi will change working
>> directory to the home directory of the user that the daemon process
>> runs as. On your system, the default Apache user doesn't have a home
>> directory and so the message. It will not stop anything from working.
>> If you really want to get rid of it, then override home as you have
>> done, setting it to '/tmp' even. Alternatively, create a dedicated
>> user, or use another existing user account that does have a home
>> directory, specifying the user/group options to WSGIDaemonProcess so
>> that the daemon process runs as that user and not the default Apache
>> user.
> Ahh right, that totally makes sense. Thanks.
>> Are you still loading mod_python into same Apache?
>> You likely have a conflicting version of mod_python loaded which is
>> causing problems. Disable mod_python and try again.
> I removed the mod_python port and installed mod_wsgi-3.1 last night. There
> really shouldn't be any remnants of mod_python lurking around; but even if
> there are, I removed the mod_python LoadModule directive from httpd.conf and
> have stopped and restarted Apache numerous times - so it really should be
> gone.

Just the LoadModule line for mod_python is enough to cause the
problem. This is because it is still loaded even if not used.

Also make sure you did a complete 'stop' of Apache and not just a
Linux init reload, as sometimes mod_python doesn't unload properly the
Python library.

If still a problem, you perhaps have SELinux extensions enabled and it
should be disabled or properly configured.


>> Please use mod_wsgi list in future as I already pointed out.
> Oooops sorry, I don't remember any mention of that but I really should have
> thought to switch myself. I'll get myself subscribed to the mod_wsgi list
> pronto.
> Thanks again everyone!
> _______________________________________________
> Mod_python mailing list
> Mod_python at modpython.org
> http://mailman.modpython.org/mailman/listinfo/mod_python

More information about the Mod_python mailing list