Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sayeed-ahmed-rasel/a00e13384de63f7910cd0e6465d7dbe6 to your computer and use it in GitHub Desktop.
Save sayeed-ahmed-rasel/a00e13384de63f7910cd0e6465d7dbe6 to your computer and use it in GitHub Desktop.
solve For error: pdoexception could not find driver
At this stage I would simply recommend "turning it off and on again" by doing:
====" sudo apt-get purge php-common php5-common "====
followed by
====" sudo rm -r /etc/php"====
And then reinstalling PHP 7.0 and mysql modules:
====" sudo apt-get install libapache2-mod-php php-mysql "====
You may also try just purging and reinstalling mysql modules, first removing the package:
====" sudo apt-get purge php7.0-mysql "====
And the installing them again:
====" sudo apt-get install php-mysql "====
In both cases it's important to use apt-get purge instead of apt-get remove to delete any existing configuration files and package states.
The least destructive way would be trying to re-enable mysql modules using phpenmod command:
====" sudo phpenmod mysqlnd pdo_mysql "===
It's hard to give you correct advice if we don't know what mayhem you created on your system.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment