Problem: export the database from the server to SQL and import the local database. Error code: 2006 – MySQL server is offline
Solution:
(1) This problem is due to the default max of MySQL_allowed_Because the packet is too small, you can modify it larger
max_allowed_Packet = 100m
in addition, you can add two parameters to expand the corresponding time
interactive_timeout=28800000
wait_timeout=28800000
(2) View the current configuration
show variables like ‘% max’_allowed_packet%’;
(3) Enter MySQL server and modify the configuration
Run
set global Max on the MySQL command line_allowed_Packet = 2 * 1024 * 1024 * 10 (the parameter can be set larger)
then close the MySQL server link and enter
show VARIABLES like ‘%max_allowed_packet%’;
View Max_allowed_Is the packet edited successfully
(4) Import the data again to solve the problem
Similar Posts:
- Error while sending query packet in PHP runtime
- [Solved] MYSQL:1153 Got a packet bigger than ‘max_allowed_packet’ bytes
- ERROR 2006 (HY000): MySQL server has gone away No
- [Solved] MYSQL:1153 Got a packet bigger than ‘max_allowed_packet’ bytes
- Sqlog recovery database error solution [error code: 2006 – MySQL server has gone away]
- Loading local data is disabled; this must be enabled on both the client and server sides
- Error Code: 2006 – MySQL server has gone away
- MySQL exclude error 1114 holmium HY000 41 holmium“
- [Solved] Windows10 Export Datas to MySQL Error: 2006 – MySQL server has gone away
- MySql Host is blocked because of many connection errors; unblock with ‘mysqladmin flush-hosts…