Home > Just the Video Tutorials, WP database > “Error Establishing a Database Connection” — How to Fix This WordPress Error

“Error Establishing a Database Connection” — How to Fix This WordPress Error

“Error Establishing a Database Connection” — How to Fix This WordPress Error: Part 1 of 2

“Error Establishing a Database Connection” — How to Fix This WordPress Error: Part 2 of 2

Share and Enjoy:
  • PDF
  • Print
  • email
  • Facebook
  • MySpace
  • Google Bookmarks
  • StumbleUpon
  • del.icio.us
  • Technorati
  • Digg
  • Sphinn
  • Mixx
  • Blogosphere News
  • Slashdot
  • Yahoo! Bookmarks
  • Faves
  • Live
  • MSN Reporter
  • MyShare
  • Yahoo! Buzz
  • blogmarks
  • FSDaily
  • Reddit
  • Twitthis

No related posts.

  1. October 29th, 2009 at 04:56 | #1

    Brilliant. Wonderful. You saved my day. My whole website was doomed and it is now restored. Thank you so much for you clear exposition of how to troubleshoot the database connection problem.

  2. November 1st, 2009 at 10:05 | #2

    Oh my God, Thanks a lot. You save my work and my current job as well.
    Thanks again.

  3. Ashia
    November 8th, 2009 at 04:22 | #3

    Thanks very much for the helpful videos! I’d like to add one bit of information for you — a simple solution that solved my database connection error without going through the steps that were outlined in the videos.

    In the middle of the wp-config.php file there is a section titled “Authentication Unique Keys”. If you follow the directions there to reset the secret keys, then all who are logged in to the WP admin interface (including a potential hacker) will be kicked out and the cache will be cleared. The secret keys can be changed as often as you like. Be sure to set the CHMOD on the wp-config.php file to 400 for extra security.

    Hope this info is able to help someone else out there!

  4. November 8th, 2009 at 09:55 | #4

    @Ashia: Changing the keys will do what you explained, but that has nothing to do with connecting to the database.

  5. Carsten
    November 12th, 2009 at 07:36 | #5

    Its really brilliant way to help people & defining through video sample…. i’ve a database error with my site : http://www.buying-annuities.org/ and solve by watching this video…. thnx a lot for helping us……

  6. Juice
    November 16th, 2009 at 15:48 | #6

    Ur my hero. Thanks!!!

  7. November 17th, 2009 at 14:23 | #7

    Many thanks for this very clear tutorial. I have a question though: In my case, as I have learned from this tutorial, my Table prefix must have been incorrect as the Wordpress Installation page came up.

    My problem is that I went ahead and filled it in with the result that instead of the error message coming up I found that my site had vanished to be replaced by a brand new blog with the single Hello World! post in it.
    Question: Is there any way I can recover my original blog? All the files appear to be in place on my server.

  8. November 17th, 2009 at 14:47 | #8

    @Alan: All you need to do is find out what the table prefix is on your original blog…those tables will still be in the same database. Then open your wp-config.php file and change the prefix.

  9. Joseph
    November 17th, 2009 at 15:44 | #9

    Thanks so much for posting this!!! :-)

  10. Geraldine
    November 21st, 2009 at 01:47 | #10

    how do you find the new table prefix? mine was wp_ but changed the database and when the installation page popped up i accidentally registered again. and i really would like to switch it bk to the old blog because all my posts are gone. do help! thanks again!

  11. November 21st, 2009 at 09:25 | #11

    @Geraldine: Just look in your current wp-config.php file and see what db you are using. Then open the db in phpmyadmin and you should see the tables. This ONLY applies to a self-hosted wp blog…if you are using wp.com, then you can’t do this.

  12. Geraldine
    November 21st, 2009 at 12:18 | #12

    I am using a self-hosted blog but thing is my server was also changed when the database was changed. and I don’t have any backups. but all my pictures and whatnots are still intact in my ftp server. (which is totally weird)

    and what appears on my ‘table list’ are wp_comments, wp_users, wp_flagcomments and so on.. and i have no idea which i should use. i have tried all of them but i end up at the installation page all the time.

    i am totally new to this so i am sorry!
    but i appreciate you helping out!

  13. Geraldine
    November 21st, 2009 at 12:44 | #13

    my pics and music are all intact but i dont know where are my posts stored in. so i was wondering if i just had to change something else?

  14. November 21st, 2009 at 15:47 | #14

    @Geraldine: Your posts are stored in the database. If you didn’t move the db from the other server as well, then you need to get it. Otherwise, without a back-up…you’re pretty much out of luck.

  15. Kiernan
    December 3rd, 2009 at 04:21 | #15

    Thanks mate, you saved my site!

  16. December 10th, 2009 at 17:04 | #16

    Thank you, Thank You, Thank You…I can’t say it enough. Your tutorial has relived a huge amount of stress for me. you are brilliant!

  17. December 11th, 2009 at 09:22 | #17

    @Carlos: You’re welcome…glad they helped.

  18. January 1st, 2010 at 20:45 | #18

    This video is a lifesaver. I’m new to hosting my own WordPress site, and I was sure that I’d have to uninstall and reinstall the whole thing. Thanks!

  19. Steve
    January 3rd, 2010 at 08:26 | #19

    Thanks very much for making these two videos. I have an important site that was hacked, and these videos helped me to finally recover my admin status. Had never used phpMyAdmin before and your tutorial gave me the confidence to change my database… Would not have attempted this without your video assistance. You are a gentleman and a scholar!

  20. January 3rd, 2010 at 09:45 | #20

    @Steve: You’re welcome…glad it helped.

  21. January 6th, 2010 at 05:49 | #21

    I am sorry, I don’t see this videos.

  22. January 24th, 2010 at 13:06 | #22

    It worked! Thanks! My site had been down for a week and I couldn’t find the source of the problem. All I had to do was switch MySQL host name to “localhost”.

  23. Elsa
    January 25th, 2010 at 06:18 | #23

    Thanks a lot for mentioning that GoDaddy doesn’t use localhost! It saved my day :)

  24. January 28th, 2010 at 18:33 | #24

    Hello,

    Unfortunately, after following your great videos, nothing worked. I have the right information, everything was correct in the DB, password, etc. It’s been hours on end, I still cannot figure it out.

  25. jessica
    January 29th, 2010 at 17:19 | #25

    this was soooo helpful. thank you!

  26. January 31st, 2010 at 22:41 | #26

    Thanks a million!!!! I about had a heart attack when it stopped working. you were right, the password was wrong in my wp-config. Thank you, thank you, thank you!

  27. niaZor
    February 3rd, 2010 at 11:32 | #27

    thxs so much for this…
    I wonder if you have anything on using other function on host panel?

  28. Steve
    February 6th, 2010 at 14:06 | #28

    Great tutorial! not sure why mine broke in the 1st place but following your video got my site back up and running, so thanks a lot!!

  29. February 17th, 2010 at 06:45 | #29

    Thanks for a very clear set of instructions – wonderful!

  30. February 17th, 2010 at 14:41 | #30

    This is a really excellent guide – the only thing I can’t seem to figure out is when I go into my Godaddy SQL database manager the database name and user names are not appended like they are in my current wp config file – so I don’t know how to make sure they are correct? I starting receiving this error even though I dodn’t change anything with my blog in the last few days it just stopped working.
    Are there any references you could direct me to specific to GoDaddy’s listing of Databases and users?

  31. February 17th, 2010 at 17:52 | #31

    @DessertBuzz: If you click on the database link in your godaddy control panel, you should see the db name and user name for each db you have.

  32. February 26th, 2010 at 16:11 | #32

    You saved me as well with the video tutorial – easy to understand and follow. Lucky for me I am also hosted with Bluhost so it was even easier to understand. created a new user and that solved the problem. I don’t know why the old user got corrupted.
    Thanks for the great tutorials.

  33. vrrockers
    March 3rd, 2010 at 12:57 | #33

    hi..i tried all your tips but still error in establishment with database….
    my webpage just loading ….loading….loading…….
    i purly use tdo mini form for posting purpose …
    here is some information might be useful for u
    when i open phpmyadmin it will default show databases on left hand side but there is nothing just shows white space…but when i click on databases from menu it shows database ….but not open after click on that…
    i request my host to resolve this problem but from 2 days there is no response….

  34. March 6th, 2010 at 03:55 | #34

    Hello, Can you help me?

    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 mysql509.ixwebhosting.com. 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.

  35. March 6th, 2010 at 04:03 | #35

    Please help me to check the http://www.freeplrmrr.com/download/

    I have the “Error establishing a database connection”

    Thanks…

  36. March 6th, 2010 at 18:55 | #36

    @Jay Soary: Other than what’s in the video, I can’t help…it must be one of those things.

  37. Esales
    March 7th, 2010 at 05:06 | #37

    Extremely grateful.

    After watching these videos, I was able to fix the error message that a host company couldn’t do in a day!

    Absolutely brilliant!

    Thank you

  38. Karla
    March 8th, 2010 at 20:51 | #38

    Thank you – this is exactly the info I was looking for, and my problem is fixed!

  39. Matt
    March 17th, 2010 at 14:18 | #39

    Thanks for the videos. However, is there a way to test if the blog NEVER worked? I just installed everything for the first time, and I’m getting the “Error establishing a database connection” error. I think I have everything set correctly in wp-config.php. I know php is working (on my Windows server); I know the database and user is online and available (I’ve created a test table in my ‘wordpress’ database using my ‘wordpress’ user. And I have all the settings in the config file, using db_host ‘localhost’ but get the error.

    Your videos assume that the blog is working, and then by changing certain items, you illustrate how to trouble shoot. If I can successfully do those other things (see a web page in php, get into the database through a command prompt), do you have any suggestions to trouble shoot the error? Thanks!

  40. Matt
    March 17th, 2010 at 16:07 | #40

    Fixed! In the absence of a working blog installation as a reference point, I went back to the database and deleted (dropped) everything related to my new installation. I dropped the database and user I had created for the blog, and started over. I created the database, created the user, and granted permissions to the user on the new database, and now I can get to the WordPress installation page!

    Thanks for allowing me to think out loud!

Comment pages
1 2 148
  1. June 29th, 2009 at 05:53 | #1
Get Adobe Flash playerPlugin by wpburn.com wordpress themes