From owner-freebsd-net@freebsd.org Sat Mar 25 23:48:30 2017 Return-Path: Delivered-To: freebsd-net@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 2984ED1E2F9 for ; Sat, 25 Mar 2017 23:48:30 +0000 (UTC) (envelope-from slw@zxy.spb.ru) Received: from zxy.spb.ru (zxy.spb.ru [195.70.199.98]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id E32521C3B for ; Sat, 25 Mar 2017 23:48:29 +0000 (UTC) (envelope-from slw@zxy.spb.ru) Received: from slw by zxy.spb.ru with local (Exim 4.86 (FreeBSD)) (envelope-from ) id 1crvQ2-0008AT-DF for freebsd-net@FreeBSD.org; Sun, 26 Mar 2017 02:48:26 +0300 Date: Sun, 26 Mar 2017 02:48:26 +0300 From: Slawa Olhovchenkov To: freebsd-net@FreeBSD.org Subject: Re: TSO and packets accounting Message-ID: <20170325234826.GC70430@zxy.spb.ru> References: <20170325223930.GK86500@zxy.spb.ru> <20170325233233.GA17705@ox> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20170325233233.GA17705@ox> User-Agent: Mutt/1.5.24 (2015-08-30) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: slw@zxy.spb.ru X-SA-Exim-Scanned: No (on zxy.spb.ru); SAEximRunCond expanded to false X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 25 Mar 2017 23:48:30 -0000 On Sat, Mar 25, 2017 at 04:32:33PM -0700, Navdeep Parhar wrote: > On Sun, Mar 26, 2017 at 01:39:30AM +0300, Slawa Olhovchenkov wrote: > > How to acoount output packets w/ TSO? > > I mean as one large packet. What I see: > > > > # netstat -nbI lagg0 1 > > input lagg0 output > > packets errs idrops bytes packets errs bytes colls > > 1702715 0 0 122228560 6274492 0 9401968581 0 > > 1623416 0 0 116306353 6035291 0 9045680036 0 > > 1670956 0 0 119911678 6107868 0 9153586152 0 > > 1682365 0 0 120518112 6157620 0 9228163875 0 > > 1575295 0 0 112786199 5831604 0 8736670135 0 > > 1596283 0 0 114404028 5910990 0 8852555094 0 > > 1651946 0 0 118449478 6080815 0 9109251501 0 > > 1661730 0 0 119001512 6152532 0 9219357915 0 > > 1638212 0 0 117502802 6114157 0 9160154253 0 > > 1644270 0 0 117823930 6116968 0 9164984649 0 > > > > 9401968581/6274492 = 1498.44299442887169192342 > > > > TSO not worked? > > Or this is adapted acounting? > > The interfaces are cc(4), so this is adapter accounting. The numbers > you see are coming from hardware MAC statistics that track "on-the-wire" > frames. > > If you want to know if TSO is occurring look for the driver stats for > the number of TSO work requests it has sent to the chip: > # sysctl dev.cc. | grep tso_wrs Thanks