MySQL upgrade to 5.6 and outdated mysqlnd

#1
We recently upgraded some of ours servers to MySQL 5.6 but this caused some issues on some client's sites, on the server running CloudLinux. We contacted our server administrators believe this is due to LiteSpeed's version of mysqlnd, which doesn't change, no matter what version of lsphp is used.

For example, when cpanel updates PHP it sets the extension as:


Client API version => 5.6.16
Client API library version => 5.6.16
Client API header version => 5.6.16
But when litespeed updates the extension, it leaves it at a MySQL 5.0 compatible version:

Client API library version => mysqlnd 5.0.11-dev - 20120503
Client API version => mysqlnd 5.0.11-dev - 20120503
 

mistwang

LiteSpeed Staff
#2
Build Matching PHP will update default lsphp5 binary after you run easyApache.
If you use PHP selector, the binary is from RPM provided by CloudLinux. you need to contact CloudLinux about that.
 

mistwang

LiteSpeed Staff
#3
upgraded our cPanel test server to MySQL 5.6, then build matching PHP, the default lsphp5 binary has been updated to using MySQL 5.6.15 Client API.
CloudLinux also has alt-php RPM for MySQL 5.6.
The PHP binary compiled with cPanel easyApache does not use mysqlnd, The matching lsphp5 does not use mysqlnd either.
So, I am not sure how mysqlnd was enabled? the PHP binary built through LiteSpeed WebAdmin console? For cPanel, we do not recommend that, just build matching PHP feature. If you need to support multiple version of PHP, should customize the lsphp configurations closely match cPanel's.
 
#4
Thanks for your time and reply.

Just to confirm, we have other CloudLinux servers and this is only happening at our server with Litespeed installed. We also requested confirmation with them, they said they have nothing to do with native PHP version, where the error appears.

We haven't specifically enabled mysqlnd, so I'll run the Build Matching LSPHP and post results here to see if that did the trick.
 
#5
We are also seeing a mismatch in headers after the update to MySQL 5.6, 5.5.32 vs 5.6.16 specifically. Did the mysqlnd resolve the problem? If so was that done through the rawopts config file? Thanks.
 

mistwang

LiteSpeed Staff
#8
You need to run easyApache first to let cPanel update header/library, then build matching PHP.
If you are not using cPanel, you need to manually update mysql header file to match the lib. then build PHP.
If you build php from Admin console, you need to make sure the updated header files are used.
 
#9
We did run easyApache beforehand, this attempt was forcing Litespeed to rebuild which didn't have any affect because it already should have been in sync. We are also running Cloudlinux.
 
#10
This was the response from cPanel support FYI:

Your webserver is lightspeed, which is unsupported. We cannot guarantee that EasyApache can build a working configuration in that environment. Have you tried this with lightspeed removed/disabled, and Apache as the webserver? The use of lightspeed uses a copy of the php binary(evident in EasyApache build log), which may not be getting used due to cagefs not recognizing the new file. To ensure PHP is being built properly and the new settings recognized by the intended webserver, please disable and remove lightspeed from the configuration. Then we can look into the operation of PHP in more depth.
 

mistwang

LiteSpeed Staff
#11
check output of /usr/local/lsws/fcgi-bin/lsphp5 -i
see if it the mysql header/lib is updated and match.
If it is different to the phpinfo() page you got under a user account, you need to update the CageFS template to use the new lsphp5 binary, the old one is still used in the cage. Assuming the default PHP is selected for this user account in PHP selector.
 
Top