Pruning and full node are new features of Reth, and we will be happy to hear about your experience using them either on GitHub or in the Telegram group.
By default, Reth runs as an archive node. Such nodes have all historical blocks and the state at each of these blocks available for querying and tracing.
Reth also supports pruning of historical data and running as a full node. This chapter will walk through the steps for running Reth as a full node, what caveats to expect and how to configure your own pruned node.
- Archive node – Reth node that has all historical data from genesis.
- Pruned node – Reth node that has its historical data pruned partially or fully through a custom configuration.
- Full Node – Reth node that has the latest state and historical data for only the last 10064 blocks available for querying in the same way as an archive node.
The node type that was chosen when first running a node can not be changed after the initial sync. Turning Archive into Pruned, or Pruned into Full is not supported.
Default mode, follow the steps from the previous chapter on how to run on mainnet or official testnets.
To run Reth as a pruned node configured through a custom configuration,
modify the reth.toml
file and run Reth in the same way as archive node by following the steps from
the previous chapter on how to run on mainnet or official testnets.
To run Reth as a full node, follow the steps from the previous chapter on
how to run on mainnet or official testnets, and add a --full
flag. For example:
reth node \
--full \
--authrpc.jwtsecret /path/to/secret \
--authrpc.addr 127.0.0.1 \
--authrpc.port 8551
All numbers are as of April 2024 at block number 19.6M for mainnet.
Archive node occupies at least 2.14TB.
You can track the growth of Reth archive node size with our public Grafana dashboard.
Different segments take up different amounts of disk space. If pruned fully, this is the total freed space you'll get, per segment:
Segment | Size |
---|---|
Sender Recovery | 85GB |
Transaction Lookup | 200GB |
Receipts | 250GB |
Account History | 235GB |
Storage History | 590GB |
Full node occupies at least 1.13TB.
Essentially, the full node is the same as following configuration for the pruned node:
[prune]
block_interval = 5
[prune.parts]
sender_recovery = "full"
# transaction_lookup is not pruned
receipts = { before = 11052984 } # Beacon Deposit Contract deployment block: https://etherscan.io/tx/0xe75fb554e433e03763a1560646ee22dcb74e5274b34c5ad644e7c0f619a7e1d0
account_history = { distance = 10_064 }
storage_history = { distance = 10_064 }
[prune.parts.receipts_log_filter]
# Prune all receipts, leaving only those which contain logs from address `0x00000000219ab540356cbb839cbe05303d7705fa`,
# starting from the block 11052984. This leaves receipts with the logs from the Beacon Deposit Contract.
"0x00000000219ab540356cbb839cbe05303d7705fa" = { before = 11052984 }
Meaning, it prunes:
- Account History and Storage History up to the last 10064 blocks
- All of Sender Recovery data. The caveat is that it's pruned gradually after the initial sync is completed, so the disk space is reclaimed slowly.
- Receipts up to the last 10064 blocks, preserving all receipts with the logs from Beacon Deposit Contract
As it was mentioned in the pruning configuration chapter, there are several segments which can be pruned independently of each other:
- Sender Recovery
- Transaction Lookup
- Receipts
- Account History
- Storage History
Pruning of each of these segments disables different RPC methods, because the historical data or lookup indexes become unavailable.
The following tables describe RPC methods available in the full node.
RPC | Note |
---|---|
debug_getRawBlock |
|
debug_getRawHeader |
|
debug_getRawReceipts |
Only for the last 10064 blocks and Beacon Deposit Contract |
debug_getRawTransaction |
|
debug_traceBlock |
Only for the last 10064 blocks |
debug_traceBlockByHash |
Only for the last 10064 blocks |
debug_traceBlockByNumber |
Only for the last 10064 blocks |
debug_traceCall |
Only for the last 10064 blocks |
debug_traceCallMany |
Only for the last 10064 blocks |
debug_traceTransaction |
Only for the last 10064 blocks |
RPC / Segment | Note |
---|---|
eth_accounts |
|
eth_blockNumber |
|
eth_call |
Only for the last 10064 blocks |
eth_chainId |
|
eth_createAccessList |
Only for the last 10064 blocks |
eth_estimateGas |
Only for the last 10064 blocks |
eth_feeHistory |
|
eth_gasPrice |
|
eth_getBalance |
Only for the last 10064 blocks |
eth_getBlockByHash |
|
eth_getBlockByNumber |
|
eth_getBlockReceipts |
Only for the last 10064 blocks and Beacon Deposit Contract |
eth_getBlockTransactionCountByHash |
|
eth_getBlockTransactionCountByNumber |
|
eth_getCode |
|
eth_getFilterChanges |
|
eth_getFilterLogs |
Only for the last 10064 blocks and Beacon Deposit Contract |
eth_getLogs |
Only for the last 10064 blocks and Beacon Deposit Contract |
eth_getStorageAt |
Only for the last 10064 blocks |
eth_getTransactionByBlockHashAndIndex |
|
eth_getTransactionByBlockNumberAndIndex |
|
eth_getTransactionByHash |
|
eth_getTransactionCount |
Only for the last 10064 blocks |
eth_getTransactionReceipt |
Only for the last 10064 blocks and Beacon Deposit Contract |
eth_getUncleByBlockHashAndIndex |
|
eth_getUncleByBlockNumberAndIndex |
|
eth_getUncleCountByBlockHash |
|
eth_getUncleCountByBlockNumber |
|
eth_maxPriorityFeePerGas |
|
eth_mining |
|
eth_newBlockFilter |
|
eth_newFilter |
|
eth_newPendingTransactionFilter |
|
eth_protocolVersion |
|
eth_sendRawTransaction |
|
eth_sendTransaction |
|
eth_sign |
|
eth_signTransaction |
|
eth_signTypedData |
|
eth_subscribe |
|
eth_syncing |
|
eth_uninstallFilter |
|
eth_unsubscribe |
RPC / Segment |
---|
net_listening |
net_peerCount |
net_version |
RPC / Segment | Note |
---|---|
trace_block |
Only for the last 10064 blocks |
trace_call |
Only for the last 10064 blocks |
trace_callMany |
Only for the last 10064 blocks |
trace_get |
Only for the last 10064 blocks |
trace_rawTransaction |
Only for the last 10064 blocks |
trace_replayBlockTransactions |
Only for the last 10064 blocks |
trace_replayTransaction |
Only for the last 10064 blocks |
trace_transaction |
Only for the last 10064 blocks |
RPC / Segment |
---|
txpool_content |
txpool_contentFrom |
txpool_inspect |
txpool_status |
The following tables describe the requirements for prune segments, per RPC method:
- ✅ – if the segment is pruned, the RPC method still works
- ❌ - if the segment is pruned, the RPC method doesn't work anymore
RPC / Segment | Sender Recovery | Transaction Lookup | Receipts | Account History | Storage History |
---|---|---|---|---|---|
debug_getRawBlock |
✅ | ✅ | ✅ | ✅ | ✅ |
debug_getRawHeader |
✅ | ✅ | ✅ | ✅ | ✅ |
debug_getRawReceipts |
✅ | ✅ | ❌ | ✅ | ✅ |
debug_getRawTransaction |
✅ | ❌ | ✅ | ✅ | ✅ |
debug_traceBlock |
✅ | ✅ | ✅ | ❌ | ❌ |
debug_traceBlockByHash |
✅ | ✅ | ✅ | ❌ | ❌ |
debug_traceBlockByNumber |
✅ | ✅ | ✅ | ❌ | ❌ |
debug_traceCall |
✅ | ✅ | ✅ | ❌ | ❌ |
debug_traceCallMany |
✅ | ✅ | ✅ | ❌ | ❌ |
debug_traceTransaction |
✅ | ✅ | ✅ | ❌ | ❌ |
RPC / Segment | Sender Recovery | Transaction Lookup | Receipts | Account History | Storage History |
---|---|---|---|---|---|
eth_accounts |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_blockNumber |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_call |
✅ | ✅ | ✅ | ❌ | ❌ |
eth_chainId |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_createAccessList |
✅ | ✅ | ✅ | ❌ | ❌ |
eth_estimateGas |
✅ | ✅ | ✅ | ❌ | ❌ |
eth_feeHistory |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_gasPrice |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_getBalance |
✅ | ✅ | ✅ | ❌ | ✅ |
eth_getBlockByHash |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_getBlockByNumber |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_getBlockReceipts |
✅ | ✅ | ❌ | ✅ | ✅ |
eth_getBlockTransactionCountByHash |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_getBlockTransactionCountByNumber |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_getCode |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_getFilterChanges |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_getFilterLogs |
✅ | ✅ | ❌ | ✅ | ✅ |
eth_getLogs |
✅ | ✅ | ❌ | ✅ | ✅ |
eth_getStorageAt |
✅ | ✅ | ✅ | ✅ | ❌ |
eth_getTransactionByBlockHashAndIndex |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_getTransactionByBlockNumberAndIndex |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_getTransactionByHash |
✅ | ❌ | ✅ | ✅ | ✅ |
eth_getTransactionCount |
✅ | ✅ | ✅ | ❌ | ✅ |
eth_getTransactionReceipt |
✅ | ❌ | ❌ | ✅ | ✅ |
eth_getUncleByBlockHashAndIndex |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_getUncleByBlockNumberAndIndex |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_getUncleCountByBlockHash |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_getUncleCountByBlockNumber |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_maxPriorityFeePerGas |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_mining |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_newBlockFilter |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_newFilter |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_newPendingTransactionFilter |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_protocolVersion |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_sendRawTransaction |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_sendTransaction |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_sign |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_signTransaction |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_signTypedData |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_subscribe |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_syncing |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_uninstallFilter |
✅ | ✅ | ✅ | ✅ | ✅ |
eth_unsubscribe |
✅ | ✅ | ✅ | ✅ | ✅ |
RPC / Segment | Sender Recovery | Transaction Lookup | Receipts | Account History | Storage History |
---|---|---|---|---|---|
net_listening |
✅ | ✅ | ✅ | ✅ | ✅ |
net_peerCount |
✅ | ✅ | ✅ | ✅ | ✅ |
net_version |
✅ | ✅ | ✅ | ✅ | ✅ |
RPC / Segment | Sender Recovery | Transaction Lookup | Receipts | Account History | Storage History |
---|---|---|---|---|---|
trace_block |
✅ | ✅ | ✅ | ❌ | ❌ |
trace_call |
✅ | ✅ | ✅ | ❌ | ❌ |
trace_callMany |
✅ | ✅ | ✅ | ❌ | ❌ |
trace_get |
✅ | ❌ | ✅ | ❌ | ❌ |
trace_rawTransaction |
✅ | ✅ | ✅ | ❌ | ❌ |
trace_replayBlockTransactions |
✅ | ✅ | ✅ | ❌ | ❌ |
trace_replayTransaction |
✅ | ❌ | ✅ | ❌ | ❌ |
trace_transaction |
✅ | ❌ | ✅ | ❌ | ❌ |
RPC / Segment | Sender Recovery | Transaction Lookup | Receipts | Account History | Storage History |
---|---|---|---|---|---|
txpool_content |
✅ | ✅ | ✅ | ✅ | ✅ |
txpool_contentFrom |
✅ | ✅ | ✅ | ✅ | ✅ |
txpool_inspect |
✅ | ✅ | ✅ | ✅ | ✅ |
txpool_status |
✅ | ✅ | ✅ | ✅ | ✅ |