diff options
Diffstat (limited to 'usr/src/man/man1m/netstat.1m')
-rw-r--r-- | usr/src/man/man1m/netstat.1m | 1241 |
1 files changed, 1241 insertions, 0 deletions
diff --git a/usr/src/man/man1m/netstat.1m b/usr/src/man/man1m/netstat.1m new file mode 100644 index 0000000000..5859adea18 --- /dev/null +++ b/usr/src/man/man1m/netstat.1m @@ -0,0 +1,1241 @@ +'\" te +.\" Copyright (C) 2002, Sun Microsystems, Inc. All Rights Reserved +.\" Copyright 1989 AT&T +.\" Copyright (c) 1983 Regents of the University of California. All rights reserved. The Berkeley software License Agreement specifies the terms and conditions for redistribution. +.TH netstat 1M "16 Jun 2009" "SunOS 5.11" "System Administration Commands" +.SH NAME +netstat \- show network status +.SH SYNOPSIS +.LP +.nf +\fBnetstat\fR [\fB-anvR\fR] [\fB-f\fR \fIaddress_family\fR] [\fB-P\fR \fIprotocol\fR] +.fi + +.LP +.nf +\fBnetstat\fR \fB-g\fR [\fB-nv\fR] [\fB-f\fR \fIaddress_family\fR] +.fi + +.LP +.nf +\fBnetstat\fR \fB-p\fR [\fB-n\fR] [\fB-f\fR \fIaddress_family\fR] +.fi + +.LP +.nf +\fBnetstat\fR \fB-s\fR [\fB-f\fR \fIaddress_family\fR] [\fB-P\fR \fIprotocol\fR] + [\fB-T\fR u | d ] [\fIinterval\fR [\fIcount\fR]] +.fi + +.LP +.nf +\fBnetstat\fR \fB-m\fR [\fB-T\fR u | d ] [\fB-v\fR] [\fIinterval\fR [\fIcount\fR]] +.fi + +.LP +.nf +\fBnetstat\fR \fB-i\fR [\fB-I\fR \fIinterface\fR] [\fB-an\fR] [\fB-f\fR \fIaddress_family\fR] + [\fB-T\fR u | d ] [\fIinterval\fR [\fIcount\fR]] +.fi + +.LP +.nf +\fBnetstat\fR \fB-r\fR [\fB-anvR\fR] [\fB-f\fR \fIaddress_family\fR | \fIfilter\fR] +.fi + +.LP +.nf +\fBnetstat\fR \fB-M\fR [\fB-ns\fR] [\fB-f\fR \fIaddress_family\fR] +.fi + +.LP +.nf +\fBnetstat\fR \fB-D\fR [\fB-I\fR \fIinterface\fR] [\fB-f\fR \fIaddress_family\fR] +.fi + +.SH DESCRIPTION +.sp +.LP +The \fBnetstat\fR command displays the contents of certain network-related data +structures in various formats, depending on the options you select. +.sp +.LP +The \fBnetstat\fR command has the several forms shown in the SYNOPSIS section, +above, listed as follows: +.RS +4 +.TP +.ie t \(bu +.el o +The first form of the command (with no required arguments) displays a list of +active sockets for each protocol. +.RE +.RS +4 +.TP +.ie t \(bu +.el o +The second, third, and fourth forms (\fB-g\fR, \fB-p\fR, and \fB-s\fR options) +display information from various network data structures. +.RE +.RS +4 +.TP +.ie t \(bu +.el o +The fifth form (\fB-m\fR option) displays STREAMS memory statistics. +.RE +.RS +4 +.TP +.ie t \(bu +.el o +The sixth form (\fB-i\fR option) shows the state of the interfaces. +.RE +.RS +4 +.TP +.ie t \(bu +.el o +The seventh form (\fB-r\fR option) displays the routing table. +.RE +.RS +4 +.TP +.ie t \(bu +.el o +The eighth form (\fB-M\fR option) displays the multicast routing table. +.RE +.RS +4 +.TP +.ie t \(bu +.el o +The ninth form (\fB-D\fR option) displays the state of \fBDHCP\fR on one or all +interfaces. +.RE +.sp +.LP +These forms are described in greater detail below. +.sp +.LP +With no arguments (the first form), \fBnetstat\fR displays connected sockets +for \fBPF_INET\fR, \fBPF_INET6\fR, and \fBPF_UNIX\fR, unless modified otherwise +by the \fB-f\fR option. +.SH OPTIONS +.sp +.ne 2 +.mk +.na +\fB\fB-a\fR\fR +.ad +.sp .6 +.RS 4n +Show the state of all sockets, all routing table entries, or all interfaces, +both physical and logical. Normally, listener sockets used by server processes +are not shown. Under most conditions, only interface, host, network, and +default routes are shown and only the status of physical interfaces is shown. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-f\fR \fIaddress_family\fR\fR +.ad +.sp .6 +.RS 4n +Limit all displays to those of the specified \fIaddress_family\fR. The value of +\fIaddress_family\fR can be one of the following: +.sp +.ne 2 +.mk +.na +\fB\fBinet\fR\fR +.ad +.RS 9n +.rt +For the \fBAF_INET\fR address family showing IPv4 information. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBinet6\fR\fR +.ad +.RS 9n +.rt +For the \fBAF_INET6\fR address family showing IPv6 information. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBunix\fR\fR +.ad +.RS 9n +.rt +For the \fBAF_UNIX\fR address family. +.RE + +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-f\fR \fIfilter\fR\fR +.ad +.sp .6 +.RS 4n +With \fB-r\fR only, limit the display of routes to those matching the specified +filter. A filter rule consists of a \fIkeyword\fR:\fIvalue\fR pair. The known +keywords and the value syntax are: +.sp +.ne 2 +.mk +.na +\fB\fBaf:\fR{\fBinet\fR|\fBinet6\fR|\fBunix\fR|\fInumber\fR}\fR +.ad +.sp .6 +.RS 4n +Selects an address family. This is identical to \fB-f\fR \fIaddress_family\fR +and both syntaxes are supported. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBoutif\fR:{\fIname\fR|\fIifIndex\fR|\fBany\fR|\fBnone\fR}\fR +.ad +.sp .6 +.RS 4n +Selects an output interface. You can specify the interface by name (such as +\fBhme0\fR) or by \fBifIndex\fR number (for example, \fB2\fR). If \fBany\fR is +used, the filter matches all routes having a specified interface (anything +other than null). If \fBnone\fR is used, the filter matches all routes having a +null interface. Note that you can view the index number (\fIifIndex\fR) for an +interface with the \fB-a\fR option of \fBifconfig\fR(1M). +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBdst\fR:{\fIip-address\fR[/\fImask\fR]|\fBany\fR|\fBnone\fR}\fR +.ad +.sp .6 +.RS 4n +Selects a destination IP address. If specified with a mask length, then any +routes with matching or longer (more specific) masks are selected. If \fBany\fR +is used, then all but addresses but 0 are selected. If \fBnone\fR is used, then +address 0 is selected. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBflags:\fR[\fB+ -\fR]?[\fBABDGHLMSU\fR]\fB+\fR\fR +.ad +.sp .6 +.RS 4n +Selects routes tagged with the specified flags. By default, the flags as +specified must be set in order to match. With a leading \fB+\fR, the flags +specified must be set but others are ignored. With a leading \fB-\fR, the flags +specified must not be set and others are permitted. +.RE + +You can specify multiple instances of \fB-f\fR to specify multiple filters. For +example: +.sp +.in +2 +.nf +% netstat -nr -f outif:hme0 -f outif:hme1 -f dst:10.0.0.0/8 +.fi +.in -2 +.sp + +The preceding command displays routes within network 10.0.0.0/8, with mask +length 8 or greater, and an output interface of either \fBhme0\fR or +\fBhme1\fR, and excludes all other routes. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-g\fR\fR +.ad +.sp .6 +.RS 4n +Show the multicast group memberships for all interfaces. If the \fB-v\fR option +is included, source-specific membership information is also displayed. See +DISPLAYS, below. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-i\fR\fR +.ad +.sp .6 +.RS 4n +Show the state of the interfaces that are used for \fBIP\fR traffic. Normally +this shows statistics for the physical interfaces. When combined with the +\fB-a\fR option, this will also report information for the logical interfaces. +See \fBifconfig\fR(1M). +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-m\fR\fR +.ad +.sp .6 +.RS 4n +Show the STREAMS memory statistics. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-n\fR\fR +.ad +.sp .6 +.RS 4n +Show network addresses as numbers. \fBnetstat\fR normally displays addresses as +symbols. This option may be used with any of the display formats. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-p\fR\fR +.ad +.sp .6 +.RS 4n +Show the net to media tables. See DISPLAYS, below. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-r\fR\fR +.ad +.sp .6 +.RS 4n +Show the routing tables. Normally, only interface, host, network, and default +routes are shown, but when this option is combined with the \fB-a\fR option, +all routes will be displayed, including cache. If you have not set up a +multicast route, \fB-ra\fR might not show any multicast routing entries, +although the kernel will derive such an entry if needed. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-s\fR\fR +.ad +.sp .6 +.RS 4n +Show per-protocol statistics. When used with the \fB-M\fR option, show +multicast routing statistics instead. When used with the \fB-a\fR option, +per-interface statistics will be displayed, when available, in addition to +statistics global to the system. See DISPLAYS, below. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-T\fR \fBu\fR | \fBd\fR\fR +.ad +.sp .6 +.RS 4n +Display a time stamp. +.sp +Specify \fBu\fR for a printed representation of the internal representation of +time. See \fBtime\fR(2). Specify \fBd\fR for standard date format. See +\fBdate\fR(1). +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-v\fR\fR +.ad +.sp .6 +.RS 4n +Verbose. Show additional information for the sockets, STREAMS memory +statistics, routing table, and multicast group memberships. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-I\fR \fIinterface\fR\fR +.ad +.sp .6 +.RS 4n +Show the state of a particular interface. \fIinterface\fR can be any valid +interface such as \fBhme0\fR or \fBeri0\fR. Normally, the status and statistics +for physical interfaces are displayed. When this option is combined with the +\fB-a\fR option, information for the logical interfaces is also reported. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-M\fR\fR +.ad +.sp .6 +.RS 4n +Show the multicast routing tables. When used with the \fB-s\fR option, show +multicast routing statistics instead. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-P\fR \fIprotocol\fR\fR +.ad +.sp .6 +.RS 4n +Limit display of statistics or state of all sockets to those applicable to +\fIprotocol\fR. The protocol can be one of \fBip\fR, \fBipv6\fR, \fBicmp\fR, +\fBicmpv6\fR, \fBicmp\fR, \fBicmpv6\fR, \fBigmp\fR, \fBudp\fR, \fBtcp\fR, +\fBrawip\fR. \fBrawip\fR can also be specified as \fBraw\fR. The command +accepts protocol options only as all lowercase. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-D\fR\fR +.ad +.sp .6 +.RS 4n +Show the status of \fBDHCP\fR configured interfaces. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-R\fR\fR +.ad +.sp .6 +.RS 4n +This modifier displays extended security attributes for sockets and routing +table entries. The \fB-R\fR modifier is available only if the system is +configured with the Solaris Trusted Extensions feature. +.sp +With \fB-r\fR only, this option displays the routing entries' gateway security +attributes. See \fBroute\fR(1M) for more information on security attributes. +.sp +When displaying socket information using the first form of the commmand, this +option displays additional information for Multi-Level Port(MLP) sockets. This +includes: +.RS +4 +.TP +.ie t \(bu +.el o +The label for the peer if the socket is connected. +.RE +.RS +4 +.TP +.ie t \(bu +.el o +The following flags can be appended to the socket's "State" output: +.RS + +.sp +.ne 2 +.mk +.na +\fB\fBP\fR\fR +.ad +.RS 5n +.rt +The socket is a MLP on zone-private IP addresses. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBS\fR\fR +.ad +.RS 5n +.rt +The socket is a MLP on IP addresses shared between zones. +.RE + +.RE + +.RE +.RE + +.SH OPERANDS +.sp +.ne 2 +.mk +.na +\fB\fIinterval\fR\fR +.ad +.RS 12n +.rt +Display statistics accumulated since last display every \fIinterval\fR seconds, +repeating forever, unless \fIcount\fR is specified. When invoked with +\fIinterval\fR, the first row of netstat output shows statistics accumulated +since last reboot. +.sp +The following options support \fIinterval\fR: \fB-i\fR, \fB-m\fR, \fB-s\fR and +\fB-Ms\fR. Some values are configuration parameters and are just redisplayed at +each interval. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fIcount\fR\fR +.ad +.RS 12n +.rt +Display interface statistics the number of times specified by \fIcount\fR, at +the interval specified by \fIinterval\fR. +.RE + +.SH DISPLAYS +.SS "Active Sockets (First Form)" +.sp +.LP +The display for each active socket shows the local and remote address, the send +and receive queue sizes (in bytes), the send and receive windows (in bytes), +and the internal state of the protocol. +.sp +.LP +The symbolic format normally used to display socket addresses is either: +.sp +.in +2 +.nf +\fBhostname\fR.\fIport\fR +.fi +.in -2 +.sp + +.sp +.LP +when the name of the host is specified, or +.sp +.in +2 +.nf +\fInetwork\fR.\fIport\fR +.fi +.in -2 +.sp + +.sp +.LP +if a socket address specifies a network but no specific host. +.sp +.LP +The numeric host address or network number associated with the socket is used +to look up the corresponding symbolic hostname or network name in the +\fIhosts\fR or \fInetworks\fR database. +.sp +.LP +If the network or hostname for an address is not known, or if the \fB-n\fR +option is specified, the numerical network address is shown. Unspecified, or +"wildcard", addresses and ports appear as an asterisk (\fB*\fR). For more +information regarding the Internet naming conventions, refer to \fBinet\fR(7P) +and \fBinet6\fR(7P). +.sp +.LP +For SCTP sockets, because an endpoint can be represented by multiple addresses, +the verbose option (\fB-v\fR) displays the list of all the local and remote +addresses. +.SS "\fITCP Sockets\fR" +.sp +.LP +The possible state values for \fBTCP\fR sockets are as follows: +.sp +.ne 2 +.mk +.na +\fB\fBBOUND\fR\fR +.ad +.RS 16n +.rt +Bound, ready to connect or listen. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBCLOSED\fR\fR +.ad +.RS 16n +.rt +Closed. The socket is not being used. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBCLOSING\fR\fR +.ad +.RS 16n +.rt +Closed, then remote shutdown; awaiting acknowledgment. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBCLOSE_WAIT\fR\fR +.ad +.RS 16n +.rt +Remote shutdown; waiting for the socket to close. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBESTABLISHED\fR\fR +.ad +.RS 16n +.rt +Connection has been established. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBFIN_WAIT_1\fR\fR +.ad +.RS 16n +.rt +Socket closed; shutting down connection. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBFIN_WAIT_2\fR\fR +.ad +.RS 16n +.rt +Socket closed; waiting for shutdown from remote. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBIDLE\fR\fR +.ad +.RS 16n +.rt +Idle, opened but not bound. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBLAST_ACK\fR\fR +.ad +.RS 16n +.rt +Remote shutdown, then closed; awaiting acknowledgment. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBLISTEN\fR\fR +.ad +.RS 16n +.rt +Listening for incoming connections. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBSYN_RECEIVED\fR\fR +.ad +.RS 16n +.rt +Initial synchronization of the connection under way. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBSYN_SENT\fR\fR +.ad +.RS 16n +.rt +Actively trying to establish connection. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBTIME_WAIT\fR\fR +.ad +.RS 16n +.rt +Wait after close for remote shutdown retransmission. +.RE + +.SS "\fISCTP Sockets\fR" +.sp +.LP +The possible state values for SCTP sockets are as follows: +.sp +.ne 2 +.mk +.na +\fB\fBCLOSED\fR\fR +.ad +.RS 21n +.rt +Closed. The socket is not being used. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBLISTEN\fR\fR +.ad +.RS 21n +.rt +Listening for incoming associations. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBESTABLISHED\fR\fR +.ad +.RS 21n +.rt +Association has been established. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBCOOKIE_WAIT\fR\fR +.ad +.RS 21n +.rt +\fBINIT\fR has been sent to the peer, awaiting acknowledgment. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBCOOKIE_ECHOED\fR\fR +.ad +.RS 21n +.rt +State cookie from the INIT-ACK has been sent to the peer, awaiting +acknowledgement. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBSHUTDOWN_PENDING\fR\fR +.ad +.RS 21n +.rt +\fBSHUTDOWN\fR has been received from the upper layer, awaiting acknowledgement +of all outstanding \fBDATA\fR from the peer. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBSHUTDOWN_SENT\fR\fR +.ad +.RS 21n +.rt +All outstanding data has been acknowledged in the \fBSHUTDOWN_SENT\fR state. +\fBSHUTDOWN\fR has been sent to the peer, awaiting acknowledgement. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBSHUTDOWN_RECEIVED\fR\fR +.ad +.RS 21n +.rt +\fBSHUTDOWN\fR has been received from the peer, awaiting acknowledgement of all +outstanding \fBDATA\fR. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBSHUTDOWN_ACK_SENT\fR\fR +.ad +.RS 21n +.rt +All outstanding data has been acknowledged in the \fBSHUTDOWN_RECEIVED\fR +state. \fBSHUTDOWN_ACK\fR has been sent to the peer. +.RE + +.SS "Network Data Structures (Second Through Fifth Forms)" +.sp +.LP +The form of the display depends upon which of the \fB-g\fR, \fB-m\fR, \fB-p\fR, +or \fB-s\fR options you select. +.sp +.ne 2 +.mk +.na +\fB\fB-g\fR\fR +.ad +.RS 6n +.rt +Displays the list of multicast group membership. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-m\fR\fR +.ad +.RS 6n +.rt +Displays the memory usage, for example, STREAMS mblks. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-p\fR\fR +.ad +.RS 6n +.rt +Displays the net to media mapping table. For IPv4, the address resolution table +is displayed. See \fBarp\fR(1M). For IPv6, the neighbor cache is displayed. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fB-s\fR\fR +.ad +.RS 6n +.rt +Displays the statistics for the various protocol layers. +.RE + +.sp +.LP +The statistics use the MIB specified variables. The defined values for +\fBipForwarding\fR are: +.sp +.ne 2 +.mk +.na +\fB\fBforwarding(1)\fR\fR +.ad +.RS 21n +.rt +Acting as a gateway. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBnot-forwarding(2)\fR\fR +.ad +.RS 21n +.rt +Not acting as a gateway. +.RE + +.sp +.LP +The IPv6 and ICMPv6 protocol layers maintain per-interface statistics. If the +\fB-a\fR option is specified with the \fB-s\fR option, then the per-interface +statistics as well as the total sums are displayed. Otherwise, just the sum of +the statistics are shown. +.sp +.LP +For the second, third, and fourth forms of the command, you must specify at +least \fB-g\fR, \fB-p\fR, or \fB-s\fR. You can specify any combination of these +options. You can also specify \fB-m\fR (the fifth form) with any set of the +\fB-g\fR, \fB-p\fR, and \fB-s\fR options. If you specify more than one of these +options, \fBnetstat\fR displays the information for each one of them. +.SS "Interface Status (Sixth Form)" +.sp +.LP +The interface status display lists information for all current interfaces, one +interface per line. If an interface is specified using the \fB-I\fR option, it +displays information for only the specified interface. +.sp +.LP +The list consists of the interface name, \fBmtu\fR (maximum transmission unit, +or maximum packet size)(see \fBifconfig\fR(1M)), the network to which the +interface is attached, addresses for each interface, and counter associated +with the interface. The counters show the number of input packets, input +errors, output packets, output errors, and collisions, respectively. For +Point-to-Point interfaces, the Net/Dest field is the name or address on the +other side of the link. +.sp +.LP +If the \fB-a\fR option is specified with either the \fB-i\fR option or the +\fB-I\fR option, then the output includes names of the physical interface(s), +counts for input packets and output packets for each logical interface, plus +additional information. +.sp +.LP +If the \fB-n\fR option is specified, the list displays the IP address instead +of the interface name. +.sp +.LP +If an optional \fIinterval\fR is specified, the output will be continually +displayed in \fIinterval\fR seconds until interrupted by the user or until +\fIcount\fR is reached. See OPERANDS. +.sp +.LP +The physical interface is specified using the \fB-I\fR option. When used with +the \fIinterval\fR operand, output for the \fB-I\fR option has the following +format: +.sp +.in +2 +.nf +input eri0 output input (Total) output +packets errs packets errs colls packets errs packets errs colls +227681 0 659471 1 502 261331 0 99597 1 502 +10 0 0 0 0 10 0 0 0 0 +8 0 0 0 0 8 0 0 0 0 +10 0 2 0 0 10 0 2 0 0 +.fi +.in -2 +.sp + +.sp +.LP +If the input interface is not specified, the first interface of address family +\fBinet\fR or \fBinet6\fR will be displayed. +.SS "Routing Table (Seventh Form)" +.sp +.LP +The routing table display lists the available routes and the status of each. +Each route consists of a destination host or network, and a gateway to use in +forwarding packets. The \fIflags\fR column shows the status of the route. These +flags are as follows: +.sp +.ne 2 +.mk +.na +\fB\fBU\fR\fR +.ad +.RS 5n +.rt +Indicates route is \fBup\fR. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBG\fR\fR +.ad +.RS 5n +.rt +Route is to a gateway. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBH\fR\fR +.ad +.RS 5n +.rt +Route is to a host and not a network. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBM\fR\fR +.ad +.RS 5n +.rt +Redundant route established with the \fB-multirt\fR option. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBS\fR\fR +.ad +.RS 5n +.rt +Route was established using the \fB-setsrc\fR option. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBD\fR\fR +.ad +.RS 5n +.rt +Route was created dynamically by a redirect. +.RE + +.sp +.LP +If the \fB-a\fR option is specified, there will be routing entries with the +following flags: +.sp +.ne 2 +.mk +.na +\fB\fBA\fR\fR +.ad +.RS 5n +.rt +Combined routing and address resolution entries. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBB\fR\fR +.ad +.RS 5n +.rt +Broadcast addresses. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBL\fR\fR +.ad +.RS 5n +.rt +Local addresses for the host. +.RE + +.sp +.LP +Interface routes are created for each interface attached to the local host; the +gateway field for such entries shows the address of the outgoing interface. +.sp +.LP +The \fBuse\fR column displays the number of packets sent using a combined +routing and address resolution (\fBA\fR) or a broadcast (\fBB\fR) route. For a +local (\fBL\fR) route, this count is the number of packets received, and for +all other routes it is the number of times the routing entry has been used to +create a new combined route and address resolution entry. +.sp +.LP +The \fIinterface\fR entry indicates the network interface utilized for the +route. +.SS "Multicast Routing Tables (Eighth Form)" +.sp +.LP +The multicast routing table consists of the virtual interface table and the +actual routing table. +.SS "DHCP Interface Information (Ninth Form)" +.sp +.LP +The \fBDHCP\fR interface information consists of the interface name, its +current state, lease information, packet counts, and a list of flags. +.sp +.LP +The states correlate with the specifications set forth in \fIRFC 2131\fR. +.sp +.LP +Lease information includes: +.RS +4 +.TP +.ie t \(bu +.el o +when the lease began; +.RE +.RS +4 +.TP +.ie t \(bu +.el o +when lease renewal will begin; and +.RE +.RS +4 +.TP +.ie t \(bu +.el o +when the lease will expire. +.RE +.sp +.LP +The flags currently defined include: +.sp +.ne 2 +.mk +.na +\fB\fBBOOTP\fR\fR +.ad +.RS 11n +.rt +The interface has a lease obtained through \fBBOOTP\fR (IPv4 only). +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBBUSY\fR\fR +.ad +.RS 11n +.rt +The interface is busy with a \fBDHCP\fR transaction. +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBPRIMARY\fR\fR +.ad +.RS 11n +.rt +The interface is the primary interface. See \fBdhcpinfo\fR(1) and +\fBifconfig\fR(1M). +.RE + +.sp +.ne 2 +.mk +.na +\fB\fBFAILED\fR\fR +.ad +.RS 11n +.rt +The interface is in failure state and must be manually restarted. +.RE + +.sp +.LP +Packet counts are maintained for the number of packets sent, the number of +packets received, and the number of lease offers declined by the \fBDHCP\fR +client. All three counters are initialized to zero and then incremented while +obtaining a lease. The counters are reset when the period of lease renewal +begins for the interface. Thus, the counters represent either the number of +packets sent, received, and declined while obtaining the current lease, or the +number of packets sent, received, and declined while attempting to obtain a +future lease. +.SH FILES +.sp +.ne 2 +.mk +.na +\fB\fB/etc/default/inet_type\fR\fR +.ad +.RS 26n +.rt +\fBDEFAULT_IP\fR setting +.RE + +.SH SEE ALSO +.sp +.LP +\fBarp\fR(1M), \fBdhcpinfo\fR(1), \fBdhcpagent\fR(1M), \fBifconfig\fR(1M), +\fBiostat\fR(1M), \fBkstat\fR(1M), \fBmibiisa\fR(1M), \fBsavecore\fR(1M), +\fBvmstat\fR(1M), \fBhosts\fR(4), \fBinet_type\fR(4), \fBnetworks\fR(4), +\fBprotocols\fR(4), \fBservices\fR(4), \fBattributes\fR(5), \fBdhcp\fR(5), +\fBkstat\fR(7D), \fBinet\fR(7P), \fBinet6\fR(7P) +.sp +.LP +Droms, R., \fIRFC 2131, Dynamic Host Configuration Protocol\fR, Network Working +Group, March 1997. +.sp +.LP +Droms, R. \fIRFC 3315, Dynamic Host Configuration Protocol for IPv6 +(DHCPv6)\fR. Cisco Systems. July 2003. +.SH NOTES +.sp +.LP +When displaying interface information, \fBnetstat\fR honors the +\fBDEFAULT_IP\fR setting in \fB/etc/default/inet_type\fR. If it is set to +\fBIP_VERSION4\fR, then \fBnetstat\fR will omit information relating to IPv6 +interfaces, statistics, connections, routes and the like. +.sp +.LP +However, you can override the \fBDEFAULT_IP\fR setting in +\fB/etc/default/inet_type\fR on the command-line. For example, if you have used +the command-line to explicitly request IPv6 information by using the +\fBinet6\fR address family or one of the IPv6 protocols, it will override the +\fBDEFAULT_IP\fR setting. +.sp +.LP +If you need to examine network status information following a kernel crash, use +the \fBmdb\fR(1) utility on the \fBsavecore\fR(1M) output. +.sp +.LP +The \fBnetstat\fR utility obtains TCP statistics from the system by opening +\fB/dev/tcp\fR and issuing queries. Because of this, \fBnetstat\fR might +display an extra, unused connection in \fBIDLE\fR state when reporting +connection status. +.sp +.LP +Previous versions of \fBnetstat\fR had undocumented methods for reporting +kernel statistics published using the \fBkstat\fR(7D) facility. This +functionality has been removed. Use \fBkstat\fR(1M) instead. +.sp +.LP +\fBnetstat\fR restricts its output to information that is relevant to the zone +in which \fBnetstat\fR runs. (This is true for both shared-IP and exclusive-IP +zones.) |