Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I'm using Ubuntu 12.04 and trying to configure my Apache server with Django. I tried a couple of different online tutorials and keep on getting errors. This is my latest error when I try to start my server:

 * Starting web server apache2  
     apache2: Syntax error on line 214 of /etc/apache2/apache2.conf:
     Syntax error on line 2 of /etc/apache2/httpd.conf: 
     Cannot load /etc/apache2/modules/ into server: 
     cannot open shared object file: No such file or directory
Action 'start' failed.
The Apache error log may have more information.

Any help would be appreciated.

share|improve this question
up vote 4 down vote accepted

Make sure libapache2-mod-wsgi is installed, and that it is enabled:

sudo apt-get install libapache2-mod-wsgi
sudo a2enmod wsgi

If you're using Python3 you might need libapache2-mod-wsgi-py3 instead. They can't both be installed at the same time but they both use the same a2enmod command to enable in Apache.

share|improve this answer
Thanks @Dan, I'll alter the muttering at the end of the answer. – Oli Jun 18 '14 at 16:09

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.