Man Linux: Main Page and Category List

NAME

     scamper - parallel Internet measurement utility

SYNOPSIS

     scamper [-?Pv] [-c command] [-p pps] [-M monitorname] [-s sport]
             [-H holdtime] [-o outfile] [-O outtype]
             [-i addr 1..N | listfile | -D port]

DESCRIPTION

     The scamper utility provides the ability to execute Internet measurement
     techniques to IPv4 and IPv6 addresses, in parallel, to fill a specified
     packets-per-second rate.  Currently, scamper supports the well-known
     traceroute and ping techniques.  scamper has three modes of operation.

     First, scamper can be supplied a list of addresses on the command line
     with the -i option.  scamper will then measure each of the supplied
     addresses, in parallel, and output the results as each task completes.
     Second, scamper can be supplied a list of addresses in a listfile, one
     address per line.  Finally, scamper can be started as a daemon listening
     on a port specified with the -D option only accessible on the local host.
     scamper will then accept connections to that port, where commands can be
     supplied to scamper.

     The options are as follows:

     -?      prints a list of command line options and a synopsis of each.

     -P      tells scamper to use the operating system’s datalink support to
             obtain more accurate transmit and receive timestamps for scamper
             probes.  This corresponds to bpf(4) on BSD systems, and packet(7)
             on Linux systems.  Datalink timestamps exclude the effects of
             route-lookup delays, as well as overheads in a packet making it
             to and from the network interface.

     -v      causes scamper to output version information and exit.

     -c command
             specifies the command for scamper to use by default. The current
             choices for this option are trace and ping.  scamper uses trace
             by default.

     -p pps  specifies the target packets-per-second rate for scamper to
             reach.  By default, this value is 20.

     -M monitorname
             specifies the canonical name of machine where scamper is run.
             This value is used when recording the output in a warts(5) output
             file.

     -s sport
             specifies the default source port value for scamper to use.  By
             default, this value is the least significant 15 bits of the
             process id with the 16th bit set.

     -H holdtime
             specifies how long to wait after a measurement has completed for
             any final responses that were delayed.

     -o outfile
             specifies the default output file to write measurement results
             to.  By default, stdout is used.

     -O outtype
             specifies the default output file format to use.  By default,
             ASCII output is used.  However, warts(5) provides a binary file
             format that records much more meta data and detail.

     -i addr 1..N
             specifies the addresses to probe, on the command line.

     listfile
             specifies the input file to read for target addresses.

     -D port
             specifies that scamper starts as a daemon, listening on the
             specified port.

TRACE OPTIONS

     The following variation of the traceroute(8) options are available when
     using the scamper trace command:

     trace [-MQ] [-d dport] [-f firsthop] [-g gaplimit] [-l loops] [-m maxttl]
     [-P method] [-q attempts] [-s sport] [-t tos] [-w wait]

     -P method
             specifies the traceroute method to use.  scamper currently
             supports five different probe methods: UDP, ICMP, TCP, UDP-paris,
             and ICMP-paris.  By default, UDP is used.

     -d dport
             specifies the base destination port value to use for UDP-based
             and TCP-based traceroute methods.  For ICMP-based methods, this
             option has no effect.

     -s sport
             specifies the source port value to use.  For ICMP-based methods,
             this option specifies the ICMP identifier to use.

     -f firsthop
             specifies the TTL or HLIM value to begin probing with.  By
             default, a first hop of one is used.

     -g gaplimit
             specifies the number of unresponsive hops permitted until a check
             is made to see if the destination will respond.  By default, a
             gap limit of 5 hops is used.  Setting the gap limit to 0 disables
             the gap limit.

     -m maxttl
             specifies the maximum TTL or HLIM value that will be probed.  By
             default, a maxttl of 32 is used.

     -l loops
             specifies the maximum number of loops permitted until probing
             stops.  By default, a value of one is used.  A value of zero
             disables loop checking.

     -q attempts
             specifies the maximum number of attempts to obtain a response per
             hop.  By default, a value of two is used.

     -Q      specifies that all allocated probes are sent, regardless of how
             many responses have been received.

     -w wait
             specifies how long to wait, in seconds, for a reply.  By default,
             a value of 5 is used.

     -t tos  specifies the value to set in the IP ToS/DSCP + ECN byte.  By
             default, this byte is set to zero.

     -M      specifies that path MTU discovery should be attempted for the
             path when the initial traceroute completes.

PING OPTIONS

     The following variation of the ping(8) options are available when using
     the scamper ping command:

     ping [-c probecount] [-i wait] [-m ttl] [-o replycount] [-p pattern]
     [-s size] [-z tos]

     -c probecount
             specifies the number of probes to send before exiting.  By
             default, a value of 4 is used.

     -i wait
             specifies the length of time to wait, in seconds, between probes.
             By default, a value of 1 is used.

     -m ttl  specifies the TTL value to use for outgoing packets.  By default,
             a value of 64 is used.

     -o replycount
             specifies the number of replies required at which time probing
             may cease.  By default, all probes are sent.

     -p pattern
             specifies the pattern, in hex, to use in probes.  Up to 16 bytes
             may be specified.  By default, each probe’s bytes are zeroed.

     -s size
             specifies the size of the probes to send.  The probe size
             includes the length of the IP and ICMP headers.  By default, a
             probe size of 84 bytes is used for IPv4 pings, and 56 bytes for
             IPv6 pings.

     -z tos  specifies the value to use in the IPv4 ToS/DSCP + ECN byte.  By
             default, this byte is set to zero.

DATA COLLECTION FEATURES

     scamper has two data output formats.  The first is a human-readable
     format suitable for one-off data collection and measurement.  The second,
     known as warts, is a binary format that records much more meta-data and
     is more precise than the human-readable format.

     scamper is designed for Internet-scale measurement, where large lists of
     targets are supplied for probing.  scamper has the ability to probe
     multiple lists simultaneously, with each having a mix rate that specifies
     the priority of the list.  scamper can also make multiple cycles over a
     list of addresses.

     When writing output to a warts file, scamper records details of the list
     and cycle that each measurement task belongs to.

CONTROL SOCKET

     When started with the -D option, scamper allows inter-process
     communication via a TCP socket bound to the supplied port on the local
     host.  This socket is useful for controlling the operation of a long-
     lived scamper process.  A client may interact with scamper by using
     telnet(1) to open a connection to the supplied port.

     The following control socket commands are available.

     exit
          The exit command closes the current control socket connection.

     get argument
          The get command returns the current setting for the supplied
          argument.  Valid argument values are: holdtime, monitorname, pid,
          pps, sport, version.

     set argument ...
          The set command sets the current setting for the supplied argument.
          Valid argument values are: holdtime, monitorname, pps.

     source argument ...

          add arguments
               The source add command allows a new input source to be added.
               It accepts the following arguments:

               name string
                    The name of the source.  This parameter is mandatory.

               descr string
                    An optional string describing the source.

               command string
                    The command to execute for each address supplied.  If not
                    supplied, the default command is used.

               list_id uint32_t
                    An optional numeric list identifier, assigned by a human.
                    If not supplied, a value of zero is used.

               cycle_id uint32_t
                    An optional numeric initial cycle identifier to use,
                    assigned by a human.  If not supplied, a value of one is
                    used.

               priority uint32_t
                    An optional numeric value that specifies the mix rate of
                    measurements from the source compared to other sources.
                    If not supplied, a mix rate of one is used.  A value of
                    zero causes the source to be created, but not actively
                    used.

               adhoc [on | off]
                    An optional parameter that specifies if the source is
                    adhoc (on) or managed (off).  An adhoc source is supplied
                    addresses to probe using control socket commands.  A
                    managed source is one that is supplied addresses to probe
                    from a file.  A managed source handles cycling and
                    reloading the file as necessary.  If not supplied, an
                    adhoc source is created.

               outfile string
                    The name of the output file to write results to,
                    previously defined with outfile open.  If not supplied,
                    the default output file is used.

               file string
                    The name of the input file to read target addresses from.
                    This parameter is mandatory if the source is a managed
                    source.

               cycles integer
                    The number of cycles to make over the target address file.
                    If zero, scamper will loop indefinitely over the file.
                    This parameter is ignored unless a managed source is
                    defined.

               autoreload [on | off]
                    This parameter specifies if the target address file should
                    be re-read whenever a cycle is completed, or if the same
                    set of target addresses as the previous cycle should be
                    used.  If not specified, the file is not automatically
                    reloaded at cycle time.

          update name arguments
               The source update command allows some properties of an existing
               source to be modified.  The source to update is specified with
               the name parameter.  Valid parameters are: autoreload, cycles,
               and priority.

          list ...
               The source list command provides a listing of all currently
               defined sources.  The optional third name parameter restricts
               the listing to the source specified.

          cycle name
               The source cycle command manually inserts a cycle marker in an
               adhoc source.

          delete name
               The source delete command deletes the named source, if
               possible.

     outfile argument ...
          The outfile commands provide the ability to manage output files.  It
          accepts the following arguments:

          open ...
               The outfile open command allows a new output file to be
               defined.  It accepts the following parameters:

               name alias
                    The alias of the output file.  This parameter is
                    mandatory.

               file string
                    The filename of the output file.  This parameter is
                    mandatory.

               mode [truncate | append]
                    How the file will be opened.  If the append mode is used,
                    any existing file with the specified name will be appended
                    to.  If the truncate mode is used, any existing file will
                    be truncated when it is opened.

          close alias
               The outfile close command allows an existing output file to be
               closed.  The mandatory alias parameter specifies which output
               file to close.  An output file that is currently referenced is
               not able to be closed.  To close a file that is currently
               referenced, a new outfile must be opened, and then the outfile
               swap command be used.

          swap alias1 alias2
               The outfile swap command swaps the file associated with each
               output file.

          list
               The outfile list command outputs a list of the existing
               outfiles.

     observe sources
          This command allows for monitoring of source events.  When executed,
          the control socket will then supply event notices whenever a source
          is added, updated, deleted, finished, or cycled.  Each event is
          prefixed with a count of the number of seconds elapsed since the
          Unix epoch.  The following examples illustrate the event monitoring
          capabilities:

                EVENT 1169065640 source add name ’foo’ list_id 5 priority 1
                EVENT 1169065641 source update ’foo’ priority 15
                EVENT 1169065642 source cycle ’bar’ id 2
                EVENT 1169065650 source finish ’bar’
                EVENT 1169065661 source delete ’foo’

     shutdown argument
          The shutdown argument allows the scamper process to be exited
          cleanly.  The following arguments are supported

          done
               The shutdown done command requests that scamper shuts down when
               the current tasks, as well as all remaining cycles, have
               completed.

          flush
               The shutdown flush command requests that scamper flushes all
               remaining tasks queued with each list, finishes all current
               tasks, and then shuts down.

          now  The shutdown now command causes scamper to shutdown
               immediately.  Unfinished tasks are purged.

          cancel
               The shutdown cancel command cancels any pending shutdown.

EXAMPLES

     To use the default traceroute command to trace the path to 192.168.1.1:

          scamper -i 192.168.1.1

     To infer Path MTU changes in the network and associate them with a
     traceroute path:

          scamper -c "trace -M" -i 192.168.1.1

     To use paris UDP traceroute, using 3 probes per hop, sending all probes:

          scamper -c "trace -P UDP-paris -q 3 -Q" -i 192.168.1.1

     To ping a series of addresses defined in filename, probing each address
     10 times:

          scamper -c "ping -c 10" filename

SEE ALSO

     ping(8), sc_analysis_dump(1), traceroute(8), warts(5), warts-dump(1)

AUTHOR

     scamper is written by Matthew Luckie <mjl@wand.net.nz>, member of the
     WAND network research group at the University of Waikato.

ACKNOWLEDGEMENTS

     scamper development was initially funded by the WIDE project in
     association with CAIDA.  CAIDA actively support scamper development.