Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
I have a machine, a old one with old mysql-4.1.14-standard for 32bit which is running a monitoring tool like cacti. The mysql was a binary one.
I also have php and apache running; where PHP was compiled with the option --with-mysql=/usr/local/mysql and phpinfo page shows the mysql verison 4.1.14 standard in MySQL section.
So far so good.
Now, I download MySQL 5.1.30 source file and compiled it in /usr/test/mysql. Now after running `make` and `make install` I dumped the databases of previous mysql in the new datadir of new mysql & when I run the new mysql server after stopping the old one its surprisingly working. That is the apache is serving pages which Connects to mysql. But the Phpinfo page is still showing the old mysql version.
Both the new and old mysql are using /tmp/mysql.sock file; is that the issue otherwise as PHP was compiled with the mysql location which is not running how come its connecting to mysql!
I even renamed the /usr/local/mysql folder to other name but still it works.
No, I haven't as I know if I recompile with new mysql location then the phpinfo page will show the new mysql version definite.
But what I am asking is right now how come PHP is communicating with new mysql in a different location not compiled with in php.
I think that might be because the PHP / MySQL communications mechanism uses a standard location. I. e. whatever MySQL version is active works with port 3306 on localhost - so two MySQL versions can exist, one running, and responding to commands from PHP, even while PHP itself "thinks" it is talking to the inactive (not running) one...
I also think so and most probably the file responsible for this is mysql.sock which default location is /tmp.
And in my case both the old and new versions of mysql uses that same file as per my my.cnf settings.
Anyway I finally recompiled the PHP with new mysql compiled location and now its showing the latest mysql client API version as we all assumed.