When I try to log in it says Cannot log in to the MySQL with the error (HY000/2002)
After I upgraded my server from 18.04 to 20.04 I can't log in anymore so anyone can help ?
1 Answer
If phpMyAdmin is running on the same server as the database, you'll want to update your config.inc.php file, replacing localhost with 127.0.0.1. The result should look something like this:
$cfg['Servers'][$i]['host'] = '127.0.0.1';By default, phpMyAdmin will try to connect to the mysql.socket connection when you use localhost. When you use 127.0.0.1 it will make a TCP connection, which should resolve the issue.