From 88c878da0c1e8f6e33d2092f6a97ec4e176fdb67 Mon Sep 17 00:00:00 2001 From: Federico Gimenez Date: Wed, 29 Jan 2025 17:51:31 +0100 Subject: [PATCH] chore: update reth-bench docs (#14060) --- bin/reth-bench/README.md | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/bin/reth-bench/README.md b/bin/reth-bench/README.md index fa58d467f..fa600f241 100644 --- a/bin/reth-bench/README.md +++ b/bin/reth-bench/README.md @@ -33,15 +33,21 @@ The `reth-bench new-payload-fcu` command is the most representative of ethereum Below is an overview of how to execute a benchmark: - 1. **Setup**: Make sure `reth` is running in the background with the proper configuration. This setup involves ensuring the node is at the correct state, setting up profiling tools, and possibly more depending on the purpose of the benchmark's. + 1. **Setup**: + + Make sure `reth` is running in the background with the proper configuration. This setup involves ensuring the node is at the correct state, setting up profiling tools, and possibly more depending on the purpose of the benchmark's. + + Also, you should shut down any consensus layer client configured to connect to `reth`, all the engine API interactions during benchmarking will be driven by `reth-bench`. + + Depending on the block range you want to use in the benchmark you might need to unwind your node, the head of the node should be behind the lowest block in the range. 2. **Run the Benchmark**: ```bash - reth-bench new-payload-fcu --rpc-url http://:8545 --from --to --jwtsecret + reth-bench new-payload-fcu --rpc-url --from --to --jwtsecret ``` - Replace ``, ``, ``, and `` with the appropriate values for your testing environment. - Note that this assumes that the benchmark node's engine API is running on `http://127.0.0.1:8545`, which is set as a default value in `reth-bench`. To configure this value, use the `--engine-rpc-url` flag. + Replace ``, ``, and `` with the appropriate values for your testing environment. `` should be the URL of an RPC endpoint that can provide the blocks that will be used during the execution. + Note that this assumes that the benchmark node's engine API is running on `http://127.0.0.1:8551`, which is set as a default value in `reth-bench`. To configure this value, use the `--engine-rpc-url` flag. 3. **Observe Outputs**: Upon running the command, `reth-bench` will output benchmark results, showing processing speeds and gas usage, which are crucial for analyzing the node's performance. @@ -62,4 +68,3 @@ Below is an overview of how to execute a benchmark: - **Profiling tools**: If you are collecting CPU profiles, tools like [`samply`](https://github.com/mstange/samply) and [`perf`](https://perf.wiki.kernel.org/index.php/Main_Page) can be useful for analyzing node performance. - **Benchmark Data**: `reth-bench` additionally contains a `--benchmark.output` flag, which will output gas used benchmarks across the benchmark range in CSV format. This may be useful for further data analysis. - **Platform Information**: To ensure accurate and reproducible benchmarking, document the platform details, including hardware specifications, OS version, and any other relevant information before publishing any benchmarks. -