• Hi,
    I installed LAMP but get the browser localhost “Error establishing a database connection”.

    I can log into the database from the command line, so the credentials are correct and these match the WP config.php file.

    I’m wondering if I may previously have installed MYSQ and it is not where it is expected to be by Apache or whatever?

    Is that a possibility? How can I tell?
    Where would I expect to find my WordPress MYSQL database?
    How can I troubleshoot this? I have spent all of today trying things from the web, but still no success.
    Thanks

    • This topic was modified 7 years, 1 month ago by usererror. Reason: accidentally hit enter/return
Viewing 2 replies - 1 through 2 (of 2 total)
  • Recheck the wp-config and check grants on the database

    Use the MySQL workbench
    https://dev.mysql.com/downloads/workbench/

    Thread Starter usererror

    (@usererror)

    Thanks, as far as I can tell, wp-config is correct – I connected with the db with mysql workbench using the same credentials.

    It appears that the permissions hadn’t been granted, but even after granting full admin rights to the user, it still won’t connect.

    Localhost is looking for (or can’t access the db -I can access the db through the command line & mysql workbench, so why can’t localhost?). How can I tell where is it looking?
    Thanks

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘MYSQL installed correctly?’ is closed to new replies.