dgpingUser Manual

dgping(1)

Name

dgping — SOCK_DGRAM echo ping client

Synopsis

dgping 

[ -c count ] [ -i interval ] host port

dgping 

{ -h }

Description

dgping is analog of ICMP ping for SOCK_DGRAM. Messages are sent to a server, dgpingd, which responds back to the dgping client.

The client maintains a list of pending responses, and keeps runing statistics. This illustrates dropped packets, corruption, out of order responses and duplicate datagrams.

Pending responses are removed either when a response is received, or on timeout. A checksum is included in the packet contents to detect corruption, and a sequence number is used to identify the order of responses.

SIGINFO causes current statistics to be written to stderr. The total statistics are also printed to stderr when pinging is complete.

Options

-c count

Specify the maximum number of ping messages to send. dgping will enter culling mode after this number has been sent (see SIGINT below).

The default is 0, meaning to continue indefinitely. Negative values are not permitted.

-i interval

The interval between pings, specified in seconds.

The default is 0.5 meaning a ping is sent every 500ms.

-h

Print a quick reference to these options, and exit.

Exit Status

Exits >0 if an error occurs, or 0 on success.

Signals

SIGINT

An initial SIGINT causes dgping to cease sending futher ping messages, and to enter a period of culling. Pending responses pings are either recieved (and accounted for), or time out. dgping will exit when no pending responses remain.

If a further SIGINT signal is recieved whilst culling pending responses, then dgping will exit immediately, as if all responses had timed out.

SIGINFO

Causes dgping to print current statistics to stderr.

SIGALRM

Used internally.

Caveats

SIGINFO is not present on Linux.

Timing is ostensibly to millisecond resolution, but is in practice only accurate to the OS scheduler.

There is no way to specify a timeout interval, as per the -t option for stping.

There is no way to specify the cull factor, as per the -u option for stping.

See Also

dgpingd.

History

dgping was designed and implemented by Katherine Flavel for Bubblephone Ltd.