Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Fedora 10, mySQL 5.0.67 has a different login steps from FC-7, mySQL 5.0.37, and I got an error of access.

Posted on 2014-04-22
6
Medium Priority
?
389 Views
Last Modified: 2014-04-26
Up to MySQL 5.0.37 (FC-7), there were username and password for login to get into the MySQL server.    However, when I am in Fedora 10, MySQL 5.0.67, I got different login steps,

$ mysql -u username -p
password :   xxxxxx           MySQL 5.0.37 (FC-7)


$ mysql -u username -p
ERROR:   Access denied for user ' '@'localhost' to database '   '.
                                                  Fedora 10, MySQL 5.0.67


I did exactly the same way of initial setting to both MySQL server (Fedora Core 7 and Fedora 10), which I learned from textbook "Learning SQL".   That procedure was as below,


$ mysql -u root
(Welcome messages)

mysql>  UPDATE  mysql.user
          ->   SET  password =  PASSWORD('root_password')
          ->   WHERE User =  'root';
(Query OK, message)

mysql>  FLUSH PRIVILEGES;
(Query OK)

mysql>  grant all privileges on *.* to 'mkido'@'localhost'  identified by 'xxxxx(mkido_password)';

(Query OK message)


=====================================================
After this initial root and username(mkido) setting, when I issue the following command line, I got an error like below, PLEASE help me, how to deal with !

[username@.. ~]$  mysql   -u  mkido
ERROR 1045 ..:    Access denied for user 'mkido'@'localhost' (using password: NO)

OR - OR - OR -

[username@.. ~]$  mysql   -u  mkido -p
ENTER password :   XXXXX     (I typed in my password.)
ERROR 1045 ..:    Access denied for user 'mkido'@'localhost' (using password: YES)

What do you think ?    Thanks.
0
Comment
Question by:mkido
  • 4
  • 2
6 Comments
 
LVL 84

Accepted Solution

by:
Dave Baldwin earned 2000 total points
ID: 40018567
I think something else is going on because that login to 'mysql' hasn't changed since at least version 3.23 and remains the same in the current version.   http://dev.mysql.com/doc/refman/5.7/en/mysql.html  You can try the 'long' syntax:
mysql --user=user_name --password=your_password db_name

Open in new window

0
 

Author Comment

by:mkido
ID: 40018988
I agree.    Something else is going on.    It is absolutely weird.    

(shell) $ mysql -u root_password      OR
(shell) $ mysql  -u user_paassword

makes me get into MYSQL, and I see welcome message.     They must be root or username.    Apparently, user and password appear mixed up (or exchanged).     Very weird.    


 Well, let me continue later, because I may want to completely reload the Fedora 10 entire system.    There is no data or special setting on this computer (local, not on net).   So, I have no problem of complete cleaning up.
0
 
LVL 84

Expert Comment

by:Dave Baldwin
ID: 40019051
Ok.
0
Windows Server 2016: All you need to know

Learn about Hyper-V features that increase functionality and usability of Microsoft Windows Server 2016. Also, throughout this eBook, you’ll find some basic PowerShell examples that will help you leverage the scripts in your environments!

 

Author Comment

by:mkido
ID: 40021456
THIS TIME, NORMAL LOGIN IS WORKING :


I have completely reloaded the entire Fedora 10 Operating System.   Because the computer is a local one, and this procedure only took about one hour or so.    

After I started the band new Fedora 10 computer, I started mysqld as below,
   
# /etc/init.d/mysqld    start

then initialization of MySQL database and starting MySQL were [OK].   Then, I did

$ mysql -u root

mysql>  UPDATE  mysql.user
          ->   SET  password =  PASSWORD('root_password')
          ->   WHERE User =  'root';

mysql>  FLUSH PRIVILEGES;

mysql>  grant all privileges on *.* to 'mkido'@'localhost'  identified by 'xxxxx(mkido_password)';


AFTER THIS SETTING, EVERYTHING works normal.   ALL LOGINs work normal.  
Perhaps, somewhere in the MySQL setting, I messed up at the previous time.     During the previous setting I had to break up one time procedure into two times or more, due to displaying to my student, who is learning MySQL as a newbie.       Thank you so much, Dave.    Practically I fixed it by Operating System (Fedora 10) reloading.
0
 
LVL 84

Expert Comment

by:Dave Baldwin
ID: 40021575
I'm glad you got it working .
0
 
LVL 84

Expert Comment

by:Dave Baldwin
ID: 40024188
Thanks for the points.
0

Featured Post

Configuration Guide and Best Practices

Read the guide to learn how to orchestrate Data ONTAP, create application-consistent backups and enable fast recovery from NetApp storage snapshots. Version 9.5 also contains performance and scalability enhancements to meet the needs of the largest enterprise environments.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Password hashing is better than message digests or encryption, and you should be using it instead of message digests or encryption.  Find out why and how in this article, which supplements the original article on PHP Client Registration, Login, Logo…
When table data gets too large to manage or queries take too long to execute the solution is often to buy bigger hardware or assign more CPUs and memory resources to the machine to solve the problem. However, the best, cheapest and most effective so…
In this video, Percona Solution Engineer Dimitri Vanoverbeke discusses why you want to use at least three nodes in a database cluster. To discuss how Percona Consulting can help with your design and architecture needs for your database and infras…
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…
Suggested Courses
Course of the Month10 days, 11 hours left to enroll

885 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question