From nobody@FreeBSD.org  Wed Jul  2 20:34:16 2008
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 57BEF1065674
	for <freebsd-gnats-submit@FreeBSD.org>; Wed,  2 Jul 2008 20:34:16 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21])
	by mx1.freebsd.org (Postfix) with ESMTP id 45C3C8FC16
	for <freebsd-gnats-submit@FreeBSD.org>; Wed,  2 Jul 2008 20:34:16 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.14.2/8.14.2) with ESMTP id m62KYFlH025593
	for <freebsd-gnats-submit@FreeBSD.org>; Wed, 2 Jul 2008 20:34:15 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.14.2/8.14.1/Submit) id m62KYF98025592;
	Wed, 2 Jul 2008 20:34:15 GMT
	(envelope-from nobody)
Message-Id: <200807022034.m62KYF98025592@www.freebsd.org>
Date: Wed, 2 Jul 2008 20:34:15 GMT
From: Zbigniew Szalbot <z.szalbot@lc-words.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: systat counter resets ever 4GB worth of data
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         125196
>Category:       i386
>Synopsis:       systat(1) counter resets ever 4GB worth of data
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    freebsd-i386
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Wed Jul 02 20:40:04 UTC 2008
>Closed-Date:    Fri Jul 04 08:22:02 UTC 2008
>Last-Modified:  Fri Jul 04 08:22:02 UTC 2008
>Originator:     Zbigniew Szalbot
>Release:        FreeBSD 7.0-RELEASE
>Organization:
SGM Lifewords
>Environment:
$ uname -a
FreeBSD relay.lc-words.com 7.0-RELEASE-p2 FreeBSD 7.0-RELEASE-p2 #1: Mon Jun 30 16:32:34 CEST 2008     zbyszek@relay.lc-words.com:/usr/obj/usr/src/sys/RELAY  i386
>Description:
When I use systat -ifstat, the Total counter gets reset around every 4th GB worth of data. No matter what, the counter will never show more than 4GB. 

                    /0   /1   /2   /3   /4   /5   /6   /7   /8   /9   /10
     Load Average

      Interface           Traffic               Peak                Total
           tun0  in      0.000 KB/s          0.000 KB/s           10.467 MB
                 out     0.000 KB/s          0.000 KB/s          436.847 MB

            lo0  in      0.000 KB/s          0.000 KB/s            2.421 GB
                 out     0.000 KB/s          0.000 KB/s            2.421 GB

            re0  in      1.592 KB/s          1.592 KB/s            1.489 GB
                 out    21.427 KB/s         21.427 KB/s          977.608 MB

A friend of mine tested it on amd64 machine, and it does not happen there. He then tested it on his i386 machine and the Total counter got reset, too. I am not an expert but it seems like a bug.
>How-To-Repeat:
Just watch out the output of systat -ifstat
>Fix:
Sorry, I'd love to but I am in no position to do that. Thanks in advance!

>Release-Note:
>Audit-Trail:
State-Changed-From-To: open->closed 
State-Changed-By: remko 
State-Changed-When: Fri Jul 4 08:20:43 UTC 2008 
State-Changed-Why:  
I dont think this is a bug, but more a feature request, what probably 
happends is that the integer is unsigned and gets maxed out at 4gb. 
The 64bit amd system is running on 64bit counters and the 32bit 
version on 32bit...  

http://www.freebsd.org/cgi/query-pr.cgi?pr=125196 
>Unformatted:
