0
Welcome Guest! Login
0 items Join Now

ROCKETTHEME IS CLOSING ON JUNE 30, 2025. As a thank-you to our community, enjoy 50% off all themes with the promo code THANKYOU before we shut down. Read our Farewell Blog Post for more details.

Database Error: Unable to connect to the database:Could not

  • Database Error: Unable to connect to the database:Could not

    Posted 16 years 3 months ago
    • Hi,

      I’m not sure why, but Im getting the below error message when I try to visit any of my four sites (i.e. www.grouptour.com.au ):

      Database Error: Unable to connect to the database:Could not connect to MySQL

      I can still log into the cPanel.

      I have no idea what caused this or how to fix it. Please help.

      Thanks a lot,

      Andy Richards
      Understand down under - 1 day Royal National Park Eco-tours
  • Re: Database Error: Unable to connect to the database:Could not

    Posted 16 years 3 months ago
    • hi,

      please check your configuration.php and ensure that the database details (user, db name, password) are correct
    • Ragdata's Avatar
    • Ragdata
    • Elite Rocketeer
    • Posts: 614
    • Thanks: 0
    • Software Engineer

    Re: Database Error: Unable to connect to the database:Could not

    Posted 16 years 3 months ago
    • Are your sites on shared hosting? If so, call your provider and tell them to reboot mysqld.

      Are your sites on your own dedicated server? If so, reboot mysqld.

      cPanel uses a completely different database (postgreSQL I think) to your websites for exactly this reason - something can take down your site databases (script overrun, or one of a million other reasons), but you are still able to use your cPanel.
    • Ragdata's Rubber Duck
      www.ragdata.net/
  • Re: Database Error: Unable to connect to the database:Could not

    Posted 16 years 3 months ago
    • Hi,

      I dont know if I did the right thing, but that didnt seem to work.

      I just realised how I might of caused the problem. I recentyly requested a "cPanel password reset" email.

      does that change things?
  • Re: Database Error: Unable to connect to the database:Could not

    Posted 16 years 3 months ago
    • cPanel password reset should not change the database details. cPanel also runs mySQL database (as well as postgreSQL).

      First, check this in your cPanel, in the right side:
      "Service Status Click to View" , see if the mysql service is up or not. If it's down, contact your hosting.

      If it's up, did you change anything(especially the database details) recently in your configuration.php of Joomla?
  • Re: Database Error: Unable to connect to the database:Could not

    Posted 16 years 3 months ago
    • the mysql service is up.

      I havent changed the configuration.php file on purpose (i.e. I havent opened it up), I dont know if its possible to accidently change things

      So should I call my server and get them to reboot mysqld?
  • Re: Database Error: Unable to connect to the database:Could not

    Posted 16 years 3 months ago
    • Andrew Richards wrote:
      So should I call my server and get them to reboot mysqld?
      if you are on shared hosting I am afraid they are unwilling to do this because this will affect other users on the same server.

      If you are sure you didn't change anything on the database details, it's okay too to discuss and ask your hosting first.

      or you may try to create a new database user, assign it to your joomla database, and change your configuration.php with this new details too.
  • Re: Database Error: Unable to connect to the database:Could not

    Posted 16 years 3 months ago
    • Thanks, Ive fixed it now. It was the configuration.php file that needed changing (i.e. the new password), it wasnt working initially because I needed to change the permissions.

      Thanks a lot for all your help.

      :D

Time to create page: 0.078 seconds