• Plesk Uservoice will be deprecated by October. Moving forward, all product feature requests and improvement suggestions will be managed through our new platform Plesk Productboard.
    To continue sharing your ideas and feedback, please visit features.plesk.com

CMAdamadman

New Pleskian
Hello,

I am trying to get a database to link to a site, but whatever I do I cant get them working. I have used MySQL, Postgres, and even browser based databases, but i always get an error when i reload the site. I then tried making tables and importing tables using MyPHPadmin, but i get an error suggesting that I dont have the permissions. So now Im thinking its all related to the same Plesk related permission issues, but Im the only user, so how can I not have the permissions?

If I am in the wrong topic, please direct me to where I should post.

Thanks
 
Hello, its Fatal error: Uncaught PDOException: SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: YES) in /var/www/vhosts/25bi75bc.example.co.uk/httpdocs/test_db.php:7 Stack trace: #0 /var/www/vhosts/25bi75bc.example.co.uk/httpdocs/test_db.php(7): PDO->__construct() #1 {main} thrown in /var/www/vhosts/25bi75bc.example.co.uk/httpdocs/test_db.php on line 7
 
Last edited by a moderator:
Thank you for the update. Could you please double-check the test_db.php file (or whichever the database config is for your application) and confirm if the database user is correctly defined. It should be the one you see assigned for the database when you navigate to Domains > example.co.uk > Databases > Connection info button in the database card.

What else you might do, is test the credentials defined in your website's config file by executing the following command:

mysql -u db_user -p db_name

Then you'll be prompted for the database password.
 
Back
Top