wrk is a HTTP Benchmarking tool. It can generate significant amount of load on a HTTP server. Here is an example how it works.
wrk -t12 -c400 -d30s http://127.0.0.1:8080/index.html
This runs a benchmark for 30 seconds, using 12 threads, and keeping 400 HTTP connections open.
Running 30s test @ http://127.0.0.1:8080/index.html 12 threads and 400 connections Thread Stats Avg Stdev Max +/- Stdev Latency 635.91us 0.89ms 12.92ms 93.69% Req/Sec 56.20k 8.07k 62.00k 86.54% 22464657 requests in 30.00s, 17.76GB read Requests/sec: 748868.53 Transfer/sec: 606.33MB
wrk requires LuaJIT and OpenSSL as dependencies.
You may face the following issues while you will be trying to build and install wrk on IBM Power Systems(ppc64le).
In file included from src/wrk.c:3: src/wrk.h:11:10: fatal error: openssl/ssl.h: No such file or directory #include <openssl/ssl.h> ^~~~~~~~~~~~~~~
To solve the above issue you need to install openssl-devel package.
In file included from src/wrk.c:3: src/wrk.h:13:10: fatal error: lua.h: No such file or directory #include <lua.h> ^~~~~~~
To solve this issue, luajit need to be system include and lib path. Find How to install LuaJIT on IBM Power Systems.
So you can follow the below steps to install wrk on IBM Power Systems(ppc64le platform).
# Install openssl-devel package yum install openssl-devel # git clone wrk git clone https://github.com/wg/wrk.git cd wrk # put luajit under include and lib ln -sf /usr/local/include/luajit-2.1/ /usr/include/luajit-2.1 ln -sf /usr/local/lib/libluajit-5.1.so.2 /usr/lib64/libluajit-5.1.so.2 sed -i 's/WITH_LUAJIT)\/include$/WITH_LUAJIT)\/include\/luajit-2.1/' Makefile # build and install wrk make WITH_LUAJIT=/usr WITH_OPENSSL=/usr