I recently updated a development server running CentOS and ran into various minor issues including one regarding postfix being compiled with MySQL support. The development server runs ISPConfig for various virtual hosts and after upgrading all the packages on the server which included Postfix I noticed errors in the maillog. Below I describe what the error was in more detail as well as how it can easily be resolved.
Another error I ran into while attempting to build PHP via the Litespeed Admin Console. This error directly related to the MySQL libraries or the MySQL version. Below is more information on the error itself and how the error was resolved. This error was resolved by simply installing a couple MySQL packages via the yum package manager as shown below.
The below is part of the output when receiving an error attempting to install the Perl DBD::mysql module using the CPAN shell. I rarely use the Perl CPAN shell since most of the packages are available on CentOS, my typical Linux distribution choice for servers, using the yum package manager. In this case I was working on installing Monarch on a server at work to assist with Nagios file management. Monarch allows you to backup the entire Nagios configuration files with the click of a button. Monarch will also provide a visual view of any Nagios build errors, Nagios configuration files (including users, user groups, services, check commands, etc.,), and more. So when attempting to build the Perl DBD:mysql module via the CPAN shell I received some errors which I initially did not understand because they did not explain the specific issue however I eventually located the problem which ended up being easy to resolve. Below I describe the error in detail as well as information on how to resolve.
Another error during an attempt to compile PHP via the Litespeed web admin console dealt with MySQL library versions. I had MySQL installed and operational on the server so I wasn’t immediately sure what the issue was. Error:configure: error: wrong mysql library version or lib not found. Check config.log for more information. After looking further…
I received the below error when attempting to compile PHP to use with Litespeed as an LSAPI module. The error was related to multiple versions of numerous MySQL RPM packages being installed.
PHP Compile Error:
checking for MySQL support… yes
checking for specified location of the MySQL UNIX socket… no
checking for MySQL UNIX socket location… /var/lib/mysql/mysql.sock
checking for mysql_close in -lmysqlclient… no
checking for mysql_errno in -lmysqlclient… no
The PHP configure script was getting confused because of two 32-bit MySQL RPM packages being installed. If you look below this is the MySQL packages yum was showing installed on the server.