MySQL Error 1045 after transferring & renaming an account via WHM
Hello,
I transferred an account from one VPS (VPS-OLD) to another (VPS-NEW) using the tools at:
Home "Transfers "Copy an Account From Another Server
There was an account on VPS-OLD that had the same name as one already existing on VPS-NEW; so as part of the transfer process I had to rename it using the Local User Name field.
The account appeared to transfer fine, but when I attempt to log into a MySQL driven web application, I receive the following error message:
Database connection failed. Error received from database was #1045: Access denied for user 'oldaccountname_webapp'@'localhost' (using password: YES).
The page also displays the following non fatal error:
SYSTEM WARNING: 'mysql_connect() [function.mysql-connect]: Access denied for user 'oldaccountname_webapp'@'localhost' (using password: YES)' in '/home/newaccountname/public_html/webapp/library/adodb/drivers/adodb-mysql.inc.php' line 365
When checking the MySQL database and users on the transferred (renamed) account on VPS-NEW I see that both the database and usernames are prefixed by the newaccountname (as discussed above). There is no reference to the oldaccountname(s) in the database prefixes for the database name and user.
The web application I am attempting to reach is somewhat critical so I would like to address this as quickly as possible and would greatly appreciate a (noob) step-by-step approach to resolving this issue. Thanks in advance for your help.
Winnie
-
You mast change database settings (database name and database user name) in your web application so that they match the new names. 0 -
Hello :) Yes, the configuration file for your script/application needs to be modified with the new database name and database username details. Thank you. 0 -
Thank you to both quietFinn and cPanelMichael for the replies. I have updated the application with the renamed database and user names (prefixes) and I am now able to access the application. I really appreciate the help. Winnie 0
Please sign in to leave a comment.
Comments
3 comments