]> git.proxmox.com Git - mirror_iproute2.git/blame - man/man8/ss.8
veth.h move to linux/
[mirror_iproute2.git] / man / man8 / ss.8
CommitLineData
d7eeca84
SH
1.TH SS 8
2.SH NAME
3ss \- another utility to investigate sockets
4.SH SYNOPSIS
5.B ss
6.RI [ options ] " [ FILTER ]"
7.SH DESCRIPTION
8.B ss
9is used to dump socket statistics. It allows showing information similar
10to
11.IR netstat .
b096fa5f 12It can display more TCP and state informations than other tools.
d7eeca84
SH
13
14.SH OPTIONS
15These programs follow the usual GNU command line syntax, with long
16options starting with two dashes (`-').
17A summary of options is included below.
18.TP
19.B \-h, \-\-help
20Show summary of options.
21.TP
22.B \-V, \-\-version
23Output version information.
24.TP
25.B \-n, \-\-numeric
26Do now try to resolve service names.
27.TP
28.B \-r, \-\-resolve
29Try to resolve numeric address/ports.
30.TP
31.B \-a, \-\-all
32Display all sockets.
33.TP
34.B \-l, \-\-listening
35Display listening sockets.
36.TP
37.B \-o, \-\-options
38Show timer information.
39.TP
40.B \-e, \-\-extended
41Show detailed socket information
42.TP
43.B \-m, \-\-memory
44Show socket memory usage.
45.TP
46.B \-p, \-\-processes
47Show process using socket.
48.TP
49.B \-i, \-\-info
50Show internal TCP information.
51.TP
52.B \-s, \-\-summary
53Print summary statistics. This option does not parse socket lists obtaining
54summary from various sources. It is useful when amount of sockets is so huge
55that parsing /proc/net/tcp is painful.
56.TP
57.B \-4, \-\-ipv4
58Display only IP version 4 sockets (alias for -f inet).
59.TP
60.B \-6, \-\-ipv6
61Display only IP version 6 sockets (alias for -f inet6).
62.TP
63.B \-0, \-\-packet
64Display PACKET sockets.
65.TP
66.B \-t, \-\-tcp
67Display only TCP sockets.
68.TP
69.B \-u, \-\-udp
70Display only UDP sockets.
71.TP
72.B \-d, \-\-dccp
73Display only DCCP sockets.
74.TP
75.B \-w, \-\-raw
76Display only RAW sockets.
77.TP
78.B \-x, \-\-unix
79Display only Unix domain sockets.
80.TP
81.B \-f FAMILY, \-\-family=FAMILY
82Display sockets of type FAMILY.
83Currently the following families are supported: unix, inet, inet6, link, netlink.
84.TP
85.B \-A QUERY, \-\-query=QUERY
86List of socket tables to dump, separated by commas. The following identifiers
87are understood: all, inet, tcp, udp, raw, unix, packet, netlink, unix_dgram,
88unix_stream, packet_raw, packet_dgram.
89.TP
90.B \-D FILE
91Do not display anything, just dump raw information about TCP sockets to FILE after applying filters. If FILE is - stdout is used.
92.TP
93.B \-F FILE, \-\-filter=FILE
94Read filter information from FILE.
95Each line of FILE is interpreted like single command line option. If FILE is - stdin is used.
96.TP
97.B FILTER := [ state TCP-STATE ] [ EXPRESSION ]
98Please take a look at the official documentation (Debian package iproute-doc) for details regarding filters.
99.SH USAGE EXAMPLES
100.TP
101.B ss -t -a
102Display all TCP sockets.
103.TP
104.B ss -u -a
105Display all UDP sockets.
106.TP
107.B ss -o state established '( dport = :ssh or sport = :ssh )'
108Display all established ssh connections.
109.TP
110.B ss -x src \"/tmp/.X11-unix/*\"
111Find all local processes connected to X server.
112.TP
113.B ss -o state fin-wait-1 '( sport = :http or sport = :https )' dst 193.233.7/24
114List all the tcp sockets in state FIN-WAIT-1 for our apache to network 193.233.7/24 and look at their timers.
115.SH SEE ALSO
116.BR ip (8),
117