diff --git a/README.md b/README.md index fd34748..0d6f025 100644 --- a/README.md +++ b/README.md @@ -265,6 +265,8 @@ The following default configurations are available: ``` -h, --help Show usage message. + -l, --log Container logging facility. + Example: -l journald -l syslog -l json-file -d Benchmark description. -m Benchmark mode. Example: -m wrk -m rate @@ -410,7 +412,7 @@ To add one more node configuration, provide all necessary information to the `no Name|Description| Default |Example ---|---|---------|--- -NEOBENCH_LOGGER|Container logging facility| `none` |`none`, `journald`, `syslog` +NEOBENCH_LOGGER|Container logging facility| `none` |`none`, `journald`, `syslog`,`json-file` NEOBENCH_TC|Parameters passed to the `tc qdisc` (netem discipline) on container startup| |`delay 100ms` NEOBENCH_TYPE|Type of the load| `NEO` |`NEO`, `GAS` NEOBENCH_FROM_COUNT|Number of tx senders| `1` | `1` @@ -418,6 +420,8 @@ NEOBENCH_TO_COUNT|Number of fund receivers| `1` | `1` NEOBENCH_VALIDATOR_COUNT|Number of validators| `4` | `1`, `4`, `7` NEOBENCH_VOTE|Vote for validators before the bench| empty |`1` or empty +For MacOS NEOBENCH_LOGGER should be set to `json-file` as `journald` and +`syslog` are not supported by this architecture. ## Benchmark results visualisation There's a Python plotting script available for benchmark data visualisation. diff --git a/runner.sh b/runner.sh index 5eafe1b..d682ffa 100755 --- a/runner.sh +++ b/runner.sh @@ -47,7 +47,8 @@ show_help() { echo " -t Request timeout." echo " Used for RPC requests." echo " Example: -t 30s" - echo " -l, --log Enable logging on consensus nodes." + echo " -l, --log Container logging facility. Default value is none" + echo " Example: -l journald -l syslog -l json-file" echo " --tc Arguments to pass to 'tc qdisc netem' inside the container." echo " Example: 'delay 100ms'" exit 0 @@ -68,7 +69,22 @@ while test $# -gt 0; do case $_opt in -h | --help) show_help ;; - -l | --log) export NEOBENCH_LOGGER=journald ;; + -l | --log) + if [[ $# -gt 0 && ${1:0:1} != "-" ]]; then + case "$1" in + "syslog" | "journald" | "json-file" | "none") + export NEOBENCH_LOGGER="$1" + shift + ;; + *) + fatal "unknown logger specified: $1" + ;; + esac + else + export NEOBENCH_LOGGER="none" + fi + ;; + --vote) export NEOBENCH_VOTE=1 ;; -v | --validators)