LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 12-06-2006, 10:16 AM   #1
tobiasw
Member
 
Registered: Oct 2006
Distribution: Fedora Core
Posts: 60

Rep: Reputation: 15
MySQL wont work together with PHP


Hello,

I am trying to connect to a remote MySQL server over PHP on RedHat Linux Server. I get the message "PHP Fatal Error: Call to undefined Function: mysql_connect()... powered by PHP4.3.9

I included in php.ini - "Dynamic Extension" the entry with mysql.so. - Then I get the error message dynamic library unable to load /usr/lib/php/mysql.so
(Directory is empty..)
I can connect directly with mysql without problems.

What I need to do to manual install the php connection to mysql, without reinstalling anything?


Thanks

Tobias
 
Old 12-06-2006, 12:08 PM   #2
derxob
Member
 
Registered: Apr 2006
Location: Los Angeles, California
Distribution: Slackware, Ubuntu
Posts: 68

Rep: Reputation: 16
Verify that the path to mysql.so is actually /usr/lib/php/ as it may vary from system to system depending on the install.

Example, mysql.so is located in /usr/lib/php/extensions/ on one of my servers.

Hope this helps.
 
Old 12-06-2006, 12:57 PM   #3
tobiasw
Member
 
Registered: Oct 2006
Distribution: Fedora Core
Posts: 60

Original Poster
Rep: Reputation: 15
Thanks,

but I cannot find mysql.so on the system "find / ..." . How can I include it to the system, or what are the necessary steps to make it running?

Tobias
 
Old 12-07-2006, 11:44 AM   #4
AlbinoJap
Member
 
Registered: Mar 2004
Posts: 36

Rep: Reputation: 15
You said that your are running PHP 4.3.9 so I am guessing that it is a RHEL4 server. You shouldn't have to update the PHP configuration with the MySQL extension. Sounds like you don't have MySQL support for PHP installed. Check to see if you have the 'php-mysql' RPM installed.

rpm -qa | grep php-mysql

If not, install it with up2date.

up2date php-mysql

Then restart Apache and you should be good to go.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Php and Mysql wont play together Slith(++1) Mandriva 6 10-03-2005 09:53 PM
PHP 5 wont connect to MySql (fedora spacy2003 Linux - Software 0 02-07-2005 08:31 AM
php 438 and mysql 41 fedora 2 wont talk phoebebright Linux - Software 0 11-02-2004 03:49 PM
Apache Mysql Php: mysql with php doesn't work breakerfall Linux - Networking 6 12-27-2003 08:59 PM
mysql just wont work nocturnal Linux - Software 13 07-10-2003 08:02 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 11:44 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration