Joomla database connection error shown while tried to install

Asked By 50 points N/A Posted on -
qa-featured

Hi,

During the installation I received the following error message

Database connection error (2): Could not connect to MySQL.

I have entered the MySQL database details correctly but I could not connect. What is wrong?

Can I get the possible solution?

I am waiting for your resolution. Any help would be appreciated.

Thanks.

 

Database connection error (2): Could not connect to MySQL.

SHARE
Answered By 30 points N/A #190022

Joomla database connection error shown while tried to install

qa-featured
Hi there Stephen R Gates,
 
The number (2) in your error 'Database connection error (2): Could not connect to MySQL' indicates that your Joomla configuration.php doesn't have the right information about your database. This could be due to several reasons including wrong username, password or database name.
 
The first thing you should do is to open your configuration.php file and see what's written in it. If the username and password are correct, you may want to change the password on your database using the database wizard via the cpanel and replace the password with the new one.
 
Also, check if the database host is correct as some hosts are not using localhost. That information can also be found in your database manager in the hosting cpanel.
 
Another thing to do is to check the permissions on your database. The user you are using to connect to the database should have all permissions available.
 
Best regards,
Drake Vivian

Related Questions