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:
|
<<: JavaScript plugin encapsulation for table switching
>>: How to simply configure multiple servers in nginx
1: Install SVN yum install -y subversion 2. Creat...
1. First, an error message is reported when assoc...
Understand this Perhaps you have seen this in oth...
Recently, I added a click-to-send email function t...
When we write pages, we sometimes find that the C...
Preface: Because many business tables use design ...
When key is not added to the v-for tag. <!DOCT...
There is a task process on the server. When we us...
Table of contents Oracle Isolation Levels MySQL I...
After installing the MySQL database using the rpm...
HTTP Header Explanation 1. Accept: Tells the web s...
Prepare: MySQL 8.0 Windows zip package download a...
This article shares the specific code for JavaScr...
This article summarizes the knowledge points of M...
Table of contents 1. Compiler code format specifi...