1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376
|
.\" Automatically generated by Pod::Man 4.11 (Pod::Simple 3.35)
.\"
.\" Standard preamble:
.\" ========================================================================
.de Sp \" Vertical space (when we can't use .PP)
.if t .sp .5v
.if n .sp
..
.de Vb \" Begin verbatim text
.ft CW
.nf
.ne \\$1
..
.de Ve \" End verbatim text
.ft R
.fi
..
.\" Set up some character translations and predefined strings. \*(-- will
.\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left
.\" double quote, and \*(R" will give a right double quote. \*(C+ will
.\" give a nicer C++. Capital omega is used to do unbreakable dashes and
.\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff,
.\" nothing in troff, for use with C<>.
.tr \(*W-
.ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p'
.ie n \{\
. ds -- \(*W-
. ds PI pi
. if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch
. if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch
. ds L" ""
. ds R" ""
. ds C` ""
. ds C' ""
'br\}
.el\{\
. ds -- \|\(em\|
. ds PI \(*p
. ds L" ``
. ds R" ''
. ds C`
. ds C'
'br\}
.\"
.\" Escape single quotes in literal strings from groff's Unicode transform.
.ie \n(.g .ds Aq \(aq
.el .ds Aq '
.\"
.\" If the F register is >0, we'll generate index entries on stderr for
.\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
.\" entries marked with X<> in POD. Of course, you'll have to process the
.\" output yourself in some meaningful fashion.
.\"
.\" Avoid warning from groff about undefined register 'F'.
.de IX
..
.nr rF 0
.if \n(.g .if rF .nr rF 1
.if (\n(rF:(\n(.g==0)) \{\
. if \nF \{\
. de IX
. tm Index:\\$1\t\\n%\t"\\$2"
..
. if !\nF==2 \{\
. nr % 0
. nr F 2
. \}
. \}
.\}
.rr rF
.\"
.\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2).
.\" Fear. Run. Save yourself. No user-serviceable parts.
. \" fudge factors for nroff and troff
.if n \{\
. ds #H 0
. ds #V .8m
. ds #F .3m
. ds #[ \f1
. ds #] \fP
.\}
.if t \{\
. ds #H ((1u-(\\\\n(.fu%2u))*.13m)
. ds #V .6m
. ds #F 0
. ds #[ \&
. ds #] \&
.\}
. \" simple accents for nroff and troff
.if n \{\
. ds ' \&
. ds ` \&
. ds ^ \&
. ds , \&
. ds ~ ~
. ds /
.\}
.if t \{\
. ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u"
. ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u'
. ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u'
. ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u'
. ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u'
. ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u'
.\}
. \" troff and (daisy-wheel) nroff accents
.ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V'
.ds 8 \h'\*(#H'\(*b\h'-\*(#H'
.ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#]
.ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H'
.ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u'
.ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#]
.ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#]
.ds ae a\h'-(\w'a'u*4/10)'e
.ds Ae A\h'-(\w'A'u*4/10)'E
. \" corrections for vroff
.if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u'
.if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u'
. \" for low resolution devices (crt and lpr)
.if \n(.H>23 .if \n(.V>19 \
\{\
. ds : e
. ds 8 ss
. ds o a
. ds d- d\h'-1'\(ga
. ds D- D\h'-1'\(hy
. ds th \o'bp'
. ds Th \o'LP'
. ds ae ae
. ds Ae AE
.\}
.rm #[ #] #H #V #F C
.\" ========================================================================
.\"
.IX Title "FPING 8"
.TH FPING 8 "2022-02-06" "fping" ""
.\" For nroff, turn off justification. Always turn off hyphenation; it makes
.\" way too many mistakes in technical documents.
.if n .ad l
.nh
.SH "NAME"
fping \- send ICMP ECHO_REQUEST packets to network hosts
.SH "SYNOPSIS"
.IX Header "SYNOPSIS"
\&\fBfping\fR [ \fIoptions\fR ] [ \fIsystems...\fR ]
.SH "DESCRIPTION"
.IX Header "DESCRIPTION"
\&\fBfping\fR is a program like \fBping\fR which uses the Internet Control Message
Protocol (\s-1ICMP\s0) echo request to determine if a target host is responding.
\&\fBfping\fR differs from \fBping\fR in that you can specify any number of targets on the
command line, or specify a file containing the lists of targets to ping.
Instead of sending to one target until it times out or replies, \fBfping\fR will
send out a ping packet and move on to the next target in a round-robin fashion.
In the default mode, if a target replies, it is noted and removed from the list
of targets to check; if a target does not respond within a certain time limit
and/or retry limit it is designated as unreachable. \fBfping\fR also supports
sending a specified number of pings to a target, or looping indefinitely (as in
\&\fBping\fR ). Unlike \fBping\fR, \fBfping\fR is meant to be used in scripts, so its
output is designed to be easy to parse. Current statistics can be obtained without
termination of process with signal \s-1SIGQUIT\s0 (^\e from the keyboard on most systems).
.SH "OPTIONS"
.IX Header "OPTIONS"
.IP "\fB\-4\fR, \fB\-\-ipv4\fR" 5
.IX Item "-4, --ipv4"
Restrict name resolution and IPs to IPv4 addresses.
.IP "\fB\-6\fR, \fB\-\-ipv6\fR" 5
.IX Item "-6, --ipv6"
Restrict name resolution and IPs to IPv6 addresses.
.IP "\fB\-a\fR, \fB\-\-alive\fR" 5
.IX Item "-a, --alive"
Show systems that are alive.
.IP "\fB\-A\fR, \fB\-\-addr\fR" 5
.IX Item "-A, --addr"
Display targets by address rather than \s-1DNS\s0 name. Combined with \-d, the output
will be both the ip and (if available) the hostname.
.IP "\fB\-b\fR, \fB\-\-size\fR=\fI\s-1BYTES\s0\fR" 5
.IX Item "-b, --size=BYTES"
Number of bytes of ping data to send. The minimum size (normally 12) allows
room for the data that \fBfping\fR needs to do its work (sequence number,
timestamp). The reported received data size includes the \s-1IP\s0 header (normally
20 bytes) and \s-1ICMP\s0 header (8 bytes), so the minimum total size is 40 bytes.
Default is 56, as in \fBping\fR. Maximum is the theoretical maximum \s-1IP\s0 datagram
size (64K), though most systems limit this to a smaller, system-dependent
number.
.IP "\fB\-B\fR, \fB\-\-backoff\fR=\fIN\fR" 5
.IX Item "-B, --backoff=N"
Backoff factor. In the default mode, \fBfping\fR sends several requests to a
target before giving up, waiting longer for a reply on each successive request.
This parameter is the value by which the wait time (\fB\-t\fR) is multiplied on each
successive request; it must be entered as a floating-point number (x.y). The
default is 1.5.
.IP "\fB\-c\fR, \fB\-\-count\fR=\fIN\fR" 5
.IX Item "-c, --count=N"
Number of request packets to send to each target. In this mode, a line is
displayed for each received response (this can suppressed with \fB\-q\fR or \fB\-Q\fR).
Also, statistics about responses for each target are displayed when all
requests have been sent (or when interrupted).
.IP "\fB\-C\fR, \fB\-\-vcount\fR=\fIN\fR" 5
.IX Item "-C, --vcount=N"
Similar to \fB\-c\fR, but the per-target statistics are displayed in a format
designed for automated response-time statistics gathering. For example:
.Sp
.Vb 2
\& $ fping \-C 5 \-q somehost
\& somehost : 91.7 37.0 29.2 \- 36.8
.Ve
.Sp
shows the response time in milliseconds for each of the five requests, with the
\&\f(CW\*(C`\-\*(C'\fR indicating that no response was received to the fourth request.
.IP "\fB\-d\fR, \fB\-\-rdns\fR" 5
.IX Item "-d, --rdns"
Use \s-1DNS\s0 to lookup address of ping target. This allows you to give fping
a list of \s-1IP\s0 addresses as input and print hostnames in the output. This is similar
to option \fB\-n\fR/\fB\-\-name\fR, but will force a reverse-DNS lookup even if you give
hostnames as target (\s-1NAME\-\s0>\s-1IP\-\s0>\s-1NAME\s0).
.IP "\fB\-D\fR, \fB\-\-timestamp\fR" 5
.IX Item "-D, --timestamp"
Add Unix timestamps in front of output lines generated with in looping or counting
modes (\fB\-l\fR, \fB\-c\fR, or \fB\-C\fR).
.IP "\fB\-e\fR, \fB\-\-elapsed\fR" 5
.IX Item "-e, --elapsed"
Show elapsed (round-trip) time of packets.
.IP "\fB\-f\fR, \fB\-\-file\fR" 5
.IX Item "-f, --file"
Read list of targets from a file. This option can only be used by the root
user. Regular users should pipe in the file via stdin:
.Sp
.Vb 1
\& $ fping < targets_file
.Ve
.IP "\fB\-g\fR, \fB\-\-generate\fR \fIaddr/mask\fR" 5
.IX Item "-g, --generate addr/mask"
Generate a target list from a supplied \s-1IP\s0 netmask, or a starting and ending \s-1IP.\s0
Specify the netmask or start/end in the targets portion of the command line. If
a network with netmask is given, the network and broadcast addresses will be
excluded. ex. To ping the network 192.168.1.0/24, the specified command line
could look like either:
.Sp
.Vb 1
\& $ fping \-g 192.168.1.0/24
.Ve
.Sp
or
.Sp
.Vb 1
\& $ fping \-g 192.168.1.1 192.168.1.254
.Ve
.IP "\fB\-h\fR, \fB\-\-help\fR" 5
.IX Item "-h, --help"
Print usage message.
.IP "\fB\-H\fR, \fB\-\-ttl\fR=\fIN\fR" 5
.IX Item "-H, --ttl=N"
Set the \s-1IP TTL\s0 field (time to live hops).
.IP "\fB\-i\fR, \fB\-\-interval\fR=\fI\s-1MSEC\s0\fR" 5
.IX Item "-i, --interval=MSEC"
The minimum amount of time (in milliseconds) between sending a ping packet
to any target (default is 10, minimum is 1).
.IP "\fB\-I\fR, \fB\-\-iface\fR=\fI\s-1IFACE\s0\fR" 5
.IX Item "-I, --iface=IFACE"
Set the interface (requires \s-1SO_BINDTODEVICE\s0 support).
.IP "\fB\-l\fR, \fB\-\-loop\fR" 5
.IX Item "-l, --loop"
Loop sending packets to each target indefinitely. Can be interrupted with
Ctrl-C; statistics about responses for each target are then displayed.
.IP "\fB\-m\fR, \fB\-\-all\fR" 5
.IX Item "-m, --all"
Send pings to each of a target host's multiple \s-1IP\s0 addresses (use of option '\-A'
is recommended).
.IP "\fB\-M\fR, \fB\-\-dontfrag\fR" 5
.IX Item "-M, --dontfrag"
Set the \*(L"Don't Fragment\*(R" bit in the \s-1IP\s0 header (used to determine/test the \s-1MTU\s0).
.IP "\fB\-n\fR, \fB\-\-name\fR" 5
.IX Item "-n, --name"
If targets are specified as \s-1IP\s0 addresses, do a reverse-DNS lookup on them
to print hostnames in the output.
.IP "\fB\-N\fR, \fB\-\-netdata\fR" 5
.IX Item "-N, --netdata"
Format output for netdata (\-l \-Q are required). See: <http://my\-netdata.io/>
.IP "\fB\-o\fR, \fB\-\-outage\fR" 5
.IX Item "-o, --outage"
Calculate \*(L"outage time\*(R" based on the number of lost pings and the interval used (useful for network convergence tests).
.IP "\fB\-O\fR, \fB\-\-tos\fR=\fIN\fR" 5
.IX Item "-O, --tos=N"
Set the typ of service flag (\s-1TOS\s0). \fIN\fR can be either decimal or hexadecimal
(0xh) format.
.IP "\fB\-p\fR, \fB\-\-period\fR=\fI\s-1MSEC\s0\fR" 5
.IX Item "-p, --period=MSEC"
In looping or counting modes (\fB\-l\fR, \fB\-c\fR, or \fB\-C\fR), this parameter sets
the time in milliseconds that \fBfping\fR waits between successive packets to
an individual target. Default is 1000 and minimum is 10.
.IP "\fB\-q\fR, \fB\-\-quiet\fR" 5
.IX Item "-q, --quiet"
Quiet. Don't show per-probe results, but only the final summary. Also don't
show \s-1ICMP\s0 error messages.
.IP "\fB\-Q\fR, \fB\-\-squiet\fR=\fI\s-1SECS\s0\fR" 5
.IX Item "-Q, --squiet=SECS"
Like \fB\-q\fR, but additionally show interval summary results every \fI\s-1SECS\s0\fR
seconds.
.IP "\fB\-r\fR, \fB\-\-retry\fR=\fIN\fR" 5
.IX Item "-r, --retry=N"
Retry limit (default 3). This is the number of times an attempt at pinging
a target will be made, not including the first try.
.IP "\fB\-R\fR, \fB\-\-random\fR" 5
.IX Item "-R, --random"
Instead of using all-zeros as the packet data, generate random bytes.
Use to defeat, e.g., link data compression.
.IP "\fB\-s\fR, \fB\-\-stats\fR" 5
.IX Item "-s, --stats"
Print cumulative statistics upon exit.
.IP "\fB\-S\fR, \fB\-\-src\fR=\fIaddr\fR" 5
.IX Item "-S, --src=addr"
Set source address.
.IP "\fB\-t\fR, \fB\-\-timeout\fR=\fI\s-1MSEC\s0\fR" 5
.IX Item "-t, --timeout=MSEC"
Initial target timeout in milliseconds. In the default, non-loop mode, the
default timeout is 500ms, and it represents the amount of time that \fBfping\fR
waits for a response to its first request. Successive timeouts are multiplied
by the backoff factor specified with \fB\-B\fR.
.Sp
In loop/count mode, the default timeout is automatically adjusted to match
the \*(L"period\*(R" value (but not more than 2000ms). You can still adjust the timeout
value with this option, if you wish to, but note that setting a value larger
than \*(L"period\*(R" produces inconsistent results, because the timeout value can
be respected only for the last ping.
.Sp
Also note that any received replies that are larger than the timeout value, will
be discarded.
.IP "\fB\-T\fR \fIn\fR" 5
.IX Item "-T n"
Ignored (for compatibility with fping 2.4).
.IP "\fB\-u\fR, \fB\-\-unreach\fR" 5
.IX Item "-u, --unreach"
Show targets that are unreachable.
.IP "\fB\-v\fR, \fB\-\-version\fR" 5
.IX Item "-v, --version"
Print \fBfping\fR version information.
.IP "\fB\-x\fR, \fB\-\-reachable\fR=\fIN\fR" 5
.IX Item "-x, --reachable=N"
Given a list of hosts, this mode checks if number of reachable hosts is >= N
and exits true in that case.
.SH "EXAMPLES"
.IX Header "EXAMPLES"
Generate 20 pings to two hosts in ca. 1 second (i.e. one ping every 50 ms to
each host), and report every ping \s-1RTT\s0 at the end:
.PP
.Vb 1
\& $ fping \-\-quiet \-\-interval=1 \-\-vcount=20 \-\-period=50 127.0.0.1 127.0.0.2
.Ve
.SH "AUTHORS"
.IX Header "AUTHORS"
.IP "\(bu" 4
Roland J. Schemers \s-1III,\s0 Stanford University, concept and versions 1.x
.IP "\(bu" 4
\&\s-1RL\s0 \*(L"Bob\*(R" Morgan, Stanford University, versions 2.x
.IP "\(bu" 4
David Papp, versions 2.3x and up
.IP "\(bu" 4
David Schweikert, versions 3.0 and up
.PP
\&\fBfping website: <http://www.fping.org>\fR
.SH "DIAGNOSTICS"
.IX Header "DIAGNOSTICS"
Exit status is 0 if all the hosts are reachable, 1 if some hosts
were unreachable, 2 if any \s-1IP\s0 addresses were not found, 3 for invalid command
line arguments, and 4 for a system call failure.
.SH "RESTRICTIONS"
.IX Header "RESTRICTIONS"
If fping was configured with \f(CW\*(C`\-\-enable\-safe\-limits\*(C'\fR, the following values are
not allowed for non-root users:
.IP "\(bu" 4
\&\fB\-i\fR \fIn\fR, where \fIn\fR < 1 msec
.IP "\(bu" 4
\&\fB\-p\fR \fIn\fR, where \fIn\fR < 10 msec
.SH "SEE ALSO"
.IX Header "SEE ALSO"
\&\f(CWping(8)\fR
|