| 4:45 pm on Aug 23, 2006 (gmt 0)|
That is an "Access denied for user '%s'@'%s' (using password: %s)" message. When you invoke the command line interface (CLI) you need to specify at least the user and password, but often times the host and database as well. Try
mysql -u username -p databasename
You will be prompted for your password as that is what the -p switch is for. You could actually type in your password directly after the switch, but that is bad practice as it is entered into the bash logs where anybody with access to the logs will find your open text password.
More info on the MySQL command line options:
| 4:46 pm on Aug 23, 2006 (gmt 0)|
Something along the lines of:
mysql -h hostname -u user -ppassword databasename
see e.g. [dev.mysql.com...]
| 8:23 pm on Aug 23, 2006 (gmt 0)|
I see. That worked. Now, that works if you're administering an existing database, but lets say that you don't have any databases on your server or that you want to create a new one. Would that be a ssh command?
Just so you know where I'm coming from, I have plesk installed on this server and so far, I've set up all my databases in plesk.
| 8:30 pm on Aug 23, 2006 (gmt 0)|
You need to connect to MySQL as the root user (the MySQL root user, not the Linux root user) and simply "CREATE DATABASE nameofnewdatabase".
| 8:37 pm on Aug 23, 2006 (gmt 0)|
Oh I think I was logging in as an individual database user. Is there a way for me to figure out what the root login for mysql is through SSH? Or would I have to ask my web host? They're not very good at helping with this type of stuff.
| 9:19 pm on Aug 23, 2006 (gmt 0)|
You could try connecting using the Linux root user's password, if you have that - it's possible they're the same; or try connecting without a password - it's possible (horrible thought) that the root user doesn't have a password (simply use "mysql -u root").
Failing that I assume the password must be stored in the Plesk configuration somewhere if Plesk enables you to create databases. (I don't know Plesk so I've no idea where to look).
| 9:29 pm on Aug 23, 2006 (gmt 0)|
plesk has its own login, but it doesn't look like I can administer the mysql root login. I guess I can always just create databases along with corresponding logins in plesk and then mysql them in ssh. Oh well.
Thanks for your help.
| 10:01 pm on Aug 23, 2006 (gmt 0)|
If I remember correctly, plesk rubs out the 'root' user in MySQL and uses a password in /etc/psa/.psa.shadow cat /etc/psa/.psa.shadow will likely show you your password (user is typically 'admin').
| 9:12 pm on Aug 25, 2006 (gmt 0)|