[mod_python] libapache2-mod-python error

Richard Lewis richardlewis at fastmail.co.uk
Tue Aug 21 11:50:40 EDT 2007

On Tuesday 21 August 2007 16:27:36 Tomasz Woźniak wrote:
> I tried to install apache with mod_python in the Ubuntu.

I use mod_python in Debian "unstable"

> The last one were: 
> sudo aptitude install python
> sudo aptitude install libapache2-mod-python
> sudo gedit /etc/apache2/mods-available/mod_python.conf
>   AddType application/x-httpd-python .py
>   AddHandler mod_python .py
>   PythonHandler mod_python.publisher
>   PythonDebug On
> cd /etc/apache2/mods-enabled
> sudo ln -s ../mods-available/mod_python.conf mod_python.conf
> sudo /etc/init.d/apache2 restart

Hmm. In Debian there is no mod_python.conf, just mod_python.load. 
This contains one line:

LoadModule python_module /usr/lib/apache2/modules/mod_python.so

> But I had libapache2-mod-python error, and i have it whatever I
> try to install...
Are you sure Apache is running? Will it serve a plain HTML page 
correctly? Try:

$ sudo netstat -n -t -l

and make sure there is a service running on port 80:

tcp6     0    0 :::80          :::*         LISTEN

So, what exactly goes wrong? Have you tried a test script? Try 
following the instructions here:



Then ask this again if it still doesn't work.

Richard Lewis
JID: ironchicken at jabber.earth.li

More information about the Mod_python mailing list