TSO and packets accounting
Navdeep Parhar
np at FreeBSD.org
Sat Mar 25 23:32:40 UTC 2017
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
Regards,
Navdeep
>
> cc0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
> options=ec07bb<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,JUMBO_MTU,VLAN_HWCSUM,TSO4,TSO6,LRO,VLAN_HWTSO,LINKSTATE,RXCSUM_IPV6,TXCSUM_IPV6>
> ether 00:07:43:04:b3:20
> nd6 options=9<PERFORMNUD,IFDISABLED>
> media: Ethernet 40Gbase-SR4 <full-duplex>
> status: active
> cc1: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
> options=ec07bb<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,JUMBO_MTU,VLAN_HWCSUM,TSO4,TSO6,LRO,VLAN_HWTSO,LINKSTATE,RXCSUM_IPV6,TXCSUM_IPV6>
> ether 00:07:43:04:b3:20
> nd6 options=9<PERFORMNUD,IFDISABLED>
> media: Ethernet 40Gbase-SR4 <full-duplex>
> status: active
> lagg0: flags=8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> metric 0 mtu 1500
> options=ec07bb<RXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,JUMBO_MTU,VLAN_HWCSUM,TSO4,TSO6,LRO,VLAN_HWTSO,LINKSTATE,RXCSUM_IPV6,TXCSUM_IPV6>
> ether 00:07:43:04:b3:20
> nd6 options=9<PERFORMNUD,IFDISABLED>
> media: Ethernet autoselect
> status: active
> groups: lagg
> laggproto lacp lagghash l2,l3,l4
> laggport: cc0 flags=1c<ACTIVE,COLLECTING,DISTRIBUTING>
> laggport: cc1 flags=1c<ACTIVE,COLLECTING,DISTRIBUTING>
> _______________________________________________
> freebsd-net at freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-net
> To unsubscribe, send any mail to "freebsd-net-unsubscribe at freebsd.org"
More information about the freebsd-net
mailing list