Rechercher dans le manuel MySQL
B.4.2.3 Lost connection to MySQL server
There are three likely causes for this error message.
Usually it indicates network connectivity trouble and you should check the condition of your network if this error occurs frequently. If the error message includes “during query,” this is probably the case you are experiencing.
Sometimes the “during query” form happens when
millions of rows are being sent as part of one or more
queries. If you know that this is happening, you should try
increasing net_read_timeout
from its default of 30 seconds to 60 seconds or longer,
sufficient for the data transfer to complete.
More rarely, it can happen when the client is attempting the
initial connection to the server. In this case, if your
connect_timeout
value is set
to only a few seconds, you may be able to resolve the problem
by increasing it to ten seconds, perhaps more if you have a
very long distance or slow connection. You can determine
whether you are experiencing this more uncommon cause by using
SHOW GLOBAL STATUS LIKE 'Aborted_connects'
.
It will increase by one for each initial connection attempt
that the server aborts. You may see “reading
authorization packet” as part of the error message; if
so, that also suggests that this is the solution that you
need.
If the cause is none of those just described, you may be
experiencing a problem with
BLOB
values that are larger
than max_allowed_packet
,
which can cause this error with some clients. Sometime you may
see an ER_NET_PACKET_TOO_LARGE
error, and that confirms that you need to increase
max_allowed_packet
.
Traduction non disponible
Le manuel MySQL n'est pas encore traduit en français sur l'infobrol. Seule la version anglaise est disponible pour l'instant.
Document créé le 26/06/2006, dernière modification le 26/10/2018
Source du document imprimé : https://www.gaudry.be/mysql-rf-error-lost-connection.html
L'infobrol est un site personnel dont le contenu n'engage que moi. Le texte est mis à disposition sous licence CreativeCommons(BY-NC-SA). Plus d'info sur les conditions d'utilisation et sur l'auteur.
Références
Ces références et liens indiquent des documents consultés lors de la rédaction de cette page, ou qui peuvent apporter un complément d'information, mais les auteurs de ces sources ne peuvent être tenus responsables du contenu de cette page.
L'auteur de ce site est seul responsable de la manière dont sont présentés ici les différents concepts, et des libertés qui sont prises avec les ouvrages de référence. N'oubliez pas que vous devez croiser les informations de sources multiples afin de diminuer les risques d'erreurs.