A 1044 and 1045 error occurred when installing Navicat on Mysql

  • 2020-05-14 05:14:28
  • OfStack

in Navicat for MySQL,PostgreSQL and Oracle
The error occurred because the mysql account did not have sufficient permissions to connect to the remote mysql server.
After installing mysql, only "localhost" connection is allowed by default. So most server-side scripts can easily connect to a local database on a local server. The client computer is blocked by the remote server until user privileges are configured.

If you want to access a remote mysql server from your desktop, you first need to know the permissions for the mysql system to work.
User information is stored in the user, db, host, tables_priv, and columns_priv tables with the names "mysql" database. The mysql server reads the contents of these tables when it starts.

MySQL access control involves two phases:
1. The server checks that your desktop (host address or IP address) is allowed to connect.
2. Assuming you can connect, the server checks each request to see if you have enough permissions to execute it. For example, permissions to create a table, delete a table, or modify a table.

The MySQL server accesses the User, Db, and Host tables of the MySQL database in two phases.
If your remote server supports SSH connections, your Navicat will be able to connect to the remote MySQL database through the SSH tunnel without any changes to the existing MySQL permission Settings. The main advantage of the SSH tunnel is that it allows us to connect from behind to the ports of the MySQL server that are blocked by the firewall,

Steps:
You can run the following commands at the command prompt of the MySQL server. Consult your database administrator, as they will usually have the administrative authority to set the permissions.
 
GRANT ALL PRIVILEGES ON *.* TO 'YourUserName'@'%' IDENTIFIED BY "YourPassword"; 

or
 
GRANT ALL PRIVILEGES ON *.* TO 'YourUserName'@'YourIP' IDENTIFIED BY "YourPassword"; 


Related articles: