Mysql Sql Error 1045 Sqlstate 28000
Contents |
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us error 1045 sqlstate 28000 access denied for user 'root'@'localhost' Learn more about Stack Overflow the company Business Learn more about hiring developers error 1045 28000 access denied for user using password yes or posting ads with us Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack mysql access denied for user using password yes Overflow Community Stack Overflow is a community of 6.2 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up SQLSTATE[28000] [1045] Access denied for user 'root'@'localhost'
Mysql Access Denied For User Root
(using password: YES) Symfony2 up vote 8 down vote favorite 1 I tried to create my DB with Symfony2. I typed the command: php app/console doctrine:create:database The result is: Could not create database for connection named `jobeet` SQLSTATE[28000] [1045] Access denied for user 'root'@'localhost' (using password: YES) The contents of my app/config/parameters.yml file is: parameters: database_driver: pdo_mysql database_host: 127.0.0.1 database_port: ~ database_name: jobeet database_user: root database_password: 0000 mysql drop anonymous user mailer_transport: smtp mailer_host: 127.0.0.1 mailer_user: ~ mailer_password: ~ locale: fr secret: ThisTokenIsNotSoSecretChangeIt My OS is Ubuntu. I don't know what to do to correct this problem. Thanks for your help. mysql ubuntu symfony2 share|improve this question edited May 1 '13 at 19:41 wescrow 2,1901021 asked May 1 '13 at 19:36 mentaga 41113 5 Access denied for user 'root'@'localhost' (using password: YES) is a MySQL connection error. Usually implies invalid user and/or password. Sometimes you have to use localhost not 127.0.0.1 for this to work. –rncrtr May 1 '13 at 19:38 1 Is the password in quotes? –Patrik Karisch May 1 '13 at 22:15 3 Congratulation !!! The password need to be enter quotes. thank you very much!! How to do this post at resolved status? –mentaga May 1 '13 at 22:54 add a comment| 6 Answers 6 active oldest votes up vote 6 down vote Try to login via the terminal using the following command: mysql -u root -p It will then prompt for your password. If this fails, then definitely the username or password is incorrect. If this works, then your database's password needs to be enclosed in quotes: database_password: "0000" share|improve this answer edite
here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack mysql access denied for user using password no Overflow the company Business Learn more about hiring developers or posting ads with us
#1045 Access Denied For User Localhost Using Password Yes
Stack Overflow Questions Jobs Documentation Tags Users Badges Ask Question x Dismiss Join the Stack Overflow Community Stack Overflow is a community
Error 1045 Mysql Windows
of 6.2 million programmers, just like you, helping each other. Join them; it only takes a minute: Sign up How do I fix this error: [1045] SQLSTATE[28000] [1045] up vote 0 down vote favorite I http://stackoverflow.com/questions/16325115/sqlstate28000-1045-access-denied-for-user-rootlocalhost-using-password am working on a server that is not my localhost for the first time. I am renting hosting space from hostgator. I created a form that is supposed to take the user's information and put it in the database. I keep on recieving the following error message when I try to submit the form: Failed to open database [1045] SQLSTATE[28000] [1045] Access denied for user 'username@localhost'@'gator7899.hostgator.com' (using password: YES) I have seen http://stackoverflow.com/questions/14698256/how-do-i-fix-this-error-1045-sqlstate28000-1045 other posts in which people ask the same question but none of the answers given are working for me. Also, username is not my actual username and gator7899 is not the actual server. For security purposes I did not post them here. Does anyone know how to fix this? mysql database localhost share|improve this question edited Feb 5 '13 at 0:36 Lion 9,673135485 asked Feb 5 '13 at 0:34 Philip7899 1,7691648 add a comment| 1 Answer 1 active oldest votes up vote 0 down vote Make sure privledges are assigned in your CPanel -> mysql admin -> add user to database then you need to change your config to be localhost username = username of CPanel password = password of Cpanel share|improve this answer answered Feb 5 '13 at 0:39 Val 364110 I can't find the configuration file in the control panel or in the file directory. Any idea on where it would be? Thank you. –Philip7899 Feb 5 '13 at 0:47 I would look at the page that is displaying the error, look at the code/line where there is a connection to mysql and append the username and password accordingly. –Val Feb 5 '13 at 0:48 add a comment| Your Answer draft saved draft discarded Sign
communities company blog Stack Exchange Inbox Reputation and Badges sign up log in tour help Tour Start here for a quick overview of the site Help Center Detailed answers to any questions you might have Meta Discuss the workings and policies of this site About Us Learn more about Stack Overflow the company Business Learn more about hiring developers or http://askubuntu.com/questions/401449/error-104528000-access-denied-for-user-rootlocalhost-using-password-no posting ads with us Ask Ubuntu Questions Tags Users Badges Unanswered Ask Question _ Ask Ubuntu http://www.yiiframework.com/forum/index.php/topic/50166-database-connection-probelm-sqlstate28000-1045-access-denied-for-user/ is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute: Sign up Here's how it works: Anybody can ask a question Anybody can answer The best answers are voted up and rise to the top ERROR 1045(28000) : Access denied for user 'root@localhost' (using password: no ) up vote 32 down vote favorite 10 I'm trying to install queXS access denied cati app on my Ubuntu desktop and I installed MySQL server and PHP 5 and I cannot login into MySQL server as root without password: mysql -u root it says ERROR 1045(28000) : Access denied for user 'root@localhost' (using password: no ) But it's okay when I enter mysql -u root -p I can't figure out what the problem is. permissions mysql share|improve this question edited May 12 at 8:31 oerdnj 3,8661440 asked Jan 7 '14 at 10:42 user232705 161123 6 Try access denied for this: mysql -u root -p mysql Enter password: and you will get: mysql> –user273774 Apr 24 '14 at 18:47 add a comment| 3 Answers 3 active oldest votes up vote 29 down vote That is the normal behaviour. You set a root password for your database so from now on you can't access it without password. That is why it reports: Access denied for user 'root@localhost' (using password: no ) Obviously when you give the password with the -p switch you succeed. share|improve this answer answered Jan 7 '14 at 10:47 falconer 9,94721846 add a comment| up vote 2 down vote In simple words your "root" session do not know password to mysql root user. If you want to make easier to access your mysql create .my.cnf in /root/ and put in it [mysqladmin] user = root password = mysqlrootpassword [mysql] user = root password = mysqlrootpassword [mysqldump] user = root password = mysqlrootpassword where offcourse mysqlrootpassword is your password for mysql's root password so when you execute mysql it uses this password Remeber about safety of this file - put secure rights, so nobody on your server can read it! share|improve this answer answered Jan 16 '14 at 22:25 pl_ 491 1 It's bad to encourage others to put root passwords plaintext on disk. By deduction, that badness property propagates to the person doing it. –Eric Leschinski Dec 31 '15 at 11:49 add a comment| up vote -1 down vote Login to webmin and unde
Extensions Demos Logo Documentation Take the Tour Tutorials Class Reference Wiki Guide 2.0 Class Reference 2.0 Screencasts Resources Development Contribute to Yii Latest Updates Report a Bug Report a Security Issue Community Forum Live Chat News Hall of Fame Badges search Yii Framework Forum: Database Connection Probelm / Sqlstate[28000] [1045] Access Denied For User - Yii Framework Forum Jump to content Sign In » New user? Register Now! Help Search Advanced ForumsMembers Yii Framework Forum > Yii 1.1.x > Installation and Setup View New Content Page 1 of 1 You cannot start a new topic You cannot reply to this topic Database Connection Probelm / Sqlstate[28000] [1045] Access Denied For User #1 sts Newbie Group: Members Posts: 3 Joined: 26-December 13 Posted 26 December 2013 - 11:25 AM Hi, Spent quite some time to try to fix a connection problem following advice from older threads but can't solve this. I do get the Gii interface and I can connect to the database in terminal. But when I try to create a model Yii throws this error: CDbConnection failed to open the DB connection: SQLSTATE[28000] [1045] Access denied for user 'tom'@'localhost' (using password: YES) My settings are: 'db'=>array( 'connectionString' => 'mysql:host=127.0.0.1;dbname=my_db', 'class'=>'CDbConnection', 'emulatePrepare' => true, 'username' => 'tom', 'password' => 'my_password', 'charset' => 'utf8', ), If I try with localhost it gives me CDbConnection failed to open the DB connection: SQLSTATE[HY000] [2002] No such file or directory Thanks for any help! 0 Back to top of the page up there ^ #2 JFReyes Advanced Member Group: Members Posts: 508 Joined: 28-October 09 Location:Puerto Rico Posted 26 December 2013 - 11:36 AM You must have the user defined in MySQL's user table: CREATE USER 'tom'@'localhost' IDENTIFIED BY 'my_password'; Notice that 'localhost' is not the same as '127.0.0.1'; if you want to be able to login from anywhere use '%' as the host address. José 0 Back to top of the page up there ^ #3 sts Newbie Group: Members Posts: 3 Joined: 26-December 13 Posted 27 December 2013 - 11:32 AM JFReyes, on 26 December 2013 - 11:36 AM, said: