Home  >  Q&A  >  body text

Title rewritten to: Access Denied: User with username 'username'@'localhost' (no password used) Error 1045 (28000)

I moved my website from one host to another and both are on Cpanel but when I open the website I get this error

CodeIgniterDatabaseExceptionsDatabaseException #8
Unable to connect to the database.
Main connection [MySQLi]: Access denied for user '****'@'localhost' (using password:YES)

When I SSH into the site and enter this command Enter image description here

I moved the old database to the new site and when I completed the transfer, there were Many problems, especially mysql database

Here are the pictures of the site errors

1 Enter image description here 2 Enter image description here 3 Enter image description here 4 Enter image description here 5 Enter image description here 6 Enter image description here 7 Enter image description here

P粉336536706P粉336536706295 days ago440

reply all(1)I'll reply

  • P粉668019339

    P粉6680193392023-12-30 00:12:16

    Access denied for user "****"@"localhost" (use password: YES) That in itself shows where you are wrong! Have you tried creating a new MySQL user and granting permissions to that user?

    This isn't even a database problem! Your password is wrong, or user rights to the database are missing or the user itself does not exist. First try going to cPanel > MySQL Database...

    reply
    0
  • Cancelreply