In the newest release of Ubuntu, 16.04, we have finally upgraded from PHP5 to PHP7. But when the upgrade happens, it’s possible that the MySQLi plugin does not get upgraded. If you recently upgraded from a previous version of Ubuntu to Ubuntu 16.04, try reinstalling the plugin from scratch using the below commands.
First, make sure your software sources are up to date:
sudo apt-get update
Completely remove the MySQL Plugin:
sudo apt-get --purge purge php-mysql
Reinstall the MySQL Plugin:
sudo apt-get install php-mysql