/scaletesting-iperf

IPerf3 executor for running scale-tests

Primary LanguageGo

scaletesting-iperf

IPerf3 executor for running scale-tests

Usage

You can run pairs of the iperf container in you cluster for creating constant TCP or UDP streams of test data. Each instance can feed it's current observations to a StatsD server.

docker run -it --rm \
    -e STATSD_UDP_HOST=statsd.server.local \
    -e STATSD_UDP_PORT=8125 \
    -e IPERF_SIDE=server \
    icharalampidis/projects:scaletesting-iperf

Configuration

The following environment variables can (or must) be provided:

Variable Default Description
STATSD_UDP_HOST (Required) The hostname of the STATSD server where to push the metrics.
STATSD_UDP_PORT (Required) The port of the STATSD server where to push the metrics.
STATSD_PREFIX perf.server. The prefix for all metrics emitted by the runner.
perf.client.
IPERF_SIDE (Required) Specify either server or client.
IPERF_HOST 0.0.0.0 The host to either listen to or connect to.
IPERF_PORT 5201 The TCP/UDP port to use for sending traffic through.
IPERF_PARALLEL 1 How many parallel streams to establish.
IPERF_BITRATE 0 Target bitrate in bits/sec (0 for unlimited). Default 1 Mbit/sec for UDP, unlimited for TCP, optional slash and packet count for burst mode.
IPERF_UDP no Set to yes to use UDP instead of TCP.
IPERF_EXTRA_ARGS Additional arguments to pass to the iperf3 binary.
RESTART_SCONDS 5 How many seconds to wait before re-starting the client (or server) after it exists.
RESTART_RANDOM_SCONDS 5 Additional randomized number of seconds to wait after the RESTART_SECONDS timeout.

Metrics

The service is pushing the following metrics to the STATSD endpoint:

Metric Type Units Description
running Counter - Counts how many instances are running. This counter is incremented when IPerf is started and decremented when stopped.
status Gauge - Indicates the status of the process. It's -1 when running or >=0 if exited, having the exit code set in this proprty.
bytes Counter Bytes Counts how many bytes have been sent/received during the last session.
bitrate Gauge Bits/sec Indicates the current throughput.