Bug #43040 Bytes_sent gives negetive number
Submitted: 20 Feb 3:40 Modified: 25 Feb 3:59
Reporter: Ligaya Turmelle
Status: Duplicate
Category:Server: Logging Severity:S3 (Non-critical)
Version:5.0.60, 5.0, 5.1, 6.0 bzr OS:Linux
Assigned to: Target Version:
Triage: Needs Triage: D3 (Medium)

[20 Feb 3:40] Ligaya Turmelle
Description:
When closely monitoring the value of Bytes_sent (values taken every 5 seconds) noticed
the value suddenly jump up 4GB and then soon after jump *down* 4 GB.  

- At 14:01:38 the total Mb sent in 5 seconds went to 4,342 Mb. The total bytes sent went
from 2,503,034,967,866 to 2,507,377,258,205.

- At 14:03:56 the total Mb sent in 5 seconds went to a NEGATIVE number of 4,250 Mb. The
total byte sent went from 2,508,255,848,844 to 2,504,005,106,958

Since the value jumps up and down are around 2^32, it may be associated with the fix from
http://bugs.mysql.com/bug.php?id=28149, potentially a race condition or similar from the
bug fix. 

Script used to see the changes:
mysql -u user -p pwd -h dbserver db -e "show global status;" | grep Bytes >>
byteCheck.log
sleep 5
done;

Will upload supporting information files.

How to repeat:
n/a
[21 Feb 10:10] Sveta Smirnova
Thank you for the report.

Verified as described:

./sql/net_serv.cc still contains extern ulong bytes_sent, bytes_received,
net_big_packet_count; which is used, for example, by update_statistics
[25 Feb 3:59] Omer BarNir
duplicate of bug#42698