|
|
612949 |
.\" Hey, EMACS: -*- nroff -*-
|
|
|
612949 |
.\" $Revision: 1.1 $ $Date: 2003/09/06 17:20:17 $
|
|
|
612949 |
.\" First parameter, NAME, should be all caps
|
|
|
612949 |
.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
|
|
|
612949 |
.\" other parameters are allowed: see man(7), man(1)
|
|
|
612949 |
.TH MII-DIAG 8 "September 9, 2003" "Scyld Beowulf\[tm]"
|
|
|
612949 |
.\" Please adjust this date whenever revising the manpage.
|
|
|
612949 |
.\"
|
|
|
612949 |
.\" Some roff macros, for reference:
|
|
|
612949 |
.\" .nh disable hyphenation
|
|
|
612949 |
.\" .hy enable hyphenation
|
|
|
612949 |
.\" .ad l left justify
|
|
|
612949 |
.\" .ad b justify to both left and right margins
|
|
|
612949 |
.\" .nf disable filling
|
|
|
612949 |
.\" .fi enable filling
|
|
|
612949 |
.\" .br insert line break
|
|
|
612949 |
.\" .sp <n> insert n+1 empty lines
|
|
|
612949 |
.\" for manpage-specific macros, see man(7)
|
|
|
612949 |
.SH NAME
|
|
|
612949 |
mii-diag \- Network adapter control and monitoring
|
|
|
612949 |
.SH SYNOPSIS
|
|
|
612949 |
.B mii-diag
|
|
|
612949 |
.RI [ options ] <interface>
|
|
|
612949 |
.SH DESCRIPTION
|
|
|
612949 |
This manual page documents briefly the
|
|
|
612949 |
.B mii-diag
|
|
|
612949 |
network adapter control and monitoring command.
|
|
|
612949 |
Addition documentation is available from http://scyld.com/diag/index.html.
|
|
|
612949 |
|
|
|
612949 |
.\" TeX users may be more comfortable with the \fB<whatever>\fP and
|
|
|
612949 |
.\" \fI<whatever>\fP escape sequences to invoke bold face and italics,
|
|
|
612949 |
.\" respectively.
|
|
|
612949 |
.PP
|
|
|
612949 |
This \fBmii-diag\fP command configures, controls and monitors the
|
|
|
612949 |
transceiver management registers for network interfaces, and configures
|
|
|
612949 |
driver operational parameters. For transceiver control \fBmii-diag\fP
|
|
|
612949 |
uses the Media Independent Interface (MII) standard (thus the command name).
|
|
|
612949 |
It also has additional Linux-specific controls to communicate parameters
|
|
|
612949 |
such as message enable settings and buffer sizes to the underlying device
|
|
|
612949 |
driver.
|
|
|
612949 |
.PP
|
|
|
612949 |
The MII standard defines registers that control and report network
|
|
|
612949 |
transceiver capabilities, link settings and errors. Examples are link
|
|
|
612949 |
speed, duplex, capabilities advertised to the link partner, status LED
|
|
|
612949 |
indications and link error counters.
|
|
|
612949 |
|
|
|
612949 |
.SH OPTIONS
|
|
|
612949 |
The \fBmii-diag\fP command supports both single character and long
|
|
|
612949 |
option names. Short options use a single dash (´-´) in front of the option
|
|
|
612949 |
character. For options without parameters, multiple options may be
|
|
|
612949 |
concatenated after a single dash. Long options are prefixed by two
|
|
|
612949 |
dashes (´--´), and may be abbreviated with a unique prefix.
|
|
|
612949 |
A long option may take a parameter of the form --arg=param or --arg param.
|
|
|
612949 |
|
|
|
612949 |
.PP
|
|
|
612949 |
A summary of options is as follows.
|
|
|
612949 |
|
|
|
612949 |
.TP
|
|
|
612949 |
.B \-A, --advertise <speed|setting>
|
|
|
612949 |
.BR
|
|
|
612949 |
.B \-F, --fixed-speed <speed|setting>
|
|
|
612949 |
|
|
|
612949 |
Speed is one of: 100baseT4, 100baseTx, 100baseTx-FD, 100baseTx-HD, 10baseT,
|
|
|
612949 |
10baseT-FD, 10baseT-HD. For more precise control an explicit numeric
|
|
|
612949 |
register setting is also allowed.
|
|
|
612949 |
|
|
|
612949 |
|
|
|
612949 |
.TP
|
|
|
612949 |
.B \-a, \--all-interfaces
|
|
|
612949 |
Show the status of all interfaces. This option is not recommended with
|
|
|
612949 |
any other option, especially ones that change settings.
|
|
|
612949 |
|
|
|
612949 |
.TP
|
|
|
612949 |
.B \-s,\--status
|
|
|
612949 |
Return exit status 2 if there is no link beat.
|
|
|
612949 |
|
|
|
612949 |
.TP
|
|
|
612949 |
.B \-D
|
|
|
612949 |
Increase the debugging level. This may be used to understand the
|
|
|
612949 |
actions the command is taking.
|
|
|
612949 |
|
|
|
612949 |
.TP
|
|
|
612949 |
.B \-g, \--read-parameters
|
|
|
612949 |
Show driver-specific parameters.
|
|
|
612949 |
|
|
|
612949 |
.TP
|
|
|
612949 |
.B \-G, \--set-parameters value[,value...]
|
|
|
612949 |
Set driver-specific parameters.
|
|
|
612949 |
Set a adapter-specific parameters.
|
|
|
612949 |
Parameters are comma separated, with missing elements retaining the
|
|
|
612949 |
existing value.
|
|
|
612949 |
|
|
|
612949 |
.TP
|
|
|
612949 |
.B \-v
|
|
|
612949 |
Increase the verbosity level. Additional "-v" options increase the
|
|
|
612949 |
level further.
|
|
|
612949 |
|
|
|
612949 |
.TP
|
|
|
612949 |
.B \-V
|
|
|
612949 |
Show the program version information.
|
|
|
612949 |
|
|
|
612949 |
.TP
|
|
|
612949 |
.B \-w, \--watch
|
|
|
612949 |
Continuously monitor the transceiver and report changes.
|
|
|
612949 |
|
|
|
612949 |
.TP
|
|
|
612949 |
.B \-?
|
|
|
612949 |
Emit usage information.
|
|
|
612949 |
|
|
|
612949 |
.SH DESCRIPTION
|
|
|
612949 |
|
|
|
612949 |
.PP
|
|
|
612949 |
Calling the command with just the interface name
|
|
|
612949 |
produces extensive output describing the transceiver
|
|
|
612949 |
capabilities, configuration and current status.
|
|
|
612949 |
|
|
|
612949 |
.PP
|
|
|
612949 |
The '--monitor' option allows scripting link beat changes.
|
|
|
612949 |
.PP
|
|
|
612949 |
This option is similar to --watch, but with lower overhead and simplified
|
|
|
612949 |
output. It polls the interface only once a second and the output format
|
|
|
612949 |
is a single line per link change with three fixed words
|
|
|
612949 |
<unknown|down||negotiating|up> <STATUS> <PARTNER-CAP>
|
|
|
612949 |
.PP
|
|
|
612949 |
Example output: mii-diag --monitor eth0
|
|
|
612949 |
down 0x7809 0x0000
|
|
|
612949 |
negotiating 0x7829 0x45e1
|
|
|
612949 |
up 0x782d 0x45e1
|
|
|
612949 |
down 0x7809 0x0000
|
|
|
612949 |
|
|
|
612949 |
.PP
|
|
|
612949 |
This may be used as
|
|
|
612949 |
mii-diag --monitor eth0 |
|
|
|
612949 |
while read linkstatus bmsr linkpar; do
|
|
|
612949 |
case $linkstatus in
|
|
|
612949 |
up) ifup eth0 ;;
|
|
|
612949 |
down) ifdown eth0 ;;
|
|
|
612949 |
esac
|
|
|
612949 |
done
|
|
|
612949 |
|
|
|
612949 |
.PP
|
|
|
612949 |
It may be useful to shorten the DHCP client daemon timeout if it does
|
|
|
612949 |
not receive an address by adding the following setting to
|
|
|
612949 |
/etc/sysconfig/network:
|
|
|
612949 |
DHCPCDARGS="-t 3"
|
|
|
612949 |
|
|
|
612949 |
.SH SEE ALSO
|
|
|
612949 |
.BR ether-wake (8), net-diag (8), mii-tool (8).
|
|
|
612949 |
.br
|
|
|
612949 |
Addition documentation is available from http://scyld.com/diag/index.html.
|
|
|
612949 |
|
|
|
612949 |
.SH KNOWN BUGS
|
|
|
612949 |
The --all-interfaces option is quirky. There are very few settings that
|
|
|
612949 |
are usefully applied to all interfaces.
|
|
|
612949 |
|
|
|
612949 |
.SH AUTHOR
|
|
|
612949 |
The manual pages, diagnostic commands, and many of the underlying Linux
|
|
|
612949 |
network drivers were written by Donald Becker for the Scyld
|
|
|
612949 |
Beowulf(\*(Tm) cluster system.
|
|
|
612949 |
|