commands.sh

wrk

all

HTTP benchmarking tool.

More info →

Options (4)

-t, --threadsboolean

Run a benchmark for `30` seconds, using `12` threads, and keeping `400` HTTP connections open

Example: wrk {{[-t|--threads]}} {{12}} {{[-c|--connections]}} {{400}} {{[-d|--duration]}} {{30s}} "{{http://127.0.0.1:8080/index.html}}"
-c, --connectionsboolean

Run a benchmark for `30` seconds, using `12` threads, and keeping `400` HTTP connections open

Example: wrk {{[-t|--threads]}} {{12}} {{[-c|--connections]}} {{400}} {{[-d|--duration]}} {{30s}} "{{http://127.0.0.1:8080/index.html}}"
-d, --durationboolean

Run a benchmark for `30` seconds, using `12` threads, and keeping `400` HTTP connections open

Example: wrk {{[-t|--threads]}} {{12}} {{[-c|--connections]}} {{400}} {{[-d|--duration]}} {{30s}} "{{http://127.0.0.1:8080/index.html}}"
-H, --headerboolean

Run a benchmark with a custom header

Example: wrk {{[-t|--threads]}} {{2}} {{[-c|--connections]}} {{5}} {{[-d|--duration]}} {{5s}} {{[-H|--header]}} "{{Host: example.com}}" "{{http://example.com/index.html}}"

Examples (3)

Run a benchmark for `30` seconds, using `12` threads, and keeping `400` HTTP connections open

wrk [-t|--threads] 12 [-c|--connections] 400 [-d|--duration] 30s "http://127.0.0.1:8080/index.html"

Run a benchmark with a custom header

wrk [-t|--threads] 2 [-c|--connections] 5 [-d|--duration] 5s [-H|--header] "Host: example.com" "http://example.com/index.html"

Run a benchmark with a request timeout of `2` seconds

wrk [-t|--threads] 2 [-c|--connections] 5 [-d|--duration] 5s --timeout 2s "http://example.com/index.html"
made by @shridhargupta | data from tldr-pages