• Hi. Last week I updated everything and my website was fine. Now I’m getting this error message when I try to get onto the site:
    Error establishing a database connection.

    When I try to get into wp-admin I get the following message:
    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 cust-mysql-123-21. 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

    Website is: https://www.crowndentalgroup.co.uk

    I’ve been in touch with the hosting company and I’m waiting to hear what they have to say. I have a couple of other websites with the same hosting company and they are working fine. They are not wp sites though – built from code from scratch – which kinda goes against what I’m about to say next.

    Although I have some experience of computers I’m not really confident when it comes to changing things – like disabling plug ins etc. So I’m looking for an east solution to this, if it isn’t host related. I only got involved to help husband and his business out and now I seem to be drowning in this. Daft though it seems I was happier working in dreamweaver! However I couldn’t get the type of site they wanted and I was told wp was easy to use – which has been up till now!

    Thank you

Viewing 5 replies - 1 through 5 (of 5 total)
  • Hi @eg99,

    It sounds like your site may be using up the allocated resources for your hosting plan. This would be a hosting issue most likely but there still may be things you can do.

    To clarify, a lot of hosting plans have hundreds of sites running on one server and thus making some shared hosting solutions a horrible experience.

    IMO, there could be a couple things that are causing the issue:

    – The server itself is under a heavy load and thus effecting all sites that need a DB to run.
    – Something on you site is using resources (a plugin or spam)

    Depending on what the host comes back with, you may have to take things into your own hands. Try installing a cache plugin to limit DB queries as must as possible. If you site is too big, then you may need to upgrade or move you site to a more suitable hosting platform that meets your needs.

    Thread Starter EG99

    (@eg99)

    Hi @justin Greer. Thanks for the quick response.

    The site isn’t that big, but perhaps a plugin is up to something! I’ll just have to wait till they get in touch with me: I just wanted to be armed in case they start asking questions and batting things back to me. Also to try and get things running again asap if it isn’t a problem with them.

    Thanks again

    Thread Starter EG99

    (@eg99)

    Hi @justin Greer.

    Well funnily enough, having been in touch with the hosting company, they can’t find anything wrong and the site is working again!

    However I decided to look into the size of the website and it would appear that there are problems with the web space allocated. I’ve sent a couple of messages to them regarding this however they’ve gone very quiet.

    Thank you again for your help and pointing me in the right direction regarding the size of the site (it’s less than 8000 MB). Now off to fight the hosting company, before looking for a new one!

    I would suggest looking into optimizing your site. This would include cleaning the DB of revision (if you can), Optimizing your images, and removing things that are not needed. It is pretty common to run into resource limits on shared hosting but fortunately there are things that you can do to lower the chances of a limit being hit.

    Glad we could shed some light on what may be happening.

    I’ve worked for a couple of hosting companies. Here’s the fix.

    1) go to your wp-config file for that site , and find the name of the database
    2) go to cpanel and go to mySQL Databases
    3) create a new user. When you create the user make sure you copy the password as you will need it later.
    4) add the user to the database , typically I give all permissions
    5) go back to the wp-config file. Find the password in it, replace the old password with the new password and replace the old user with the new user.
    6) save the wp-config file
    7) check your site.

    If that does not resolve the database issue then there is a chance that there could be an issue with the hosting, such as MySQL not running on the server.

    ~Support Monkey

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘WordPress or hosting problem?’ is closed to new replies.