User Tools

Site Tools


python:makeobcallback

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

python:makeobcallback [2013/03/16 17:40] (current)
Line 1: Line 1:
 +==== ERROR: make_obcallback:​ could not import mod_python.apache ====
 +resolving a headache error
  
 +**TAGS: python_handler:​ Can't get/create interpreter. / no interpreter callback found. / **
 +
 +Installing mod_python under apache could be simple, but all over the forums there are problems related to the well known messages:
 +
 +<​code>​
 +make_obcallback:​ could not import mod_python.apache.\n
 +ImportError:​ No module named apache
 +[Sun Dec 07 20:50:18 2008] [error] make_obcallback:​ Python path being used
 +"​['/​usr/​lib/​python2.5/​site-packages/​MySQL_python-1.2.2-py2.5-linux-i686.egg', ​
 +'/​usr/​lib/​python2.5/​site-packages/​ipython-0.8.1-py2.5.egg', ​
 +'/​usr/​lib/​python2.5/​site-packages/​Dabo-0.8.3-py2.5.egg'​
 +[...]
 +".
 +[Sun Dec 07 20:50:18 2008] [error] get_interpreter:​ no interpreter callback found.
 +[Sun Dec 07 20:50:18 2008] [error] [client 127.0.0.1] python_handler:​ Can't get/create interpreter.
 +</​code>​
 +
 +
 +Assuming you have installed correctly the mod_python (regarding the python version, etc), you must do the following: check the permissions for mod_python folder under /​usr/​lib/​python2.5 (or wherever you installed it)
 +
 +<​code>​
 +ls -l /​usr/​lib/​python2.5/​site-packages/​ | grep mod_python
 +</​code>​
 +
 +
 +To make it available to user under the webserver is running (e.g. apache), run these simple commands:
 +
 +<​code>​
 +chmod 777 /​usr/​lib/​python2.5/​site-packages/​mod_python
 +chmod 666 /​usr/​lib/​python2.5/​site-packages/​mod_python/​*
 +</​code>​
 +
 +Restart the apache and here you go!
 +
 +References:
 +[[http://​www.modpython.org/​FAQ/​faqw.py?​query=restarted&​req=search | Modpython FAQ]]
python/makeobcallback.txt ยท Last modified: 2013/03/16 17:40 (external edit)