Trying to connect directly to a mysql database using SQLYog

Ok, for those of you that dont use SQLYog (I feel bad for you if your using phpmyadmin crap) it allows you to either connect directly to a mysql database or to connect threw what it calls a tunnel.  Which is basically a php script on the server that the program uses as an interface to the server.  The tunnel works just ducky but sqlyog pro does not support tunnelling and the trial to enterprise ran out.  I already paid 9 bucks for pro and I dont want to pay another 70 for enterprise.  I have a dedicated server with the mysql database on it and I have ssh access, and plesk ofcourse to do whatever I want with the thing.  So I see no reason why I shouldn't be able to connect directly to the mysql server.  I have used my login and password in ssh to log into the mysqladmin interface.  I use the user and password to connect in my php files so I know the user/pass I am trying to use is valid.  When I try to connect in sqlyog it says error # 1045, access denied for bla bla bla, user password (yes).  Same thing I get in ssh if I use a bad user/pass.  This tells me it is communicating with the mysql server because if I put in a bad ip address it just times out.  Like I said I know the user/pass I have is good.  Anyone have any idea what might be causing this?  I've tried refreshing the mysql server but the damn thing tells me I dont have permission.  Which is really weird because my user/pass should have full access to everything because its the account I gave to it in plesk.  I'm not opposed to reinstalling the damn mysql server.  But I tried the other day and got a bit frightened off by all the dependencies it gave.  Plesk gives me like next to no help...  I'm logging into plesk with the admin account and it doesn't let me do much of anything with database.  I can alter my account and change a few preferences but its pretty limited.  Which doesn't surprise me, sometimes I think I would have been better off not getting plesk and just forcing myself to learn all the stuff I need to learn to administer threw ssh.  Well I hope someone can help me with this.
LVL 3
purfusAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

TomeeboyCommented:
When you log in with SSH, you are not logging in to MySQL remotely, it's using your local account to access MySQL.  You need to grant priviledges to your MySQL account for remote access so that it allows your hostname to connect:

grant all privileges on yourdatabase.* to username@'%' identified by 'password'
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
purfusAuthor Commented:
Thanks for the help.  I just tried that and it told me access denied for user...  I'm logged in as root, and logged into mysql with the only username I know to exist on there 'purfus'.
0
purfusAuthor Commented:
Ok I just found the admin account password and got in there and did the query and it said 0 rows affected.
I put in:

grant all privileges on goclans.* to purfus@'%' identified by 'password';
0
Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

purfusAuthor Commented:
i know the database name is correct and the username is also correct.
0
purfusAuthor Commented:
mysql> SELECT Host, User, password FROM mysql.user;
+-----------+--------+------------------+
| Host      | User   | password         |
+-----------+--------+------------------+
| localhost | admin  | ************** |
| localhost | horde  | ************** |
| localhost | purfus | ************** |
| %         | horde  |                  |
| %         | purfus | ************** |
+-----------+--------+------------------+
5 rows in set (0.00 sec)

0
purfusAuthor Commented:
I think it is doing it despite what it says because I did the privilege query on admin and did a select statement and got this, which now has the admin account in a % as well.


mysql> SELECT Host, User, password FROM mysql.user;                             +-----------+--------+------------------+
| Host      | User   | password         |
+-----------+--------+------------------+
| localhost | admin  | ************** |
| localhost | horde  | ************** |
| localhost | purfus | ************** |
| %         | horde  |                  |
| %         | purfus | ************** |
| %         | admin  | ************** |
+-----------+--------+------------------+
6 rows in set (0.00 sec)
0
purfusAuthor Commented:
I did a FLUSH PRIVILEGES and tried to login in and recieved the same results.
0
purfusAuthor Commented:
DOH, I got it WEEEE  Thank you soo much.  The problem I was having was I was putting in password instead of my password thinking it was reffering to a column name.  Only reason I noticed was the password in the select was a different hash value.  lol...  Well thank you, you've solved my problem.
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Web Development

From novice to tech pro — start learning today.