Links

Pruning module

Configuration of the pruning parameters (pruning is the process of removing some of the intermediary state nodes - it saves some disk space but makes most of the historical state queries fail).
Property
Env Variable
Description
Default
CacheMb
NETHERMIND_PRUNINGCONFIG_CACHEMB
'Memory' pruning: Pruning cache size in MB (amount if historical nodes data to store in cache - the bigger the cache the bigger the disk space savings).
1024
FullPruningCompletionBehavior
NETHERMIND_PRUNINGCONFIG_FULLPRUNINGCOMPLETIONBEHAVIOR
Determines what to do after Nethermind completes a full prune. 'None': does not take any special action. 'ShutdownOnSuccess': shuts Nethermind down if the full prune succeeded. 'AlwaysShutdown': shuts Nethermind down once the prune completes, whether it succeeded or failed.
None
FullPruningDisableLowPriorityWrites
NETHERMIND_PRUNINGCONFIG_FULLPRUNINGDISABLELOWPRIORITYWRITES
Full pruning uses low priority writes to prevent blocking block processing. If not needed, set this to true for faster full pruning.
false
FullPruningMaxDegreeOfParallelism
NETHERMIND_PRUNINGCONFIG_FULLPRUNINGMAXDEGREEOFPARALLELISM
'Full' pruning: Defines how many parallel tasks and potentially used threads can be created by full pruning. 0 - number of logical processors, 1 - full pruning will run on single thread. Recommended value depends on the type of the node. If the node needs to be responsive (its RPC or Validator node) then recommended value is below the number of logical processors. If the node doesn't have much other responsibilities but needs to be reliably be able to follow the chain without any delays and produce live logs - the default value is recommended. If the node doesn't have to be responsive, has very fast I/O (like NVME) and the shortest pruning time is to be achieved, this can be set to 2-3x of the number of logical processors.
0
FullPruningMemoryBudgetMb
NETHERMIND_PRUNINGCONFIG_FULLPRUNINGMEMORYBUDGETMB
Set the memory budget used for the trie visit. Increasing this significantly reduces read iops requirement at expense of RAM. Default depend on network. Set to 0 to disable.
0
FullPruningMinimumDelayHours
NETHERMIND_PRUNINGCONFIG_FULLPRUNINGMINIMUMDELAYHOURS
In order to not exhaust disk writes, there is a minimum delay between allowed full pruning operations.
240
FullPruningThresholdMb
NETHERMIND_PRUNINGCONFIG_FULLPRUNINGTHRESHOLDMB
'Full' pruning: Defines threshold in MB to trigger full pruning, depends on 'Mode' and 'FullPruningTrigger'.
256000
FullPruningTrigger
NETHERMIND_PRUNINGCONFIG_FULLPRUNINGTRIGGER
'Full' pruning: Defines trigger for full pruning, manuel trigger is always supported via admin_prune RPC call. Either size of StateDB or free space left on Volume where StateDB is located can be configured as auto triggers. Possible values: 'Manual', 'StateDbSize', 'VolumeFreeSpace'.
Manual
Mode
NETHERMIND_PRUNINGCONFIG_MODE
Sets pruning mode. Possible values: 'None', 'Memory', 'Full', 'Hybrid'.
Hybrid
PersistenceInterval
NETHERMIND_PRUNINGCONFIG_PERSISTENCEINTERVAL
'Memory' pruning: Defines how often blocks will be persisted even if not required by cache memory usage (the bigger the value the bigger the disk space savings)
8192