• Hi, need a little help with something because I’m stuck.
    Timeline:

    • Discovered site was down, displaying “Error establishing a database connection”
    • ssh’ed into my box and had a quick glance at the http logs
    • Saw multiple POST requests to xmlrpc.php from a Russian IP
    • TIL about xmlrpc.php exploits
    • Install Jetpack, block access to xmlrpc.php
    • I restart mysql sudo service mysql restart
    • Everything is good again!
    • 5 mins later everything is bad again, but no more hacking attempts

    So yeah, if I restart mysql it works for a few mins then I’ll get the error again rinse repeat. Anyone know how to undo this guys handy work?

Viewing 1 replies (of 1 total)
  • Hello @louden100,
    Go to wp-config.php file and check for db_name, db_user, db_password, db_host.
    Enter the data as per the database and username assigned in your hosting. Also check for the table prefix ex: wp_ in the database tables. Always make sure that hosting provider’s cpanel prefix is correctly setup in database name.

    db_host = ‘localhost’ (in Linux Hosting)
    db_host = ‘<Database_server_IP_address>’ (in Windows Hosting)

Viewing 1 replies (of 1 total)

The topic ‘"Error establishing a database connection" Help’ is closed to new replies.