Page 1 of 1
Which is the appropriate forum
Posted: Sun Jul 16, 2006 8:50 pm
by griffinmt
I have a Fedora Linux system with Apache (2.0.51), MySql (4.0.21) and PHP (4.3.11)
The problem is that PHP is not built with the correct MySql support (EG: mysql_connect() etc cannot be found).
I don't have the source kits for any of these, but do have PHP 4.3.4 source kit.
I want to add the php support for mysql, but don't really know where to start and
want to make any disruption to the system as minimal as possible for now.
It seems that the products were installed in some unusual way (locations) as part of the original build and
continued maintenance, and I frankly get lost trying to navigate through the stuff and directory layouts.
Can someone help educate me and make me a little more dangerous

Posted: Sun Jul 16, 2006 8:55 pm
by Benjamin
You pretty much just need to recompile php with MySQL support.
If it already is, which you can check with:
then the module isn't being loaded.
Here are some tutorials that might help you...
http://www.mjmwired.net/resources/mjm-fedora-php4.html
http://www.hostlibrary.com/installing_a ... p_on_linux
Posted: Mon Jul 17, 2006 3:06 pm
by griffinmt
After checking the links that you provided, I decided to 'byte the bullet' and upgrade the whole system.
So a migrated the current website onto a different WXP system and got it up and running for the users. It is a bit sluggish, but ok for a few days.
The original system was still on version 1 of Fedora. I downloaded and built the 6 CDs for V5, and am in the process of doing a clean build on reformatted disks. Once I have all the needed parts running and the associated config files adjusted, I will slide the site back and proceed. Not the way I wanted to spend the next few days, but it was needed sooner or later!
Thanks,
Posted: Mon Jul 17, 2006 3:27 pm
by RobertGonzalez
Bear in mind that PHP does not come with mysql support by default anymore (I belive as of PHP5). I think now it is the mysqli faimly of functions. So even upgrading the entire system does not ensure that you will have access to mysql. You may still need to set that extension up yourself.
Posted: Mon Jul 17, 2006 3:32 pm
by daedalus__
PHP5 does not include the mysql library of functions.
Posted: Mon Jul 17, 2006 5:14 pm
by griffinmt
So, it looks like I am still in need of adding the PHP-MySql marriage, but at least with an up to date environment.
Once all the updates have finished their application and I have the rest of the Apache/MySql/PHP etc setup done, I will come back and try to sort this out.
Thanks,
Posted: Mon Jul 17, 2006 5:33 pm
by RobertGonzalez
Good luck, and keep us posted
Posted: Wed Jul 19, 2006 5:27 pm
by griffinmt
Ok, all the updates have been applied and ready (I think

) to proceed. Of course, right in the middle of all this, on Monday night, a storm came our way and I was lucky enough to be one of the 200,000 Michigan residents that lost power, right in the middle of applying the updates. It took about 19 hours, but we finally got power back. It took another 24 hrs to get the network connection running!
Anyway, just what do I need to do to get the correct module to enable MySql (v5.0.22) from PHP (v5)?
Be gentle, this (approach) is all foreign to me
Thanks,
Posted: Wed Jul 19, 2006 5:59 pm
by RobertGonzalez
You can have mysql_* and mysqli_* functions enabled at the same time. Just uncomment their extension lines in php.ini.
Posted: Wed Jul 19, 2006 6:17 pm
by griffinmt
Thanks!
Ok, that was straight forward enough (and I guess I already new the answer but wanted confirmation

).
Now for the awkward part. Getting Apache V2.2 to interact with PHP V5.
I don't want (need) any CGI capability, and I alread have the http.conf set to handle php extensions and look for index.php etc
What i really need is the module referenced by the 'correct' LoadModule command, and where that module comes from, or how do I have to build it.

Posted: Wed Jul 19, 2006 11:31 pm
by griffinmt
It would seem that I have been searching for the wrong module. After some more digging, I found that the correct name is libphp5.so
This I have and now I have it all working (barring any unforseen items I may have forgotten

)
Thanks for your patience.
Posted: Thu Jul 20, 2006 1:02 am
by RobertGonzalez
Congrats.