Detailed explanation of Navicat's slow remote connection to MySQL

Detailed explanation of Navicat's slow remote connection to MySQL

The final solution is in the last picture

If you connect to a remote database ( Linux system ) and it is very slow (the specific symptom is that the first connection to open all tables does not seem to be very slow, but after a few minutes, opening any table is very slow, even if the table has very little data), we use the command to find the configuration file (mysql5.7)

sudo vi /etc/my.cnf

At this time, you will generally be prompted to enter a password, so after you enter the password, execute the edit command

sudo vi /etc/my.cnf

Click the insert key on the keyboard to enter the edit mode, find the corresponding position, and add the required configuration (as shown below)

[mysqld]
#Remote connection ignores parsing (just to make it connect faster, the official instructions are there, we just need to know the configuration)
skip-name-resolve
#Set the number of connections (this can be used to modify the maximum number of connections)
max_connections=1000

When you are done, press the Esc key and enter the command to save.

:wq

Use the command to restart the mysql service (you may also need to enter a password, and restart after entering it to make the changes take effect)

systemctl restart mysqld

MySQL executes the following command to see if the maximum number of connections has been modified successfully

show variables like 'max_connections'

Test your database. Of course, the first connection seems to open the table faster, but it is still very busy after a few minutes. Opening a table is as slow as copying the MySQL ancestor's grave. This is when the big move comes in.

Check the box to keep the connection, and change the default 240 to 60 (seconds), or even 30, so that the database can be kept active for several minutes or hours, ready for CRUD at any time.

This is the end of this article about the solution to Navicat's slow remote connection to MySQL (and the database connection error "Too many connections"). For more related content about Navicat's slow remote connection to MySQL, please search 123WORDPRESS.COM's previous articles or continue to browse the following related articles. I hope everyone will support 123WORDPRESS.COM in the future!

You may also be interested in:
  • Solve the problem that Navicat cannot connect to the MySQL server in the Centos system in VMware
  • Perfect solution to the problem that Navicat cannot connect after installing mysql in docker
  • About the problem of Navicat connecting to MySql database slowly
  • Navicat for MySQL 15 Registration and Activation Detailed Tutorial
  • How to remotely connect to MySQL database with Navicat Premium
  • Solve the problem of error 10038 when connecting to MySQL remotely in Navicat
  • Navicat for MySQL 11 Registration Code\Activation Code Summary
  • Navicat Premium operates MySQL database (executes sql statements)
  • Common errors and solutions for connecting Navicat to virtual machine MySQL
  • When Navicat Premium connects to the database, the error message appears: 2003 Can't connect to MySQL server on''localhost''(10061)
  • Detailed explanation of how to create MySql scheduled tasks in navicat
  • Solution to the problem that Navicat cannot remotely connect to MySql server
  • How to use Navicat to operate MySQL

<<:  JavaScript plugin encapsulation for table switching

>>:  How to simply configure multiple servers in nginx

Recommend

How to build svn server in linux

1: Install SVN yum install -y subversion 2. Creat...

About the problem of running git programs in jenkins deployed by docker

1. First, an error message is reported when assoc...

What is this in JavaScript point by point series

Understand this Perhaps you have seen this in oth...

Sending emails in html is easy with Mailto

Recently, I added a click-to-send email function t...

CSS style does not work (the most complete solution summary in history)

When we write pages, we sometimes find that the C...

MySQL column to row conversion tips (share)

Preface: Because many business tables use design ...

Detailed explanation of :key in VUE v-for

When key is not added to the v-for tag. <!DOCT...

Linux method example to view all information of the process

There is a task process on the server. When we us...

Why MySQL chooses Repeatable Read as the default isolation level

Table of contents Oracle Isolation Levels MySQL I...

Steps to modify the MySQL database data file path under Linux

After installing the MySQL database using the rpm...

HTTP header information interpretation and analysis (detailed summary)

HTTP Header Explanation 1. Accept: Tells the web s...

Windows 10 + mysql 8.0.11 zip installation tutorial detailed

Prepare: MySQL 8.0 Windows zip package download a...

JavaScript canvas to achieve mirror image effect

This article shares the specific code for JavaScr...

Summary of MySql index, lock, and transaction knowledge points

This article summarizes the knowledge points of M...

Vue template configuration and webstorm code format specification settings

Table of contents 1. Compiler code format specifi...