Common Errors When Using MySQL Programs Another networking issue that can cause this error occurs if the MySQL port (default 3306) is blocked by your firewall, thus preventing any connections at all to the MySQL server. You can check whether the MySQL server died and restarted by executing  mysqladmin version  and examining the server’s uptime. If the client connection was broken because  mysqld  crashed and restarted, you should concentrate on finding the reason for the crash. Start by checking whether issuing the query again kills the server again. See Section B.3.3.3, “What to Do If MySQL Keeps Crashing” . You can obtain more information about lost connections by starting  mysqld  with the log_error_verbosity  system variable set to 3. This logs some of the disconnection messages in the hostname.err  file. See Section 5.4.2, “The Error Log” . If you want to create a bug report regarding this problem, be sure that you include the following information: See also Section B.3.2.9, “Communication Errors and Aborted Connections” , and Section 1.6, “How to Report Bugs or Problems” . A communication packet is a single SQL statement sent to the MySQL server, a single row that is sent to the client, or a binary log event sent from a replication source server to a replica. The largest possible packet that can be transmitted to or from a MySQL 8.0 server or client is 1GB. When a MySQL client or the  mysqld  server receives a packet bigger than  max_allowed_packet  bytes, it issues an  ER_NET_PACKET_TOO_LARGE  error and closes the connection. With some clients, you may also get a  Lost connection to MySQL server during query  error if the communication packet is too large. Both the client and the server have their own  max_allowed_packet  variable, so if you want to handle big packets, you must increase this variable both in the client and in the server. If you are using the  mysql  client program, its default  max_allowed_packet  variable is 16MB. To set a larger value, start  mysql  like this: 5293 B.3.2.8 Packet Too Large •You can also encounter this error with applications that fork child processes, all of which try to use the same connection to the MySQL server. This can be avoided by using a separate connection for each child process. •You have encountered a bug where the server died while executing the query. •Indicate whether the MySQL server died. You can find information about this in the server error log. See Section B.3.3.3, “What to Do If MySQL Keeps Crashing” . •If a specific query kills  mysqld  and the tables involved were checked with  CHECK TABLE  before you ran the query, can you provide a reproducible test case? See Section 5.9, “Debugging MySQL” . •What is the value of the  wait_timeout  system variable in the MySQL server? ( mysqladmin variables  gives you the value of this variable.) •Have you tried to run  mysqld  with the general query log enabled to determine whether the problem query appears in the log? (See Section 5.4.3, “The General Query Log” .) shell>  mysql --max_allowed_packet=32M