[mod_python] mod_python import failure on FreeBSD AMD64

Surly The Clown surly_the_clown at hotmail.com
Tue May 4 23:13:51 EDT 2010


> It isn't actively developed any more and if all you want to do is host
> a web application, and not hook into Apache request phases, you are
> better off using WSGI capable Python web frameworks and hosting using
> mod_wsgi or fastcgi/flup.


Unfortunately, I do need to hook into Apache request phases...


> 
> > I tried setting PythonOption mod_python.mutex_locks 4, and the problem
> > persisted. I then tried increasing the number of available semaphores in the
> > kernel from the default 10 (!) to 256, verified that that setting had
> > changed, and then tried again. The problem still persists. Furthermore, four
> > files that appear to be the mutexes exist in /tmp,
> 
> The sem_init() call is I believe a kernel thing, not a filesystem type of lock.
> 
> Such kernel setting changes usually only take affect after a system
> reboot. Did you do that?


Sure did.


> 
> > named mpmtx15570 to
> > mpmtx15573. Perhaps mod_python isn't using kernel semaphores? Its
> > documentation says that it doesn't always. And /tmp isn't out of space (no
> > partition is).
> 
> What is used depends on what Apache/APR sets up as default type of
> semaphore. It prefers certain types and what is available depends on
> the operating system.


I might have to dig into that to see where the sem_init message is coming from.


> 
> > Any more ideas?
> 
> Don't use mod_python if you don't have to.
> 
> What are you wanting to host using it?


Big(ish) media files, and I'm wanting to hook into Apache so that I can control access to them with custom logic. As far as I've been able to determine, this is something that wsgi/fastcgi can't really do, unless you use URL rewriting to force the requests to go through a script. Even then, it's suboptimal as the file would then be piped through a script instead of handled directly by Apache. mod_python was pretty much exactly what I need.


Thank you for your attempts to help, at any rate.


 		 	   		  
_________________________________________________________________
Win a $10,000 shopping spree from Hotmail! Enter now.
http://go.microsoft.com/?linkid=9729711
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mm_cfg_has_not_been_edited_to_set_host_domains/pipermail/mod_python/attachments/20100504/d517f851/attachment.html


More information about the Mod_python mailing list