From owner-freebsd-hackers@FreeBSD.ORG Mon Aug 31 10:18:58 2009 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0DA46106566C for ; Mon, 31 Aug 2009 10:18:58 +0000 (UTC) (envelope-from brampton@gmail.com) Received: from ey-out-2122.google.com (ey-out-2122.google.com [74.125.78.24]) by mx1.freebsd.org (Postfix) with ESMTP id 9AFEC8FC35 for ; Mon, 31 Aug 2009 10:18:57 +0000 (UTC) Received: by ey-out-2122.google.com with SMTP id 4so995773eyf.9 for ; Mon, 31 Aug 2009 03:18:56 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:sender:received:date :x-google-sender-auth:message-id:subject:from:to:content-type; bh=ihdEnbiM2Gr+pbtDb0OPjBHjNVcude2iM167o1PpaUQ=; b=qiQc3/iUAiWTR6g65C+ypf7rSUGbzUziT+sc7oMtU9ZFwZlhxoryHr8Wr/AKJT4SlY E974KXBldr0pGjNuCNCnSOggLZm4Hg5UcE1DBVARFsAFm0BT0tXnO3vSJphI++BH1SVA SBKy8305k/wsKzKqt4rPojcaXIr/gIm+0IWec= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:date:x-google-sender-auth:message-id:subject :from:to:content-type; b=JmSFdN4o3/q3cC15Tkgpq8prV1EvRCFHfFaUl2BDTciCpPcpyaBIVsHkfkkD8AIpLU YIV+pYVi2Mb6gXBotD4Zv5Z2mFLbiai/b+kOiruoL5jKn/KvzXQudOALAZGkVFa+ElYS NLUh/qa6o9M936+kj32LxKy2WgL6pfCP5Nm78= MIME-Version: 1.0 Sender: brampton@gmail.com Received: by 10.216.11.207 with SMTP id 57mr1105535wex.154.1251713936588; Mon, 31 Aug 2009 03:18:56 -0700 (PDT) Date: Mon, 31 Aug 2009 11:18:56 +0100 X-Google-Sender-Auth: 4c08602bf3e30d9b Message-ID: From: Andrew Brampton To: freebsd-hackers@freebsd.org Content-Type: text/plain; charset=UTF-8 Subject: netstat -i Ierrs column, Is it total, or per second? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 31 Aug 2009 10:18:58 -0000 Hi FreeBSD-Hackers, netstat -i will print out statistics for each interface, including input/output packets, input/output bytes, and input/output errors. Now packets and bytes columns seem to be absolute counts, whereas the errors column seems to be a count over the last second. For example, when I am filling a link (and then stop), I get output like so: Name Mtu Network Address Ipkts Ierrs Opkts Oerrs Coll ix0 9000 00:1b:21:20:f9:07 12687951213 432913 1 0 0 ix0 9000 00:1b:21:20:f9:07 12691545431 435439 1 0 0 ix0 9000 00:1b:21:20:f9:07 12692054413 434735 1 0 0 ix0 9000 00:1b:21:20:f9:07 12696499228 300785 1 0 0 ix0 9000 00:1b:21:20:f9:07 12696499228 0 1 0 0 As you can see the "Ipkts" value continues to rise, but the "Ierrs" goes up and down, eventually falling to zero. So my question is, should this "Ierrs" count be per second?, if so how can I change this behaviour. I looked at the source code for the driver (ixgbe) and the OS, looking for every reference to ifp->if_ierrors, but I didn't find anything that reset this value over time. I also tried a similar experiment with the e1000 driver but I couldn't get that interface to list any errors. I'm running these tests on FreeBSD 8.0-Beta3, but I observed the same behaviour on FreeBSD 7.2. Thanks Andrew