Skip to content

Commit 92fefb7

Browse files
committed
add history pruning and retention epochs
1 parent 525434b commit 92fefb7

File tree

4 files changed

+24
-4
lines changed

4 files changed

+24
-4
lines changed

.env.sample.holesky

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,11 @@ COMPOSE_FILE=compose-el.yml:compose-cl.yml:compose-vc.yml:compose-mev.yml:docker
5656
#NETHERMIND_ANCIENT_BODIES_BARRIER=
5757
#NETHERMIND_ANCIENT_RECEIPTS_BARRIER=
5858

59+
# History pruning (EXPERIMENTAL as of v1.33+).
60+
# History.Pruning options: Disabled (default), Rolling, UseAncientBarriers.
61+
#NETHERMIND_HISTORY_PRUNING=Rolling
62+
#NETHERMIND_HISTORY_RETENTION_EPOCHS=82125
63+
5964
######### Consensus Layer Config #########
6065

6166
# CL beacon node host exposed ports.

.env.sample.hoodi

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,14 @@ COMPOSE_FILE=compose-el.yml:compose-cl.yml:compose-vc.yml:compose-mev.yml:docker
5353
#RETH_VERSION=
5454

5555
# Nethermind ancient barrier allows you to specify how many old block bodies and receipts you want to store.
56-
#NETHERMIND_ANCIENT_BODIES_BARRIER=
57-
#NETHERMIND_ANCIENT_RECEIPTS_BARRIER=
56+
# Recommended: 1500000 for hoodi testnet.
57+
NETHERMIND_ANCIENT_BODIES_BARRIER=1500000
58+
NETHERMIND_ANCIENT_RECEIPTS_BARRIER=1500000
59+
60+
# History pruning (EXPERIMENTAL as of v1.33+).
61+
# History.Pruning options: Disabled (default), Rolling, UseAncientBarriers.
62+
NETHERMIND_HISTORY_PRUNING=Rolling
63+
NETHERMIND_HISTORY_RETENTION_EPOCHS=82125
5864

5965
######### Consensus Layer Config #########
6066

.env.sample.mainnet

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,15 @@ COMPOSE_FILE=compose-el.yml:compose-cl.yml:compose-vc.yml:compose-mev.yml:docker
5353
#RETH_VERSION=
5454

5555
# Nethermind ancient barrier allows you to specify how many old block bodies and receipts you want to store.
56-
#NETHERMIND_ANCIENT_BODIES_BARRIER=
57-
#NETHERMIND_ANCIENT_RECEIPTS_BARRIER=
56+
# Recommended: 20000000 for mainnet.
57+
NETHERMIND_ANCIENT_BODIES_BARRIER=20000000
58+
NETHERMIND_ANCIENT_RECEIPTS_BARRIER=20000000
59+
60+
# History pruning (EXPERIMENTAL as of v1.33+).
61+
# History.Pruning options: Disabled (default), Rolling, UseAncientBarriers.
62+
# Keeps approximately 1 year of history (82125 epochs minimum for mainnet).
63+
NETHERMIND_HISTORY_PRUNING=Rolling
64+
NETHERMIND_HISTORY_RETENTION_EPOCHS=82125
5865

5966
######### Consensus Layer Config #########
6067

compose-el.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,8 @@ services:
3535
--Sync.SnapSync=true
3636
--Sync.AncientBodiesBarrier=${NETHERMIND_ANCIENT_BODIES_BARRIER:-0}
3737
--Sync.AncientReceiptsBarrier=${NETHERMIND_ANCIENT_RECEIPTS_BARRIER:-0}
38+
--History.Pruning=${NETHERMIND_HISTORY_PRUNING:-Disabled}
39+
--History.RetentionEpochs=${NETHERMIND_HISTORY_RETENTION_EPOCHS:-82125}
3840
--TxPool.BlobsSupport=Disabled
3941
networks: [dvnode]
4042
volumes:

0 commit comments

Comments
 (0)