diff --git a/default.env b/default.env index 55221ffb..b74bdbe7 100644 --- a/default.env +++ b/default.env @@ -201,13 +201,15 @@ LODESTAR_HEAP= # "pruned-with-zkproofs" is experimental and will not work with the standard client builds # For a more granular way to handle it, please use CL_EXTRAS in combination with "full" CL_NODE_TYPE=pruned -# EL_NODE_TYPE can be "archive", "full", "pre-merge-expiry", "aggressive-expiry" or "rolling-expiry" -# "pre-merge-expiry" is only meaningful for mainnet and sepolia, may fail on hoodi +# EL_NODE_TYPE can be "archive", "full", "pre-merge-expiry", "pre-cancun-expiry", +# "aggressive-expiry" or "rolling-expiry" +# "pre-merge-expiry" is only meaningful for mainnet and sepolia # Switching node type typically requires a resync # Consider using `./ethd prune-history`, which guides you as to whether to prune in-place # or resync, depending on client # "aggressive-expiry" is supported with Erigon -# "rolling-expiry" is a Nethermind feature, waiting for PR 2263 to do anything +# "rolling-expiry" and "pre-cancun-expiry" are Nethermind features, for now +# "rolling-expiry" remains experimental in Nethermind as of Dec 29th 2025 EL_NODE_TYPE=pre-merge-expiry # Era URLs, see https://eth-clients.github.io/history-endpoints/ # Note that this will be replaced with EraE sometime 2026, possibly still Q1 2026 diff --git a/ethd b/ethd index 616b70ad..e900b66d 100755 --- a/ethd +++ b/ethd @@ -2833,9 +2833,9 @@ prune-history() { ;; *nethermind.yml*) client="Nethermind" - min_ver="v1.31.9" - extra_msg="To prune pre-merge history, a full resync is required, which should take 1-2 hours to where attestations work.\nYou can use https://rescuenode.com to keep attesting during resync." - prune_marker="" + min_ver="v1.35.2" + extra_msg="Pruning pre-merge history does not require a resync and should be immediate." + prune_marker="/var/lib/nethermind/minimal-node" ;; *besu.yml*) client="Besu" diff --git a/nethermind/docker-entrypoint.sh b/nethermind/docker-entrypoint.sh index 17a2318b..da783e91 100755 --- a/nethermind/docker-entrypoint.sh +++ b/nethermind/docker-entrypoint.sh @@ -104,16 +104,37 @@ case "${NODE_TYPE}" in case "${NETWORK}" in mainnet) echo "Nethermind minimal node with pre-merge history expiry" - __prune+=" --Sync.AncientBodiesBarrier=15537394 --Sync.AncientReceiptsBarrier=15537394" + __prune+=" --Sync.AncientBodiesBarrier=15537394 --Sync.AncientReceiptsBarrier=15537394 --History.Pruning=UseAncientBarriers" ;; sepolia) echo "Nethermind minimal node with pre-merge history expiry" + __prune+=" --Sync.AncientBodiesBarrier=1450408 --Sync.AncientReceiptsBarrier=1450408 --History.Pruning=UseAncientBarriers" ;; *) echo "There is no pre-merge history for ${NETWORK} network, \"pre-merge-expiry\" has no effect." ;; esac ;; + pre-cancun-expiry) + case "${NETWORK}" in + mainnet) + echo "Nethermind minimal node with pre-Cancun history expiry" + __prune+=" --Sync.AncientBodiesBarrier=19426587 --Sync.AncientReceiptsBarrier=19426587 --History.Pruning=UseAncientBarriers" + ;; + sepolia) + echo "Nethermind minimal node with pre-Cancun history expiry" + __prune+=" --Sync.AncientBodiesBarrier=5187023 --Sync.AncientReceiptsBarrier=5187023 --History.Pruning=UseAncientBarriers" + ;; + *) + echo "There is no pre-Cancun history for ${NETWORK} network, \"pre-cancun-expiry\" has no effect." + ;; + esac + ;; + rolling-expiry) + echo "Nethermind minimal node with rolling history expiry, keeps 1 year by default." + echo "\"EL_EXTRAS=--history-retentionepochs \" in \".env\" can override, minimum are 82125." + __prune+=" --History.Pruning=Rolling" + ;; *) echo "ERROR: The node type ${NODE_TYPE} is not known to Eth Docker's Nethermind implementation." sleep 30