[TriLUG] Apache2 / PHP / MySQL Help?

Brian McCullough bdmc at bdmcc-us.com
Tue Mar 25 10:27:51 EDT 2008


On Mon, Mar 24, 2008 at 08:13:34PM -0400, Mats Rynge wrote:
> Brian McCullough wrote:
> > Help!
> > 
> > 
> > I am working on a Debian Sarge system with Apache 2 ( 2.0.54 ) and PHP4
> > installed.  PHPInfo works correctly, but I can't seem to get the MySQL
> > module recognized.  I have put the path to the .so file into the php.ini
> > file, and that path is shown in the PHPInfo output, but MySQL is not
> > shown as a loaded module in the PHPInfo output.
> 
> Not sure what you mean with the path, but on sarge systems you probably
> need:
> 
> extension=mysql.so
> 
> in your /etc/php4/apache2/php.ini file.


OK.  I thought that I would try something.  I did the following:

I commented out the "extension_dir" directive in php.ini.
I commented out the "extension=mysql.so" directive in php.ini.
There are no other "extension=" directives active in php.ini.
I did: apt-get install php4-gd.  This was successful.
I examined /usr/lib/php4/20020429.  It contains gd.so and mysql.so.
I did not restart Apache.
I ran phpinfo().
The extension_dir in the phpinfo report shows as /usr/lib/php4/20020429.
GD now appears in the active extensions list.  MySQL does not.

I'm leaning toward a "strange" MySQL installation, although I don't
really believe that.  Shouldn't the MySQL extension show up in phpinfo()
even if it doesn't have a database engine to talk to?


Very confused.

Brian





More information about the TriLUG mailing list