Debugging em(4) driver

Patrick Mahan mahan at mahan.org
Sun Nov 14 02:35:19 UTC 2010



On 11/13/2010 02:27 PM, Ryan Stone wrote:
> It looks to me that you're getting a ton of input drops.  That's
> presumably the cause of your issue.  You can get the em driver to
> print debug information to the console by running:
>
> # sysctl dev.em.3.stats=1
> # sysctl.dev.em.3.debug=1
>
> The output should be available in dmesg and /var/log/messages
>
> Hopefully that can shed some light on the nature of the drops.

Ryan,

Thanks for the tip.  But I see I forgot to mention this was FreeBSD 8.0.
The em(4) driver is actually the one found in FreeBSD 8.1 as we needed
the AltQ fixes.

However, I do not see these sysctl's in the code or when I do a

'sysctl dev.em.3'

It looks like between 8.0 and 8.1 there was a change?  I now see a if_lem.c
which has the sysctl you are referring too.

Here is the output of my sysctl

npxk3# sysctl dev.em.3.stats=1
sysctl: unknown oid 'dev.em.3.stats'
npxk3# sysctl dev.em.3
dev.em.3.%desc: Intel(R) PRO/1000 Network Connection 7.0.5
dev.em.3.%driver: em
dev.em.3.%location: slot=0 function=1
dev.em.3.%pnpinfo: vendor=0x8086 device=0x10bc subvendor=0x103c subdevice=0x704b 
class=0x020000
dev.em.3.%parent: pci22
dev.em.3.nvm: -1
dev.em.3.rx_int_delay: 0
dev.em.3.tx_int_delay: 66
dev.em.3.rx_abs_int_delay: 66
dev.em.3.tx_abs_int_delay: 66
dev.em.3.rx_processing_limit: 100
dev.em.3.link_irq: 0
dev.em.3.mbuf_alloc_fail: 0
dev.em.3.cluster_alloc_fail: 0
dev.em.3.dropped: 0
dev.em.3.tx_dma_fail: 0
dev.em.3.fc_high_water: 30720
dev.em.3.fc_low_water: 29220
dev.em.3.mac_stats.excess_coll: 0
dev.em.3.mac_stats.symbol_errors: 0
dev.em.3.mac_stats.sequence_errors: 0
dev.em.3.mac_stats.defer_count: 0
dev.em.3.mac_stats.missed_packets: 0
dev.em.3.mac_stats.recv_no_buff: 0
dev.em.3.mac_stats.recv_errs: 0
dev.em.3.mac_stats.crc_errs: 0
dev.em.3.mac_stats.alignment_errs: 0
dev.em.3.mac_stats.coll_ext_errs: 0
dev.em.3.mac_stats.rx_overruns: 0
dev.em.3.mac_stats.watchdog_timeouts: 0
dev.em.3.mac_stats.xon_recvd: 0
dev.em.3.mac_stats.xon_txd: 0
dev.em.3.mac_stats.xoff_recvd: 0
dev.em.3.mac_stats.xoff_txd: 0
dev.em.3.mac_stats.total_pkts_recvd: 58365716
dev.em.3.mac_stats.good_pkts_recvd: 58365716
dev.em.3.mac_stats.bcast_pkts_recvd: 9
dev.em.3.mac_stats.mcast_pkts_recvd: 0
dev.em.3.mac_stats.rx_frames_64: 16
dev.em.3.mac_stats.rx_frames_65_127: 5612
dev.em.3.mac_stats.rx_frames_128_255: 10355
dev.em.3.mac_stats.rx_frames_256_511: 29103556
dev.em.3.mac_stats.rx_frames_512_1023: 6633
dev.em.3.mac_stats.rx_frames_1024_1522: 29239544
dev.em.3.mac_stats.good_octets_recvd: 0
dev.em.3.mac_stats.good_octest_txd: 0
dev.em.3.mac_stats.total_pkts_txd: 165551
dev.em.3.mac_stats.good_pkts_txd: 165551
dev.em.3.mac_stats.bcast_pkts_txd: 8
dev.em.3.mac_stats.mcast_pkts_txd: 2
dev.em.3.mac_stats.tx_frames_64: 19
dev.em.3.mac_stats.tx_frames_65_127: 5573
dev.em.3.mac_stats.tx_frames_128_255: 10348
dev.em.3.mac_stats.tx_frames_256_511: 3308
dev.em.3.mac_stats.tx_frames_512_1023: 6680
dev.em.3.mac_stats.tx_frames_1024_1522: 139623
dev.em.3.mac_stats.tso_txd: 0
dev.em.3.mac_stats.tso_ctx_fail: 0
dev.em.3.interrupts.asserts: 0
dev.em.3.interrupts.rx_pkt_timer: 0
dev.em.3.interrupts.rx_abs_timer: 0
dev.em.3.interrupts.tx_pkt_timer: 0
dev.em.3.interrupts.tx_abs_timer: 0
dev.em.3.interrupts.tx_queue_empty: 0
dev.em.3.interrupts.tx_queue_min_thresh: 0
dev.em.3.interrupts.rx_desc_min_thresh: 0
dev.em.3.interrupts.rx_overrun: 0
dev.em.3.host.breaker_tx_pkt: 0
dev.em.3.host.host_tx_pkt_discard: 0
dev.em.3.host.rx_pkt: 0
dev.em.3.host.breaker_rx_pkts: 0
dev.em.3.host.breaker_rx_pkt_drop: 0
dev.em.3.host.tx_good_pkt: 0
dev.em.3.host.breaker_tx_pkt_drop: 0
dev.em.3.host.rx_good_bytes: 0
dev.em.3.host.tx_good_bytes: 0
dev.em.3.host.length_errors: 0
dev.em.3.host.serdes_violation_pkt: 0
dev.em.3.host.header_redir_missed: 0

Thanks,

Patrick


More information about the freebsd-net mailing list