Bug #82727 | Allow DELETE to work on performance_schema.host_cache | ||
---|---|---|---|
Submitted: | 25 Aug 2016 16:07 | Modified: | 5 Apr 2018 6:07 |
Reporter: | Simon Mudd (OCA) | Email Updates: | |
Status: | Verified | Impact on me: | |
Category: | MySQL Server: Performance Schema | Severity: | S4 (Feature request) |
Version: | 5.7.14 | OS: | Any |
Assigned to: | CPU Architecture: | Any | |
Tags: | host_cache, performance_schema |
[25 Aug 2016 16:07]
Simon Mudd
[31 Aug 2016 7:45]
MySQL Verification Team
Hello Simon, Thank you for the feature request! Thanks, Umesh
[14 Sep 2016 17:12]
Simon Mudd
Some more background. On a master, running 111 days I checked the host_cache for consistency and got the following result: WARNING: 349 hostnames from host_cache not found in DNS, 23 host(s) found in p_s.host_cache and hostname from ip is different, 1220 host(s) found in p_s.host_cache and ip address matches Flushing the cache gives me: OK: 229 host(s) found in p_s.host_cache and ip address matches (DNS) So the point being here is that if I use the name in show processlist for something like orchestrator to find a connected slave, the name may be wrong and I may connect to the wrong box, or maybe not connect to any box at all even though the connection is valid and there's a slave connected as indicated by the MySQL server. This also can lead to confusion about client connections for the same reason. Switching off DNS (skip_name_resolve in MySQL) is not possible atm despite several requests to make the change dynamic. That would be a good start, as I can then choose to use DNS or not. Restarting all servers to change such a setting is really intrusive and means that for a long period of time I may have different hosts with different configurations. Not ideal. Better still if I can delete any bad rows in the host_cache then I can ensure I get the benefits of seeing a hostname (which is easier to understand) and not flushing the cache and triggering lots of subsequent dns queries for the next clients that connect. Doing that on one server is one thing. As the number of servers managed grows this can be more problematic. So allowing DELETE on host_cache rows would allow me to fix the problem. Making skip_name_resolve dynamic would also help and be related. I'd prefer both options to allow me to choose my setup. And maybe giving the host_cache entries a TTL would also make them expire cleanly would probably solve the issue too.
[5 Apr 2018 6:03]
Simon Mudd
Related: https://bugs.mysql.com/bug.php?id=90307 (off by 2 error between the max_connect_errors and actual connection attempts processed)
[5 Apr 2018 6:07]
Simon Mudd
Related: https://bugs.mysql.com/bug.php?id=71219 (skip_name_resolve should be dynamic)