Error establishing a database connection

Web hosting discussion, programming, and shared and dedicated servers.
3 posts Page 1 of 1
by lovecoop » Fri Jan 20, 2023 9:30 pm
I mistakenly changed the WordPress Address(URL) as well as the Site Address(URL) while tinkering with a potential domain name change. I was able to log into phpMyAdmin after changing the Database password. I reverted the broken domain back to the original domain name in wp_options > siteurl and home. As soon as I changed it back I am met with "Error establishing a database connection". When I try to go to "http://www.myurl.org/wp-admin/index.php I am met with

Code: Select all

Error establishing a database connection
This either means that the username and password information in your wp-config.php file is incorrect or we can’t contact the database server at lovecoop-wp.db.sonic.net. This could mean your host’s database server is down.

Are you sure you have the correct username and password?
Are you sure that you have typed the correct hostname?
Are you sure that the database server is running?
If you’re unsure what these terms mean you should probably contact your host. If you still need help you can always visit the WordPress Support Forums.
Is there a place to check or update the database password via phpMyAdmin?

edit: spelling
by joemuller » Wed Jan 25, 2023 12:05 pm
For your case, you have a full database with phpMyAdmin access, so you can change the password(s) through Member Tools. You will want to click through from Databases -> Manage database (your database name) -> Change Password, check the boxes for the users you want to change, then click Continue. After that, new passwords will be set up and displayed for you to use. (Note that once you click away from the results page, there is no way to view those passwords again.)

It looks like your Wordpress blog is using the lovecoop_wp-all database, so that's the username and password you'll need to update in the wp-config.php file for your site to match.

On a side note, it looks like there is an issue with your domain registration, as I cannot get a response when I attempt to load the site. Since your website's domain is set up for DNS with Sonic, you'll want to make sure that the Name Servers set up with whoever you use for registration are set to the following:

Code: Select all

a.auth-ns.sonic.net
b.auth-ns.sonic.net
c.auth-ns.sonic.net
Please feel free to sent me a message through the forum if you'd like some additional help and I'll see what I can do to assist!

-- Joe M
I'm a proud employee of Sonic.net! :-)
by lovecoop » Wed Jan 25, 2023 9:40 pm
Thank's for the reply, Joe.

I was able to change the password and access phpMyAdmin. I was able to change the site URL and home URL back to the correct address.

Inside phpMyAdmin's directory I have to main folders. One named information_schema and another named lovecoop_wp. To change the site and home URL I went to lovecoop_wp > wp_option and was presented with a table. Table 1 is siteurl and table 2 is home.

I cannot find wp_config.php anywhere.

I corrected the domain registration so there should be a response now.

Thank you.
3 posts Page 1 of 1

Who is online

In total there are 24 users online :: 0 registered, 0 hidden and 24 guests (based on users active over the past 5 minutes)
Most users ever online was 999 on Mon May 10, 2021 1:02 am

Users browsing this forum: No registered users and 24 guests