Mysql and php keeps recompiling on ./build update_versions

Richard G

Verified User
Joined
Jul 6, 2008
Messages
14,199
Location
Maastricht
Just a strange problem we encounter on a Centos 5 VPS 64-bit.

On doing a ./build update_versions, every time mysql and php are going to recompile.
./build update_versions
Updating MySQL.
Dumping database da_roundcube
Dumping database mysql
Cannot find libaio.so.1. Please install libaio
yum install libaio
Updating PHP5 (CLI)
File already exists: php-5.3.17.tar.gz
etc.etc.

However, we already did a yum install libaio and it's installed.

# locate libaio
/usr/lib64/libaio.so.1
/usr/lib64/libaio.so.1.0.0
/usr/lib64/libaio.so.1.0.1
/usr/share/doc/libaio-0.3.106
/usr/share/doc/libaio-0.3.106/COPYING
/usr/share/doc/libaio-0.3.106/TODO

We asked our host for a solution but we would like to help and also we are interested ourselves in what can be causing this problem.

Anybody a clue?
 
Zojuist gedaan, zelfde melding blijft.
Cannot find libaio.so.1. Please install libaio
Terwijl via locate te zien is dat ie wel aanwezig is. En dan begint de recompile van mysql en php weer.
 
I thought fixed it, but unfortunately.
The host had put mysql 5.5 in the options.conf however on the initial DA setup a mysql 5.1 installation was done.
Since it said 5.5 in the options.conf ofcourse the ./build update_versions command kept trying to update to 5.5.

This update is skipped every time because libaio.so.1 can not be found.

There was a post on the DA forums to do this:
Code:
ln -s /lib64/libaio.so.1 /usr/lib/libaio.so.1
But I just installed the i386 package of libaio (yum install libaio.i386) and that worked too.
Problem solved i thought.

Mysql upgrade went fine, then this problem occured when php should be rebuilded:
/usr/local/bin/php: error while loading shared libraries: libmysqlclient.so.16: cannot open shared object file: No such file or directory

Seems like a problem with Centos 5.x 64bit.
http://help.directadmin.com/item.php?id=236 did not fix the problem.

I also tried to install perl-DBD-MySQL but then we get this:
--> Running transaction check
---> Package perl-DBD-MySQL.x86_64 0:3.0007-2.el5 set to be updated
--> Processing Dependency: libmysqlclient.so.15(libmysqlclient_15)(64bit) for package: perl-DBD-MySQL
--> Processing Dependency: libmysqlclient.so.15()(64bit) for package: perl-DBD-MySQL
--> Finished Dependency Resolution
perl-DBD-MySQL-3.0007-2.el5.x86_64 from base has depsolving problems
--> Missing Dependency: libmysqlclient.so.15()(64bit) is needed by package perl-DBD-MySQL-3.0007-2.el5.x86_64 (base)
perl-DBD-MySQL-3.0007-2.el5.x86_64 from base has depsolving problems
--> Missing Dependency: libmysqlclient.so.15(libmysqlclient_15)(64bit) is needed by package perl-DBD-MySQL-3.0007-2.el5.x86_64 (base)
Error: Missing Dependency: libmysqlclient.so.15(libmysqlclient_15)(64bit) is needed by package perl-DBD-MySQL-3.0007-2.el5.x86_64 (base)
Error: Missing Dependency: libmysqlclient.so.15()(64bit) is needed by package perl-DBD-MySQL-3.0007-2.el5.x86_64 (base)
You could try using --skip-broken to work around the problem
You could try running: package-cleanup --problems
package-cleanup --dupes
rpm -Va --nofiles --nodigest

So there is still a real problem.
 
Last edited:
That's odd.
I just went on and did manually a
Code:
./build php n
And php recompiled fine, after that I don't see the libmysql.so.16 error anymore.

Would it be fixed now?

I'm still having the problem with the installation of perl-DBD-MySQL though.
 
Hello,

Recompiling php is correct, as it's linked against MySQL.
When a new version of MySQL is installed, a different libmysqlclient.so.* file is used, so recompiling php is needed so that the new php binaries can find it.
It's likely fine now.

For perl-DBD-MySQL, the same idea is needed.
Since the perl-DBD-MySQL rpm is a static binary, you either need to compile a new DBD MySQL binary, or figure out where the binary is linking to, and create symbolic link to the new version, or just add an old libmysqlclient.so.* library to where it's looking.

However, I recommend you to the first and recompile DBD-MySQL from source, so that everything is synced up correctly.

John
 
Thanks for the support.

I now did the first, compiled a new DBD MySQL binary as written in the link you gave me.
Am I correct that after building from source I must not use the "yum install perl-DBD-MySQL" anymore?
 
Back
Top