Bug #83996 Execute “select *from host_summary;” failed with " Division by 0"
Submitted: 29 Nov 2016 6:37 Modified: 30 Nov 2016 4:38
Reporter: zte zte Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: SYS Schema Severity:S3 (Non-critical)
Version:5.7.9 OS:Red Hat (6.5)
Assigned to: CPU Architecture:Any

[29 Nov 2016 6:37] zte zte
Description:
It is failed with "ERROR 1365 (22012): Division by 0" when Executing "select *from host_summary\G" 

How to repeat:
Not every time it appears,but when it appears, these steps are done:

mysql> create user root@'%' identified by 'db10$ZTE';
Query OK, 0 rows affected (0.04 sec)

mysql> select *from host_summary\G
ERROR 1365 (22012): Division by 0
[29 Nov 2016 9:21] MySQL Verification Team
Thank you for the bug report. Please try released version 5.7.16 (I couldn't repeat with current source server).
[30 Nov 2016 0:59] zte zte
Thank you for your response.
Maybe it is fixed.I found change log in mysql5.7.14 with "The sys schema host_summary view could fail with a division-by-zero error. (Bug #21970078)"
[30 Nov 2016 4:38] MySQL Verification Team
Thank you for confirming.
Here is the change log entry:

Bug #21970078 SYSSCHEMA.V_HOST_SUMMARY FAILS DUE TO DIVISION BY 0 
Protect from division by 0 in the same way as the user_summary view 
currently uses And merged to mysql-5.7/mysql-trunk server tree within the sys 1.5.1 

From 5.7.14 change log - https://dev.mysql.com/doc/relnotes/mysql/5.7/en/news-5-7-14.html

The sys schema host_summary view could fail with a division-by-zero error. (Bug #21970078)