NaviCat connection "MySql database does not support remote connection" solution _ MySQL

Source: Internet
Author: User
Tags website server
NaviCat connection "MySql database does not support remote connection" solution Navicat

Some time ago, because of a project, MYSql data synchronization service was required. However, because the website space service provider does not provide remote connection to MYSql, therefore, the NaviCat client cannot be used to connect to the remote server by entering the server address. an SSH connection is found on the internet. However, the connection still fails after testing. Later, after referring to the documents on the Internet, the MYSql database on the server was connected through Http. Record:
First download the latest version of NaviCat from the NaviCat official website (www.NaviCat.com.cn ).

After the installation is complete, open NaviCat, as shown in:

Click Connect in the upper left corner to bring up the new key connection information, as shown in:

Enter LocalHost in the host name IP address

In the username and password column, enter the username and password of your database.

If you cannot connect to the database at this time, you need to connect to the database through the Http channel.

Click Http in the connection property tab, as shown in:

After selecting the Http channel, enter your URL and background file address in the Channel Address column.

Example: http://www.google.cn/database.php

The channel address is described here. the first half is region. Here, Database. php can be renamed based on your preferences. So where can I find this database. php file?

This database. after you click OK to save the connection information, the PHP file is automatically generated under the root directory of the NaviCat file, but it is not a DataBase. the PHP file is named ntunnel_mysql.php, as shown in:

You can rename the file to become the background file of the Http channel that we just connected to the host.

After renaming the file, we use the FlashFxp tool to upload the file to the root directory of our website. Then let's test it and see:

This process is a little slow. because he wants to connect to the website server through the php file and return information, he needs to wait a moment.

Is the MySql database where the website is successfully connected.

Note:

URL: www.google.cn is the virtual URL of the instance.

After configuring the connection information, do not forget to upload the php file under the NaviCat file directory to the root directory of your website.

The PHP file generated by NaviCat uploaded to the root directory of the website must be the same as the file name of your connection information; otherwise, the PHP file cannot be connected.

I am a Cainiao, master, do not laugh

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.