简体   繁体   中英

Accessing MySQL with Toad via SSH

I'm giving Toad a try for use with my MySQL db, but I cannot seem to connect (Linux-based server with MySQL database) remotely using Toad. After entering the right credentials for both SSH login and the database login, I still get this:

'Access denied for user 'wlaprise'@'166.203.5.139' (using password: YES)'

I can however successfully login remotely using SSH and MYSQL commands directly from the command line using the same host and credentials, so I believe the credentials and firewall settings are not the problem. The username is the same for both SSH and the db (not the smartest, I know), so I even tried reversing the password entries in case I had the credentials switched. No difference.

I looked through Toad's 'Connection Properties' to see if it was encrypting my credentials somehow which could explain the 'Access denied' error, but didn't see anything.

This has to be basic, but I don't see what I'm missing? Ideas? Thanks.

When you are using shell command line , then you are connecting from localhost, thus effective permissions are 'wlaprise'@'localhost'

What you can do is to grant permissions to same user, but from different location/IP:

GRANT ALL PRIVILEGES ON *.* TO 'wlaprise'@'166.203.5.139' 
    IDENTIFIED BY PASSWORD 'mypassword';

or

GRANT ALL PRIVILEGES ON *.* TO 'wlaprise'@'%' 
    IDENTIFIED BY PASSWORD 'mypassword';

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM