Skip to content

Commit df1fe2f

Browse files
committed
Document history expiry
1 parent 16d389d commit df1fe2f

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

92 files changed

+1071
-592
lines changed

website/docs/Support/HelpfulWebsites.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Helpful Websites
3-
sidebar_position: 13
3+
sidebar_position: 12
44
sidebar_label: Helpful Websites
55
---
66

website/docs/Support/Prune.md

Lines changed: 0 additions & 27 deletions
This file was deleted.

website/docs/Support/Windows.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Windows
3-
sidebar_position: 12
3+
sidebar_position: 11
44
sidebar_label: Windows
55
---
66

website/docs/Support/ipv6.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: IPv6
3-
sidebar_position: 11
3+
sidebar_position: 10
44
sidebar_label: IPv6 support
55
---
66

website/docs/Usage/Dashboards.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: "Choose a Grafana dashboard (optional)"
3-
sidebar_position: 7
3+
sidebar_position: 8
44
sidebar_label: Dashboards
55
---
66

website/docs/Usage/Hardware.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Resources, hardware
3-
sidebar_position: 3
3+
sidebar_position: 4
44
sidebar_label: Hardware
55
---
66

website/docs/Usage/ImportKeys.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: "Create and import validator keys to the client"
3-
sidebar_position: 2
3+
sidebar_position: 3
44
sidebar_label: Import Validator Keys
55
---
66

website/docs/Usage/LinuxSecurity.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Linux security and setup recommendations
3-
sidebar_position: 5
3+
sidebar_position: 6
44
sidebar_label: Linux Security
55
---
66

website/docs/Usage/Networking.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title: Networking and port forwarding
3-
sidebar_position: 4
3+
sidebar_position: 5
44
sidebar_label: Network configuration
55
---
66

website/docs/Usage/NodeTypes.md

Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
---
2+
title: Archive, Full or Expired node
3+
sidebar_position: 2
4+
sidebar_label: History and Pruning
5+
---
6+
7+
## Types of nodes
8+
9+
You can run an Archive node, with all history and full lookup for all historical transactions. This may take large amounts of space, depending on the execution layer client.
10+
11+
You can run a Full node, with all history and limited lookup for historical transactions. This fits into a 4TB drive and is often the choice for RPC nodes.
12+
13+
You can run an Expired node, with pre-merge history and receipts gone. This fits into a 2TB drive and is foten the choice for validator nodes.
14+
15+
This is controlled by variables in `.env`, which can be set with `nano .env`. Switching from one type to another often requires a full resync.
16+
17+
`CL_ARCHIVE_NODE` - run the consensus layer node as an archive, including blobs where supported
18+
`CL_MINIMAL_NODE` - run the consensus layer node with minimal storage
19+
20+
`EL_ARCHIVE_NODE` - run the execution layer node as an archive. The required space can vary widely depending on the client: From right around 2 TB to well over 50TB
21+
`EL_MINIMAL_NODE` - run the execution layer node with history expiry. `true` is pre-merge history expiry; `rolling` is 1-year rolling if the client supports it;
22+
`aggressive` expires all but the last few blocks, if the client supoorts it
23+
24+
## Switch from Full to Expired node
25+
26+
You can use `./ethd prune-history` to switch the client to history expiry, in some cases without resync. Note that Besu requires 200 GiB free for this, and
27+
it will take less space if instead it is resynced with `./ethd resync-execution` while `EL_MINIMAL_NODE=true`
28+
29+
## State pruning
30+
31+
In addition to history, execution layer clients also carry state. Historically, the size of the state DB has been growing and can be pruned periodically.
32+
Today, only Nethermind still requires a state prune. Note this is entirely separate from history expiry. It applies to Full and Expired nodes. Archive
33+
nodes should never have their state pruned.
34+
35+
### Automatic Nethermind prune
36+
37+
By default, Nethermind will prune when free disk space falls below 350 GiB on mainnet, or 50 GiB on testnet. If you
38+
want to disable that, `nano .env` and change `AUTOPRUNE_NM` to `false`.
39+
40+
If you have disabled automatic prune, you can run `./ethd prune-nethermind`. It will check prerequisites, online prune Nethermind, and restart it.
41+
42+
### Continuous Besu prune
43+
44+
Besu continuously prunes with BONSAI, and from 24.1.0 on also prunes its trie-logs. A long-running Besu may benefit
45+
from a manual trie-log prune, once.
46+
47+
If you have a large amount of trie logs, run `./ethd prune-besu` on a long-running Besu. It will check prerequisites, offline prune Besu trie-logs, and
48+
restart it.
49+
50+
### Continuous Geth prune
51+
52+
Geth continuously prunes if synced with PBSS. If you are using an old hash-synced Geth, run `./ethd resync-execution`
53+
to use PBSS. This will cause downtime while Geth syncs, which can take 6-12 hours.

0 commit comments

Comments
 (0)