2024-10-27
This week I tried to add support for more clients to Ethshadow, and improved the general code quality.
Let's look into each client I attempted. The idea here was to quickly assess whether support can be added without much hassle.
Unfortunately, adding Prysm didn't work.
The issue here seems to be a bug in Shadow. Prysm (or rather, the Go standard library) uses a protocol called Netlink to retrieve the local IP address. Shadow seems to have support for that, but due to a bug, parsing the header sent by Go fails. I guess that can be avoided by making Prysm skip the address lookup and use the one I anyways provided via CLI, but the goal is to make unmodified clients work. Oh well.
Unfortunately, adding Nethermind didn't work.
Nethermind immediately crashes with an obscure error message that reeks of Microsoft: Failed to create CoreCLR, HRESULT: 0x8007FF02
. A quick search reveals that the .NET runtime tries to allocate a single page of memory that can't be swapped to disk, and indeed, Shadow reports that the corresponding system call (mlock
) has been tried, but is not supported by Shadow yet. So yeah, support for that has to be added. Or .NET has to patched, which seems even more painful.
Besu was the most annoying to even attempt.
Shadow expects you to provide a path to an ELF binary, but Java compiles to Java bytecode. So the ELF binary in question would be java
, as provided by your favourite JRE implementation. Besu helpfully provides a script that builds the java
command and invokes it. For your reference, find below the full command that needs to be invoked by Shadow:
java -Dvertx.disableFileCPResolving=true -Dbesu.home=/home/daniel/tmp/besu-24.10.0 -Dlog4j.shutdownHookEnabled=false -Dlog4j2.formatMsgNoLookups=true -Djava.util.logging.manager=org.apache.logging.log4j.jul.LogManager --add-opens java.base/sun.security.provider=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED -Dio.netty.tryReflectionSetAccessible=true --add-exports java.base/jdk.internal.misc=ALL-UNNAMED --add-opens java.base/java.nio=ALL-UNNAMED -XX:G1ConcRefinementThreads=2 -XX:G1HeapWastePercent=15 -XX:MaxGCPauseMillis=100 -XX:StartFlightRecording,settings=default.jfc -Xlog:jfr*=off -classpath /home/daniel/tmp/besu-24.10.0/lib/besu-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-evmtool-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-ethereum-ethstats-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-clique-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-ibft-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-qbft-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-consensus-common-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-retesteth-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-ethereum-stratum-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-api-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-merge-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-blockcreation-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-eth-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-permissioning-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-p2p-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-plugin-rocksdb-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/referencetests-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-core-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/core-support-test-24.10.0-test-support.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-config-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-trie-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-crypto-services-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-pipeline-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-tasks-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-metrics-rocksdb-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-metrics-core-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-kvstore-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/plugin-api-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-evm-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-datatypes-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-pki-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/enclave-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-nat-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-util-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/oshi-core-6.6.3.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-crypto-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/core-4.12.1.jar:/home/daniel/tmp/besu-24.10.0/lib/dnsjava-3.6.1.jar:/home/daniel/tmp/besu-24.10.0/lib/tuweni-devp2p-2.4.2.jar:/home/daniel/tmp/besu-24.10.0/lib/org.jupnp.support-3.0.2.jar:/home/daniel/tmp/besu-24.10.0/lib/org.jupnp-3.0.2.jar:/home/daniel/tmp/besu-24.10.0/lib/client-java-18.0.1.jar:/home/daniel/tmp/besu-24.10.0/lib/log4j-slf4j2-impl-2.23.1.jar:/home/daniel/tmp/besu-24.10.0/lib/graphql-java-22.2.jar:/home/daniel/tmp/besu-24.10.0/lib/java-dataloader-3.3.0.jar:/home/daniel/tmp/besu-24.10.0/lib/crypto-4.12.1.jar:/home/daniel/tmp/besu-24.10.0/lib/Java-WebSocket-1.5.7.jar:/home/daniel/tmp/besu-24.10.0/lib/jose4j-0.9.3.jar:/home/daniel/tmp/besu-24.10.0/lib/slf4j-api-2.0.16.jar:/home/daniel/tmp/besu-24.10.0/lib/besu-ethereum-rlp-24.10.0.jar:/home/daniel/tmp/besu-24.10.0/lib/jackson-annotations-2.17.2.jar:/home/daniel/tmp/besu-24.10.0/lib/vertx-web-4.5.9.jar:/home/daniel/tmp/besu-24.10.0/lib/vertx-auth-jwt-4.5.9.jar:/home/daniel/tmp/besu-24.10.0/lib/vertx-unit-4.5.9.jar:/home/daniel/tmp/besu-24.10.0/lib/vertx-web-common-4.5.9.jar:/home/daniel/tmp/besu-24.10.0/lib/vertx-auth-common-4.5.9.jar:/home/daniel/tmp/besu-24.10.0/lib/vertx-bridge-common-4.5.9.jar:/home/daniel/tmp/besu-24.10.0/lib/vertx-lang-kotlin-coroutines-4.3.7.jar:/home/daniel/tmp/besu-24.10.0/lib/vertx-lang-kotlin-4.3.7.jar:/home/daniel/tmp/besu-24.10.0/lib/vertx-core-4.5.9.jar:/home/daniel/tmp/besu-24.10.0/lib/vertx-codegen-4.5.9.jar:/home/daniel/tmp/besu-24.10.0/lib/jackson-datatype-jdk8-2.17.2.jar:/home/daniel/tmp/besu-24.10.0/lib/jackson-core-2.17.2.jar:/home/daniel/tmp/besu-24.10.0/lib/jackson-databind-2.17.2.jar:/home/daniel/tmp/besu-24.10.0/lib/simpleclient_guava-0.16.0.jar:/home/daniel/tmp/besu-24.10.0/lib/tuweni-net-2.4.2.jar:/home/daniel/tmp/besu-24.10.0/lib/tuweni-crypto-2.4.2.jar:/home/daniel/tmp/besu-24.10.0/lib/tuweni-io-2.4.2.jar:/home/daniel/tmp/besu-24.10.0/lib/discovery-24.6.0.jar:/home/daniel/tmp/besu-24.10.0/lib/grpc-netty-1.66.0.jar:/home/daniel/tmp/besu-24.10.0/lib/grpc-util-1.66.0.jar:/home/daniel/tmp/besu-24.10.0/lib/grpc-core-1.66.0.jar:/home/daniel/tmp/besu-24.10.0/lib/tuweni-kademlia-2.4.2.jar:/home/daniel/tmp/besu-24.10.0/lib/grpc-context-1.66.0.jar:/home/daniel/tmp/besu-24.10.0/lib/grpc-api-1.66.0.jar:/home/daniel/tmp/besu-24.10.0/lib/guava-33.3.0-jre.jar:/home/daniel/tmp/besu-24.10.0/lib/dagger-2.52.jar:/home/daniel/tmp/besu-24.10.0/lib/picocli-4.7.6.jar:/home/daniel/tmp/besu-24.10.0/lib/maven-artifact-3.9.6.jar:/home/daniel/tmp/besu-24.10.0/lib/client-java-api-18.0.1.jar:/home/daniel/tmp/besu-24.10.0/lib/commons-compress-1.27.1.jar:/home/daniel/tmp/besu-24.10.0/lib/commons-lang3-3.17.0.jar:/home/daniel/tmp/besu-24.10.0/lib/log4j-core-2.23.1.jar:/home/daniel/tmp/besu-24.10.0/lib/tuweni-units-2.4.2.jar:/home/daniel/tmp/besu-24.10.0/lib/tuweni-rlp-2.4.2.jar:/home/daniel/tmp/besu-24.10.0/lib/tuweni-bytes-2.4.2.jar:/home/daniel/tmp/besu-24.10.0/lib/tuweni-config-2.4.2.jar:/home/daniel/tmp/besu-24.10.0/lib/tuweni-toml-2.4.2.jar:/home/daniel/tmp/besu-24.10.0/lib/spring-security-crypto-6.3.3.jar:/home/daniel/tmp/besu-24.10.0/lib/snappy-java-1.1.10.6.jar:/home/daniel/tmp/besu-24.10.0/lib/jc-kzg-4844-1.0.0.jar:/home/daniel/tmp/besu-24.10.0/lib/rocksdbjni-8.3.2.jar:/home/daniel/tmp/besu-24.10.0/lib/commons-net-3.11.1.jar:/home/daniel/tmp/besu-24.10.0/lib/log4j-jul-2.23.1.jar:/home/daniel/tmp/besu-24.10.0/lib/splunk-library-javalogging-1.11.8.jar:/home/daniel/tmp/besu-24.10.0/lib/jansi-2.4.1.jar:/home/daniel/tmp/besu-24.10.0/lib/value-annotations-2.10.1.jar:/home/daniel/tmp/besu-24.10.0/lib/bcpkix-jdk18on-1.78.1.jar:/home/daniel/tmp/besu-24.10.0/lib/abi-4.12.1.jar:/home/daniel/tmp/besu-24.10.0/lib/log4j-api-2.23.1.jar:/home/daniel/tmp/besu-24.10.0/lib/opentelemetry-extension-trace-propagators-1.41.0.jar:/home/daniel/tmp/besu-24.10.0/lib/opentelemetry-sdk-extension-autoconfigure-1.41.0.jar:/home/daniel/tmp/besu-24.10.0/lib/opentelemetry-exporter-otlp-1.41.0.jar:/home/daniel/tmp/besu-24.10.0/lib/opentelemetry-exporter-otlp-common-1.41.0.jar:/home/daniel/tmp/besu-24.10.0/lib/opentelemetry-exporter-sender-okhttp-1.41.0.jar:/home/daniel/tmp/besu-24.10.0/lib/opentelemetry-exporter-common-1.41.0.jar:/home/daniel/tmp/besu-24.10.0/lib/opentelemetry-sdk-extension-autoconfigure-spi-1.41.0.jar:/home/daniel/tmp/besu-24.10.0/lib/opentelemetry-sdk-1.41.0.jar:/home/daniel/tmp/besu-24.10.0/lib/opentelemetry-sdk-trace-1.41.0.jar:/home/daniel/tmp/besu-24.10.0/lib/opentelemetry-sdk-metrics-1.41.0.jar:/home/daniel/tmp/besu-24.10.0/lib/opentelemetry-sdk-logs-1.41.0.jar:/home/daniel/tmp/besu-24.10.0/lib/opentelemetry-sdk-common-1.41.0.jar:/home/daniel/tmp/besu-24.10.0/lib/opentelemetry-api-incubator-1.41.0-alpha.jar:/home/daniel/tmp/besu-24.10.0/lib/opentelemetry-api-1.41.0.jar:/home/daniel/tmp/besu-24.10.0/lib/antlr4-4.11.1.jar:/home/daniel/tmp/besu-24.10.0/lib/antlr4-runtime-4.11.1.jar:/home/daniel/tmp/besu-24.10.0/lib/bcutil-jdk18on-1.78.1.jar:/home/daniel/tmp/besu-24.10.0/lib/rlp-4.12.1.jar:/home/daniel/tmp/besu-24.10.0/lib/utils-4.12.1.jar:/home/daniel/tmp/besu-24.10.0/lib/bcprov-jdk18on-1.78.1.jar:/home/daniel/tmp/besu-24.10.0/lib/caffeine-3.1.8.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-all-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-transport-native-epoll-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-transport-native-epoll-4.1.112.Final-linux-x86_64.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-transport-native-epoll-4.1.112.Final-linux-aarch_64.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-transport-native-epoll-4.1.112.Final-linux-riscv64.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-transport-native-kqueue-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-transport-native-kqueue-4.1.112.Final-osx-x86_64.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-transport-native-kqueue-4.1.112.Final-osx-aarch_64.jar:/home/daniel/tmp/besu-24.10.0/lib/arithmetic-0.9.7.jar:/home/daniel/tmp/besu-24.10.0/lib/bls12-381-0.9.7.jar:/home/daniel/tmp/besu-24.10.0/lib/gnark-0.9.7.jar:/home/daniel/tmp/besu-24.10.0/lib/jna-platform-5.14.0.jar:/home/daniel/tmp/besu-24.10.0/lib/secp256k1-0.9.7.jar:/home/daniel/tmp/besu-24.10.0/lib/secp256r1-0.9.7.jar:/home/daniel/tmp/besu-24.10.0/lib/blake2bf-0.9.7.jar:/home/daniel/tmp/besu-24.10.0/lib/jna-5.14.0.jar:/home/daniel/tmp/besu-24.10.0/lib/tuweni-concurrent-coroutines-2.4.2.jar:/home/daniel/tmp/besu-24.10.0/lib/tuweni-concurrent-2.4.2.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-transport-classes-epoll-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-transport-classes-kqueue-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-codec-http2-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-handler-proxy-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-codec-http-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-resolver-dns-native-macos-4.1.112.Final-osx-x86_64.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-resolver-dns-native-macos-4.1.112.Final-osx-aarch_64.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-resolver-dns-classes-macos-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-resolver-dns-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-handler-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-transport-native-unix-common-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/simpleclient_pushgateway-0.16.0.jar:/home/daniel/tmp/besu-24.10.0/lib/simpleclient_httpserver-0.15.0.jar:/home/daniel/tmp/besu-24.10.0/lib/simpleclient_common-0.16.0.jar:/home/daniel/tmp/besu-24.10.0/lib/simpleclient_hotspot-0.16.0.jar:/home/daniel/tmp/besu-24.10.0/lib/simpleclient-0.16.0.jar:/home/daniel/tmp/besu-24.10.0/lib/commons-collections4-4.4.jar:/home/daniel/tmp/besu-24.10.0/lib/kotlinx-coroutines-core-jvm-1.6.4.jar:/home/daniel/tmp/besu-24.10.0/lib/logging-interceptor-4.12.0.jar:/home/daniel/tmp/besu-24.10.0/lib/okhttp-4.12.0.jar:/home/daniel/tmp/besu-24.10.0/lib/okio-jvm-3.6.0.jar:/home/daniel/tmp/besu-24.10.0/lib/kotlin-stdlib-jdk8-1.9.10.jar:/home/daniel/tmp/besu-24.10.0/lib/kotlin-stdlib-jdk7-1.9.10.jar:/home/daniel/tmp/besu-24.10.0/lib/kotlin-stdlib-2.0.20.jar:/home/daniel/tmp/besu-24.10.0/lib/encoder-1.3.1.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-tcnative-boringssl-static-2.0.66.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/opentelemetry-semconv-1.27.0-alpha.jar:/home/daniel/tmp/besu-24.10.0/lib/failureaccess-1.0.2.jar:/home/daniel/tmp/besu-24.10.0/lib/listenablefuture-9999.0-empty-to-avoid-conflict-with-guava.jar:/home/daniel/tmp/besu-24.10.0/lib/jsr305-3.0.2.jar:/home/daniel/tmp/besu-24.10.0/lib/checker-qual-3.43.0.jar:/home/daniel/tmp/besu-24.10.0/lib/gson-fire-1.8.5.jar:/home/daniel/tmp/besu-24.10.0/lib/gson-2.11.0.jar:/home/daniel/tmp/besu-24.10.0/lib/error_prone_annotations-2.28.0.jar:/home/daniel/tmp/besu-24.10.0/lib/jakarta.inject-api-2.0.1.jar:/home/daniel/tmp/besu-24.10.0/lib/javax.inject-1.jar:/home/daniel/tmp/besu-24.10.0/lib/rxjava-2.2.21.jar:/home/daniel/tmp/besu-24.10.0/lib/reactor-core-3.6.7.jar:/home/daniel/tmp/besu-24.10.0/lib/reactive-streams-1.0.4.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-codec-dns-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-codec-socks-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-codec-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-transport-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-buffer-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-resolver-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-common-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/framework-1.3.2.jar:/home/daniel/tmp/besu-24.10.0/lib/framework-internal-1.3.2.jar:/home/daniel/tmp/besu-24.10.0/lib/opentelemetry-context-1.41.0.jar:/home/daniel/tmp/besu-24.10.0/lib/tuples-4.12.1.jar:/home/daniel/tmp/besu-24.10.0/lib/jnr-unixsocket-0.38.22.jar:/home/daniel/tmp/besu-24.10.0/lib/ens-normalize-0.2.0.jar:/home/daniel/tmp/besu-24.10.0/lib/plexus-utils-3.5.1.jar:/home/daniel/tmp/besu-24.10.0/lib/simpleclient_tracer_otel-0.16.0.jar:/home/daniel/tmp/besu-24.10.0/lib/simpleclient_tracer_otel_agent-0.16.0.jar:/home/daniel/tmp/besu-24.10.0/lib/jnr-enxio-0.32.17.jar:/home/daniel/tmp/besu-24.10.0/lib/jnr-posix-3.1.19.jar:/home/daniel/tmp/besu-24.10.0/lib/jnr-ffi-2.2.16.jar:/home/daniel/tmp/besu-24.10.0/lib/commons-codec-1.16.0.jar:/home/daniel/tmp/besu-24.10.0/lib/annotations-13.0.jar:/home/daniel/tmp/besu-24.10.0/lib/perfmark-api-0.27.0.jar:/home/daniel/tmp/besu-24.10.0/lib/annotations-4.1.1.4.jar:/home/daniel/tmp/besu-24.10.0/lib/animal-sniffer-annotations-1.24.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-tcnative-classes-2.0.66.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-codec-haproxy-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-codec-memcache-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-codec-mqtt-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-codec-redis-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-codec-smtp-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-codec-stomp-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-codec-xml-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-handler-ssl-ocsp-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-transport-rxtx-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-transport-sctp-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/netty-transport-udt-4.1.112.Final.jar:/home/daniel/tmp/besu-24.10.0/lib/client-java-proto-18.0.1.jar:/home/daniel/tmp/besu-24.10.0/lib/snakeyaml-2.0.jar:/home/daniel/tmp/besu-24.10.0/lib/commons-io-2.16.1.jar:/home/daniel/tmp/besu-24.10.0/lib/protobuf-java-3.25.5.jar:/home/daniel/tmp/besu-24.10.0/lib/ST4-4.3.4.jar:/home/daniel/tmp/besu-24.10.0/lib/antlr-runtime-3.5.3.jar:/home/daniel/tmp/besu-24.10.0/lib/org.abego.treelayout.core-1.0.3.jar:/home/daniel/tmp/besu-24.10.0/lib/javax.json-1.1.4.jar:/home/daniel/tmp/besu-24.10.0/lib/icu4j-71.1.jar:/home/daniel/tmp/besu-24.10.0/lib/jnr-constants-0.10.4.jar:/home/daniel/tmp/besu-24.10.0/lib/simpleclient_tracer_common-0.16.0.jar:/home/daniel/tmp/besu-24.10.0/lib/javax.annotation-api-1.3.2.jar:/home/daniel/tmp/besu-24.10.0/lib/swagger-annotations-1.6.9.jar:/home/daniel/tmp/besu-24.10.0/lib/jffi-1.3.13.jar:/home/daniel/tmp/besu-24.10.0/lib/jffi-1.3.13-native.jar:/home/daniel/tmp/besu-24.10.0/lib/asm-commons-9.2.jar:/home/daniel/tmp/besu-24.10.0/lib/asm-util-9.2.jar:/home/daniel/tmp/besu-24.10.0/lib/asm-analysis-9.2.jar:/home/daniel/tmp/besu-24.10.0/lib/asm-tree-9.2.jar:/home/daniel/tmp/besu-24.10.0/lib/asm-9.2.jar:/home/daniel/tmp/besu-24.10.0/lib/jnr-a64asm-1.0.0.jar:/home/daniel/tmp/besu-24.10.0/lib/jnr-x86asm-1.0.2.jar org.hyperledger.besu.Besu --genesis-file=/home/daniel/epf/ethshadow/data/metadata/besu.json --data-path=/home/daniel/epf/ethshadow/data/node6/besu --engine-rpc-port=21001 --engine-jwt-secret=/home/daniel/epf/ethshadow/data/jwt/jwtsecret --rpc-http-enabled --rpc-http-host=0.0.0.0 --rpc-http-port=22001 --p2p-port=21000 --p2p-host=29.251.164.100 --bootnodes=enode://16fd559ea375237cc5f3886ce971bce7b6781ab7e4a41276b4cb104ba6dca1650565bd92f19689a01548c38573237086cb585016b0afe0581b5d7248e9c59097@84.100.74.176:0?discport=30305
…yeah. As you can see, there are absolute paths and version numbers everywhere, and I am certainly not reimplementing this just for it to break on the next Besu update.
So I did the following: I noticed that the script invokes the command using the shell builtin exec
. And after a lot of trial and error, I figured out a way to make the exec
print instead of executing the command:
That actually works, and now I can let Besu's script build the full command for me to use in Shadow's config (I just append the CLI parameters), and even if they update the script, the simulator will automatically adjust in most cases. Neat! I think this again shows that Ethshadow is way easier than writing Shadow configuration yourself.
…however, Besu (or some library or the JVM) tries to use SO_REUSEPORT
, my nemesis which already made unstable Lighthouse unusable without modifications a few weeks ago.
So unfortunately, adding Besu didn't work.
This was a bit frustrating, but oh well. Time is short, so I can't spend any time to properly fix any of those :(
Next week I'll focus on finishing the documentation (finally) and starting to prepare my project report for Devcon!