[READ-ONLY] Mirror of https://github.com/FoxxMD/crowdsecBench. Benchmark Crowdsec CPU usage with concurrent requests
benchmark cpu-usage crowdsec docker k6 monitoring visualization
0

Configure Feed

Select the types of activity you want to include in your feed.

Update bench to allow specifying goffel bin location

FoxxMD (Sep 22, 2025, 3:57 PM EDT) f9e0adf7 92d930bb

+7 -4
+7 -4
bench.sh
··· 1 1 #!/bin/bash 2 2 3 - if ! command -v goeffel >/dev/null 2>&1 3 + CMD=${1:-goeffel} 4 + CMD_ANALYSIS="${CMD}-analysis" 5 + 6 + if ! command -v $CMD >/dev/null 2>&1 4 7 then 5 - echo "goeffel could not be found, please make sure it is installed and this shell can access it." 8 + echo "$CMD could not be found, please make sure it is installed and this shell can access it." 6 9 exit 1 7 10 fi 8 11 ··· 37 40 sleep 2 38 41 39 42 printf 'Starting goeffel capture of crowdsec PID %s \n' "$CS_PID" 40 - goeffel --pid $CS_PID --no-system-metrics --label crowdsec & 43 + $CMD --pid $CS_PID --no-system-metrics --label crowdsec & 41 44 G_PID=$! 42 45 43 46 printf 'Starting k6\n' ··· 61 64 62 65 printf 'Generating plot for %s\n' "$DATA" 63 66 64 - sudo -u $real_user goeffel-analysis flexplot \ 67 + sudo -u $real_user $CMD_ANALYSIS flexplot \ 65 68 --series $DATA host \ 66 69 --column proc_cpu_util_percent_total \ 67 70 'CPU util (total) / %' \