-1

I am trying to login to MySQL server using *nix shell prompt, following is my command :

$ mysql ********** -east-1.rds.amazonaws.com:3306

(where the asterisks are my ID)

I am getting following error :

Access denied for user ''@'localhost' to database

Should I be specifying a username? If so, a username from where? And the password? I already created Security Groups, but I'm not sure how to relate them to logging onto the server.

Abhijeet Kasurde
  • 983
  • 9
  • 20
Jake Byman
  • 121
  • 3

2 Answers2

2

To connect to a DB instance using the MySQL

Type the following command at a command prompt to connect to a DB instance using the MySQL monitor; substitute the DNS name for your DB instance.

  PROMPT> mysql -h myinstance.mydnsnameexample.rds.amazonaws.com -P 3306 -u mymasteruser -p
0

1)By default, a MySQL installation has an anonymous user,may be Amazon has droped anonymous user

2)in MySQL,localhost,ip,127.0.0.1 are differ,but by default,MySQL login with localhost,you might as well try -h

user192044
  • 66
  • 1