[mod_python] problem setting up mod_python under Ubuntu Breezy

Troy Kruthoff tkruthoff at gmail.com
Thu Mar 2 16:26:19 EST 2006


Try using the --with-python option when you configure mod_python,
and/or veryify the references to python in your path point to the
appropriate python installation.

Troy



On 3/2/06, Dan Lenski <dlenski at gmail.com> wrote:
> Hi all,
> I'm having trouble getting mod_python to work under Ubuntu Breezy.
> I'm using Apache 1.3.33 with mod_python 2.7.10, Python 2.4.1a0, all
> the default packages for the distribution basically.
>
> I'm having the "could not import module mod_python.apache" problem,
> which appears to be quite a classic :-)  I'm following along with
> Graham Dumpleton's "Getting mod_python Working" guide, and created a
> little mptest.py script.  When I try to load the mptest.py script, I
> get a 500 error from Apache, and the following in my error log:
>
> make_obcallback(): could not import mod_python.apache.
> make_obcallback(): could not call init.
> [Thu Mar  2 14:55:22 2006] [error] [client 129.2.43.114] python_handler: make_ob
> callback returned no obCallBack!
>
> Note that these DO NOT occur when Apache starts up!!  They don't occur
> until I try to load the offending page.  My httpd.conf includes the
> lines:
>
>   <Directory /var/www/python>
>     AddHandler python-program .py
>     PythonHandler mptest
>     PythonDebug On
>   </Directory>
>
> Does anyone have any advice?  I have python 2.4 installed on my system
> (not 2.2, 2.3, or anything else).  So I think it's not the problem
> described here:
>    http://www.modpython.org/FAQ/faqw.py?req=show&file=faq02.001.htp
> I've tried starting Apache in single-process mode with
> PYTHONHOME="/usr", since all the python modules are stored under
> /usr/lib/python2.4/
>
> All to no avail.  I'm completely stumped.  I've read a pretty good
> chunk of the FAQ, and googled lots of other threads on similar topics.
>  Any hints?  Thanks,
>
> Dan Lenski
> (Physics grad student at U of Maryland)
>
> _______________________________________________
> 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