SOCKSTAT(1) | MidnightBSD General Commands Manual | SOCKSTAT(1) |
sockstat
— list
open sockets
sockstat |
[-46CcLlSsUuvw ] [-j
jid] [-p
ports] [-P
protocols] |
The sockstat
command lists open Internet
or UNIX domain sockets.
The following options are available:
-4
AF_INET
(IPv4) sockets.-6
AF_INET6
(IPv6) sockets.-C
-c
-j
jail-L
127.0.0.0/8
, or do not
contain the IPv6 loopback address ::1
.-l
-p
ports-P
protocols-q
-S
-s
-U
-u
AF_LOCAL
(UNIX)
sockets.-v
-w
If neither -4
, -6
or -u
is specified, sockstat
will list sockets in all three domains.
If neither -c
or
-l
is specified, sockstat
will list both listening and connected sockets.
The information listed for each socket is:
USER
COMMAND
PID
FD
PROTO
LOCAL
ADDRESS
??
” if the endpoint could not be
determined.FOREIGN
ADDRESS
ENCAPS
-U
is
specified (only for SCTP).PATH
STATE
-s
is specified (only for
SCTP).CONN
STATE
-s
is specified (only for
SCTP or TCP).STACK
-S
is specified (only for
TCP).CC
-C
is specified (only
for TCP).If a socket is associated with more than one file descriptor, it is shown multiple times. If a socket is not associated with any file descriptor, the first four columns have no meaning.
fstat(1), netstat(1), procstat(1), inet(4), inet6(4), protocols(5)
The sockstat
command appeared in
FreeBSD 3.1.
The sockstat
command and this manual page
were written by Dag-Erling Smørgrav
<des@FreeBSD.org>.
September 13, 2020 | midnightbsd-3.1 |