xgcmd(1M)xgcmd(1M)NAMExgcmd - SGI 10 Gigabit Ethernet configuration and diagnostic tool
SYNOPSIS
/usr/etc/xgcmd subcommand [ xgN ... ]
DESCRIPTIONxgcmd is the diagnostic utility for the SGI 10 Gigabit Ethernet driver
xg(7M). It supports a number of subcommands to interrogate and control
both the driver itself and the XNet interfaces ('xgN') under its control.
Typing xgcmd with no arguments outputs a usage message which lists all of
the available subcommands.
WARNING
Only some of the xgcmd subcommands are documented here. The remaining
(undocumented) subcommands should be executed only under the direction of
Silicon Graphics service personnel - they could adversely affect system
performance or functionality.
OPTIONS
The following subcommands are safe for the user:
xgcmd inventory
Displays a one line summary for each Xframe board found in the
system and recognized by the driver.
# xgcmd inventory
Chip Chip Sybsys Subsys Board
I/F Vendor Device Vendor Device Rev
=== ====== ====== ====== ====== ======
xg1 0x17d5 0x5831 0x10a9 0x8020 0x0000 SGI Xframe Fiber
xg2 0x17d5 0x5831 0x10a9 0x8020 0x0000 SGI Xframe Fiber
xgcmd link_state xgN
Displays current link speed, duplex and flow control setting of the
specified interface.
# xgcmd link_state xg1
xg1 link is UP at 10 Gbps flow_ctrl is ON
xgcmd get_configs xgN
Displays the configuration parameters currently in effect for the
specified interface.
# xgcmd get_configs xg1
tx_fifo_len 4096
tx_fifo_num 1
txd_per_list 10
rx_ring_num 1
rx_block_num 20
(a complete list of parameters may be found in /etc/config/xgcmd.options)
Page 1
xgcmd(1M)xgcmd(1M)xgcmd set_configs xgN <filename>
Parses the config file specified as <filename> and sends the
parameters down to the specified interface. The interface must be
DOWN in order for the parameters to take effect.
Normally, this runs during boot and the config parameters are taken
from /etc/config/xgcmd.options
xgcmd get_cpu xgN
Displays the CPU that the interrupt thread for the specified
interface is running on (if known). If no interrupts have yet
occurred on that interface, the interrupt CPU will not yet be known.
# xgcmd get_cpu xg1
xg1 interrupts are running on CPU 0.
# xgcmd get_cpu xg2
No xg2 interrupts have yet occurred.
xgcmd get_all_stats xgN
Displays statistics for the specified interface. These statistics
are cumulative since the last time the interface was brought up via
ifconfig or since the last time 'xgcmd clear_stats xgN' command was
executed.
These statistics are separated into those collected by the driver
("Driver Statistics") and those collected by the interface hardware
("NIC Statistics").
# xgcmd get_all_stats xg1
xg1: Driver Statistics (Hex):
======================
0 Tx pkts dropped due to link down
1 Mbufs allocated for ethernet headers
1 m_pullups to merge IP and UDP/TCP headers
0 Tx pkts gathered from multiple mbufs
56643 Tx pkt drops due to I/F sendQ full
800 Max Pkts seen on I/F Send Queue
3f6c8f Tx pkts with H/W generated checksum
86d74 Tx pkts with S/W generated checksum
0 Tx path finds H/W not ready
54a7f Tx H/W fifo full
0 Tx pkts with tcp segmentation offloaded to hw
0 Tx pkts with ip segmentation offloaded to hw
8b8931 Interrupts
0 MBuf allocation failures
0 H/W detected bad TCP/UDP checksum
0 Frames rcvd with ERR flag set
0 Rcvd giant frames
3f97c4c Rx pkts with H/W generated checksum
0 Rcvd runt frames
2a079b Rx pkts with S/W generated checksum
Page 2
xgcmd(1M)xgcmd(1M)
e Unused interrupts
8b8923 Device interrupts when device up
3f3e Tx restarted from interrupt
80 Max rx pkts indicated within an interrupt context
dc947 Rx pkts dropped due to full input queue
4cd737 Send lock obtained
1fe6 Send lock busy
1 Rx link utilization mode
0 Tx link utilization mode
0 Rx link utilization
0 Tx link utilization
xg1: MAC Statistics (Hex)
=========================
0 tmac_frms
0 tmac_data_octets
0 tmac_drop_frms
0 tmac_mcst_frms
0 tmac_bcst_frms
0 tmac_pause_ctrl_frms
0 tmac_ttl_octets
0 tmac_ucst_frms
...
(one may also collect only nic stats using "get_nic_stats" and only
driver stats using "get_driver_stats")
xgcmd clear_stats xgN
Clears statistics for the specified interface. To display
statistics which occur only during a specific interval, run 'xgcmd
clear_stats xgN' before the interval and 'xgcmd get_stats xgN' after
the interval.
DIAGNOSTICS
Could not open "/hw/net/if_xframe": open: No such file or directory
All xgcmd subcommands make ioctl calls to the xg driver, via the
"/hw/net/if_xframe" hardware graph node that the driver sets up when it
finds at least one XNet card in the system. This error message most
likely indicates that no XNet cards were recognized by the driver. Use
the hinv(1M) command to verify the presence of XNet cards.
SEE ALSOethernet(7), hinv(1M), ifconfig(1M), network(1M), xg(7M),
Page 3