I installed Drupal 7 beta on my local machine using Xampp and uploaded and enabled a few modules and everything was working well.
I then followed all the documented steps about migrating the database, compressing and uploading the files to the public server but when I tried to test it in the browser I got the following error:
PDOException: SQLSTATE[28000] [1045] Access denied for user 'comRus'@'localhost' (using password: YES) in lock_may_be_available() (line 163 of /home2/bccan/public_html/bathurst-kgc/includes/lock.inc)...
The really weird thing is that when I try to browse to the test site now on localhost, I get exactly the same error so cannot use my original installation to try again.
As far as I know, I did not do anything to the original files except copy them to another location on my local machine and then make a zip file of them for upload to the local server.
Any suggestions will be gratefully received. Thank you.
Comments
I think I know how to solve
I think I know how to solve the problem.
I assume you uploaded the site you had on your machine to a web server. I would check if the username exists on the new server database. You migrated the database but i don't think you can migrate users the same way.
You could try this on the new database:
GRANT SELECT, INSERT, UPDATE, DELETE, CREATE, DROP, INDEX, ALTER
ON databasename.*
TO 'comRus'@'localhost' IDENTIFIED BY 'password';
Just change databasename and password with your actual values.
Problem solved
Thank you RemoL, I did fix the problem and as I hadn't got a reply I came to let people know that I had found the solution.
You were right it was about the user on the database.
I had created a user and password but had not attached them to the database.
Once I had done that via myPhpAdmin the site sprang into life.
Thanks again for your attention.
Patrick
One issue which people might
One issue which people might also get whwn moving sites from D6 to D7, and then moving it live:
I upgraded a site from D6, tried to move it live and got the same message. This is because the D6 upgrade script adds the new db connection schema to the bottom of settings.php, but keeps the old schema at the top of the page.
So when I moved the site to live, I changed my details using the old schema at the top, but kept recieving the message my password was denied under my old local username. It was only when i scrolled down and saw the new schema that I realised. Hope that helps someone from an hour of hairpullng.
-=[o]=-
Also happens if you have a D7 site in a subfolder on a D6 site apparently, thanks a lot for that, was wondering why it was using my old l/p :)
works at bekandloz | plays at technonaturalist
Must I upgrade?
I wish I could delete comments after asking questions that end up not mattering.
But regardless, thanks a bunch for the info!!