Solved

Issues creating and logging in as a new user

Posted on 2012-04-06
3
218 Views
Last Modified: 2012-08-13
Ive been having issues logging on as a new user, and Im not sure what Im doing wrong.

Im creating the usesr as:-
D:\mysql\bin>mysql -u root
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 59
Server version: 5.5.16 MySQL Community Server (GPL)

Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> CREATE USER 'myuser'@'%' IDENTIFIED BY 'mypass';
Query OK, 0 rows affected (0.00 sec)

mysql> quit
Bye

Open in new window


Which all seems fine, so then I try and connect:-
D:\mysql\bin>mysql -h localhost -u myuser -pmypass
ERROR 1045 (28000): Access denied for user 'myuser'@'localhost' (using password: YES)

Open in new window


Any ideas what Im doing wrong
0
Comment
Question by:tonelm54
  • 2
3 Comments
 
LVL 17

Expert Comment

by:Anuroopsundd
ID: 37816469
did you grant permission to user?
0
 

Author Comment

by:tonelm54
ID: 37816533
Yes, but still same issue:-

D:\mysql\bin>mysql -u root
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 74
Server version: 5.5.16 MySQL Community Server (GPL)

Copyright (c) 2000, 2011, Oracle and/or its affiliates. All rights reserved.

Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

mysql> GRANT ALL PRIVILEGES ON *.* TO 'myuser'@'%' WITH GRANT OPTION MAX_QUERIES_PER_HOUR 0 MAX_CONNECTIONS_PER_HOUR 0 MAX_UPDATES_PER_HOUR 0 MAX_USER_CONNECTIONS 0;
Query OK, 0 rows affected (0.00 sec)

mysql> quit
Bye

D:\mysql\bin>mysql -h localhost -u myuser -pmypass
ERROR 1045 (28000): Access denied for user 'myuser'@'localhost' (using password: YES)

Open in new window


Any other ideas?
0
 
LVL 17

Accepted Solution

by:
Anuroopsundd earned 500 total points
ID: 37816579
flush priviledges and then restart MYSQL... then try to login back.
0

Featured Post

Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

Join & Write a Comment

Loading csv or delimited data files to MySQL database is a very common task frequently questioned about and almost every time LOAD DATA INFILE comes to the rescue. Here we will try to understand some of the very common scenarios for loading data …
Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…

708 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

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now