The Base, or just another error establishing a database connection

I knew it was too good to be true. :( Really, in the past few days I was sooo fascinated by the WordPress and his high power-level utilities: the endless sea of pre-designed themes for you to choose from, amazing number of plugins for additional customization, and unbelievable automatic stuff it provides (like feed and comments feed for your visitors to subscribe to, instant updating of the structure of all previous pages when you add another page to you site, etc.)… I was so delighted, that I overlooked its biggest flaw.

There are workarounds (backing up the base), but most people (myself included) do not want to bother with the bases

The Base. In reality, it might not be that bad, but I’m the “control freak”. And it scares the s* out of me knowing that everything I do might go away in flames easily. If the case of the (MySQL) base malfunction, the whole site-blog and its every little page is a history, you’re doomed! Now, there are workarounds (backing up the base), but most people (myself included) do not want to be bothered with the bases. What about those that don’t use backups, or still don’t feel their place reached that point when it should be backed up and saved (the second type, as you might have guessed already, is actually me ;) ).

Well, the worst happened yesterday – my site was offline for at least 12 hours. I was in the middle of work when I started feeling slowdowns on page loads, then few times I got the infamous “Error establishing a database connection” message, and very soon I hit the wall – the site was down, and all I could see was that stupid message again and again. I couldn’t log in, I couldn’t watch the site as a visitor, I couldn’t do anything.

Called the technical support of my hosting company. They said there’s some problem on their side, but it will be corrected soon. Few hours later, site was still down, me also, but the company’s working hours ended. I was on my own, with the whole night in front of me. Time to do some homework.

This connection error happens when your wp-config.php parameters are wrong, or your db server is down

I googled the hell out of this subject. Read like thousands of posts. Basically, error establishing a database connection happens mainly because of the few things: either some of your wp-config.php parameters (username, password, dbname or hostname) is wrong and doesn’t match the same database parameter, or your database server is down. The 2 most helping articles on the subject I found were this post, and this 2-part movie series talking about ways to fix this error. Unfortunately, none of the described ways worked for me. :(

I was really puzzled, as it all looked just fine: my wp-config username and password were correct, as I used them to manually log onto the base (using phpMyAdmin, provided by the hosting company on my control panel), and in the base I saw its name and the server name. All seemed correct. Also, I could log on to site using FTP connection – everything looked OK there as well. The big question mark was flashing above my head…

How did I solved it? Actually, I didn’t. :P Instead, after the night of frustration, I mailed the support company and described everything I tried. They responded this morning and said that the problem was in the host IP address for the base connection – they corrected it, and the site is working now. :) And it indeed works. The feed subscription is behaving strangely in the moment, but I’ll look into it later – right now, I though that this whole thing could be helpful to someone, so I set to write it down while it’s still fresh. Cheers.

,  

Trackback URL

7 Comments to “The Base, or just another error establishing a database connection”

  1. Bojana says:

    Oh, that is why site was down for a while!

  2. Tracy Brady says:

    You’re right..Problems with the IP address is something we definately should have mentioned in the blog posts… I’m glad you got a semblance of resolution though. .Cheers.

    • Paraleader says:

      Hi Tracy, nice of you to stop by. Your text on the same subject was very informative, I liked it a lot.

  3. Nice site design , what is the name of tamplate you used in your site

    • Paraleader says:

      Thanks. You have the link to the designer’s site down right. I modified it quite a bit, though, to enable it for some needed stuff.

  4. Very cool blog, but you must improve your template graphics.

  5. Excellent article i am sure that i will come back here soon

Leave a Reply

Subscribe to Comments

Spam Protection by WP-SpamFree