[mod_python] mod_python + MySQLdb => does it work?

Tom Emerson tree at basistech.com
Thu Jul 19 07:37:26 EST 2001


markus.hillebrand at apis-group.net writes:
> I tried to bring mod_python and MySQLdb together,
> but I crashed on some problems.

This works very well.

> First of all: mod_python runs quite fine.
> Also MySQLdb runs quite well.
> 
> But when I try to import MySQLdb from a python-script
> that was invoked by mod_python I get a
> 
> ImportError: _mysql: init failed 
> (whole error message is in the attachement)

Check your Python load path within mod_python, and make sure that the
directory containing the MySQLdb modules is there. Also make sure that
the MySQLdb shared object can be found in the library search path.


-- 
Tom Emerson                                          Basis Technology Corp.
Sr. Sinostringologist                              http://www.basistech.com
  "Beware the lollipop of mediocrity: lick it once and you suck forever"



More information about the Mod_python mailing list