Description:
https://dev.mysql.com/doc/refman/5.7/en/communication-errors.html talks about some errors such as Aborted connection and Access denied type errors.
The default behaviour with log level 3 is good so that you can see issues of this type, but on busy systems it is quite easy to generate a lot of logging related to these messages. I'm seeing one or more log lines a second on some systems that were quiet with 5.6.
A real life example might be:
2015-10-15T09:15:13.240318Z 18462 [Note] Aborted connection 18462 to db: 'mydb' user: 'app' host: 'app-18.example.com' (Got timeout reading communication packets)
2015-10-15T09:15:13.327814Z 18467 [Note] Aborted connection 18467 to db: 'mydb' user: 'app' host: 'app-29.example.com' (Got timeout reading communication packets)
2015-10-15T09:15:13.770989Z 21938 [Note] Aborted connection 21938 to db: 'unconnected' user: 'check_dba' host: 'localhost' (Got an error reading communication packets)
2015-10-15T09:15:13.790774Z 21937 [Note] Aborted connection 21937 to db: 'unconnected' user: 'check_dba' host: 'localhost' (Got an error reading communication packets)
2015-10-15T09:15:14.986129Z 18478 [Note] Aborted connection 18478 to db: 'mydb' user: 'app' host: 'app-29.example.com' (Got timeout reading communication packets)
2015-10-15T09:15:16.982119Z 18504 [Note] Aborted connection 18504 to db: 'mydb' user: 'app' host: 'app-22.example.com' (Got timeout reading communication packets)
2015-10-15T09:15:17.126796Z 18503 [Note] Aborted connection 18503 to db: 'mydb' user: 'app' host: 'app-09.example.com' (Got timeout reading communication packets)
2015-10-15T09:15:19.002323Z 21973 [Note] Access denied for user 'root'@'localhost' (using password: NO)
2015-10-15T09:15:19.089593Z 18526 [Note] Aborted connection 18526 to db: 'mydb' user: 'app' host: 'app-07.example.com' (Got timeout reading communication packets)
2015-10-15T09:15:20.424670Z 18525 [Note] Aborted connection 18525 to db: 'mydb' user: 'app' host: 'app-14.example.com' (Got timeout reading communication packets)
How to repeat:
Get some applications to talk to MySQL and wait for errors.
There may be a lot of reasons for this type of message.
The point here is that this sort of logging can happen quite frequently and is not under the DBA's control.
11:24:37 [me@myserver ~]$ sudo grep -c Aborted /var/log/mysqld.log
54036
11:25:26 [me@myserver ~]$ sudo head -1 /var/log/mysqld.log
2015-10-15T01:31:02.399506Z 56682 [Note] Aborted connection 56682 to db: 'mydb' user: 'app' host: 'app-02.example.com' (Got timeout reading communication packets)
That's for a period of 8 hours.
Suggested fix:
It's not reasonable to change the global log level for this type of logging from 3 to 2 as it basically makes a lot of other things that you may want to see invisible.
I would like to see a configuration option which allows me to silence these specific (and any other similar) warnings (though they're labelled as Note in the logging) if I want to.
There are counters indicating the number of such events that are happening.
Once I've identified whether I can ignore this I am likely to want to hide them and then just focus on the counters.
If these metrics from the counters change significantly then I might be tempted to "unhide" this type of message and investigate again.
Note: this is a general problem. The famous unsafe replication messages which can be even more verbose also fall in this category. So coming up with a mechanism which might be a little more generic might be useful.