Bare metal for chain nodes: NVMe, filesystems, kernel tuning, and colocation tradeoffs

Chain state is random-read and write-amplifying, so NVMe endurance and latency dominate. On your own hardware you own the telemetry — and time-to-restore is the number that matters.

Read the briefing
About 4 min to read 7 drills

What to remember

  1. Specify drives by DWPD and sustained IOPS. Consumer SSDs die in months under node write amplification. Treat disks as consumables.
  2. Single-thread speed beats core count for execution. Block execution is largely serial; extra cores help concurrency, not sync.
  3. Raise LimitNOFILE and UDP buffers or you drop peers. Defaults are for laptops. UdpRcvbufErrors is the counter that proves it.
  4. Monitor what the cloud would hide. NVMe wear, ECC correctable errors, BMC events, thermal throttling.
  5. Know your time-to-restore, and rehearse it. Automated snapshot restore under two hours, tested monthly — not a resync from genesis you have never tried.

The big picture

Chain nodes are one of the few workloads left where hardware choices dominate software tuning. State databases are random-read and write-amplifying, execution is single-thread sensitive, gossip protocols are packet-rate heavy, and validators care about wall-clock timing. This topic covers NVMe and filesystems, CPU and memory selection, the kernel tuning that is actually required, the cloud-versus-colocation tradeoff, and how hardware failure is handled when it is your hardware.

The mental model

Follow the bottleneck: for RPC and execution it is almost always storage IOPS and latency, then single-core speed, then RAM for caching. For validators it is timing and network reliability. Cloud hides hardware but charges for the IOPS you need; bare metal gives you the hardware and hands you its failures.

In depth

Storage: the thing that decides everything

Chain state is a large key-value database (LSM or B-tree) with random reads at head and heavy writes during sync and compaction. The requirement is NVMe with high sustained random IOPS, low latency, and real endurance: consumer drives with low DWPD fail within months under a node's write amplification, and a drive that throttles under sustained writes turns a two-hour snapshot restore into a day. Choose the filesystem deliberately (ext4 and xfs are both used; the important part is the mount options, discard/trim behaviour, and avoiding surprises like atime updates and copy-on-write filesystems that fight LSM compaction). RAID mirrors buy availability but not IOPS headroom in the way people expect; for many operators, faster rebuild from a snapshot beats mirroring, and that is a decision to make explicitly. Watch nvme smart-log wear and media errors as first-class metrics: a node's disk is a consumable.

CPU, memory, and the network

Block execution is largely serial, so high single-thread performance beats core count for execution clients; extra cores help with parallel sync phases, RPC concurrency, and running consensus and execution clients together. Memory buys state cache: enough RAM to hold the hot working set turns random disk reads into memory hits, which is the cheapest performance you can buy after storage. For validators, timing matters, attestations are due within seconds, so clock discipline (chrony/NTP) is a correctness-adjacent concern, and network reliability beats raw bandwidth. Gossip-heavy chains (Solana in particular) are packet-rate bound, needing large UDP buffers, high interrupt handling capacity, and NICs that can cope; a default kernel will drop packets long before the link is saturated.

Kernel tuning, hosting choices, and failure

The tuning that is genuinely required is short and boring: LimitNOFILE in the hundreds of thousands (nodes hold thousands of peer connections plus database files), raised net.core.rmem_max/wmem_max and socket buffers for gossip, a deliberate swap policy (usually off for validators, so failure is fast and visible), NVMe-appropriate I/O scheduler and readahead, and TasksMax/LimitMEMLOCK where the client needs them. Defaults are tuned for general-purpose machines, not for a process writing gigabytes an hour.

Cloud versus bare metal: cloud gives elasticity, fast rebuilds, and no hardware handling, at a large premium for sustained IOPS and egress, both of which this workload consumes heavily. Bare metal and colocation give much better price-performance, dedicated hardware (no steal time, no noisy neighbours) and predictable latency, at the cost of lead time, hands-on failure handling, and capacity that cannot be returned. Most serious operators mix: bare metal for steady-state RPC and validators, cloud for burst, staging, and geographic reach, and they place validators differently from RPC nodes because the failure costs differ.

Failure handling on your own hardware means monitoring what a cloud would hide: NVMe wear and media errors, ECC memory correctable-error rates (a rising rate predicts failure), BMC/IPMI events, thermal throttling, and PSU/fan alarms. The operational number that matters is time to restore a node from nothing, which should be automated, measured, and rehearsed.

Myths and facts

Myth: Any SSD is fine; they are all fast.

Fact: Sustained random IOPS, latency under load, and endurance (DWPD) vary enormously; consumer drives fail early under node write amplification.

Myth: More cores make a node sync faster.

Fact: Execution is largely serial; single-thread speed and storage dominate, with extra cores helping concurrency and parallel phases.

Myth: Cloud is simpler, so it is the right default for nodes.

Fact: It is simpler operationally but expensive for sustained IOPS and egress; the right answer is usually a deliberate mix, argued with numbers.

Myth: RAID protects the node, so hardware failure is handled.

Fact: RAID covers a drive failure but not corruption, host failure, or wear; a tested rebuild-from-snapshot path is what actually bounds downtime.

Myth: Kernel defaults are fine; tuning is premature optimization.

Fact: File descriptor limits and UDP buffers are not optimizations; without them nodes drop peers and packets under normal load.

How pros do it

  • Specify NVMe by sustained random IOPS, latency, and DWPD; monitor wear and media errors as node health.
  • Prefer high single-thread performance and enough RAM to hold the hot state; keep clocks disciplined on validators.
  • Apply the required kernel settings as code: LimitNOFILE, UDP buffers, swap policy, scheduler/readahead.
  • Decide hosting per role with a cost model; keep validators and RPC nodes on different failure domains.
  • Automate rebuild-from-snapshot, measure time-to-restore, and rehearse it; monitor BMC, ECC, and thermal signals.

Questions people ask

Should validators run in the cloud?

They can, but say why you would not by default: steal time, noisy neighbours, and shared failure domains matter more for validators than for RPC nodes. The credible answer is bare metal for validators in two facilities with cloud for redundancy elsewhere, and a reason for each placement.

How do I size disk for a node?

Current state size for the client and sync mode, plus growth over your retention horizon, plus temporary space for compaction or a restore; alert at 70% and rebuild before 90%. Quote a measured figure with a date, not a remembered one.

What hardware metrics should page someone?

Rising ECC correctable errors, NVMe media errors or wear approaching threshold, thermal throttling, and PSU or fan failures. Add that each runbook ends in a planned replacement rather than a surprise; that clause is what separates owning hardware from merely having it.

Is ext4 or xfs better for chain state?

Both work; say that consistency and mount options matter more than the choice. Mention noatime, deliberate discard/trim behaviour, and avoiding copy-on-write filesystems for LSM workloads unless you have measured them.

Why is my Solana node dropping gossip packets on an idle link?

UDP receive buffers and interrupt handling, not bandwidth. Name the counter that proves it (UdpRcvbufErrors), then the fix: raise net.core.rmem_max and the client's buffer settings, and check per-CPU softirq load.

Further reading

Drills · 7

Answer in your head, or out loud, before you reveal. Mark each one: "Again" brings it back, "Got it" counts on your desk.

1 Pick the strongest answer

For an execution client, would you rather have a 64-core cloud instance with network-attached storage or a 16-core bare-metal box with local NVMe? Why?

  1. The cloud instance, because snapshots are easier. Convenience is real but does not change the performance argument; snapshots work on bare metal too.
  2. The bare-metal box: execution is largely serial so single-thread speed matters more than core count, and local NVMe latency beats network-attached storage for the random reads that dominate; the cloud instance also pays for cores the workload cannot use. Storage latency and single-thread performance are the two bottlenecks; core count is not.
  3. They are equivalent if IOPS are provisioned equally. Provisioned IOPS do not equal local NVMe latency, and the price difference is large.
  4. The cloud instance: more cores always help sync. Block execution does not parallelize across 64 cores.
In short

The bare-metal box: block execution is mostly serial, and local NVMe beats network storage for random reads.

Why

This is the standard hardware question in web3 infra interviews. The strong answer names the bottleneck (storage latency, then single-thread speed), notes the cost asymmetry for sustained IOPS, and adds that cloud still earns its place for burst, staging, and geographic spread.

The common mistake

Arguing from core count or from snapshot convenience. Block execution is largely serial, and provisioned IOPS do not equal local NVMe latency.

Read the docs

2 Answer out loud

You are asked whether to run the node fleet on cloud instances or on colocated bare metal. Make the argument with a cost and risk model, and say what you would put where. Five to seven sentences.

In short

A strong answer argues from the bottleneck: sustained NVMe IOPS, latency and egress are exactly what cloud charges a premium for.

What a strong answer does
  • analysis: Names the workload bottlenecks (sustained IOPS, egress, single-thread), compares on those axes with rough numbers, and separates roles (validators, RPC, burst, staging).
  • risk: Covers failure domains, correlated wear, rebuild time, lead time for capacity, and provider concentration risk.
  • decision: Recommends a deliberate mix with reasons per role, plus the conditions that would change the decision.
  • communication: Bottleneck → cost model → placement per role → risks → revisit trigger.
Why

The rubric rewards deriving the answer from the workload's bottlenecks, quantifying roughly, differentiating placement by role, naming the operational risks bare metal transfers to you, and stating what would change the decision.

The common mistake

Picking one side. The credible answer is a deliberate mix, with validators and RPC placed differently because their failure costs differ.

3 Pick the strongest answer

A team runs archive nodes on consumer NVMe and the drives keep dying after four to six months. What is going on?

  1. Chain state workloads write far more than they appear to (compaction and write amplification), so a low-endurance consumer drive burns through its rated writes quickly; the fix is enterprise NVMe specified by DWPD and sustained IOPS. Endurance is a specified quantity; node write amplification consumes it fast.
  2. The filesystem is wrong; switch to xfs. Filesystem choice matters at the margin, not by a factor of years of endurance.
  3. Archive nodes should use spinning disks for durability. HDDs cannot serve the random IOPS an archive node needs.
  4. The drives are overheating because of the chassis. Thermals can throttle performance, but consistent multi-month failure points at wear.
In short

Chain state writes far more than it looks, so low-endurance drives wear out; buy enterprise NVMe rated by DWPD.

Why

Specify drives by sustained random IOPS, latency under load, and DWPD, then monitor nvme smart-log percentage-used and media errors so replacement is planned. Treating the disk as a consumable with a lifetime is the operational shift.

Read the docs

4 Find what's broken

This provisioning role will produce slow nodes and long outages. Which four entries would you fix first?

# provisioning role for chain nodes (excerpt)
storage:
  device: /dev/nvme0n1
  filesystem: ext4
  mount_options: "defaults,strictatime"
  raid: none
  monitoring: ["disk_free_percent"]
sysctl:
  vm.swappiness: 60
  net.core.rmem_max: 212992
systemd_unit:
  LimitNOFILE: 1000000
  Restart: always
rebuild: { method: "resync from genesis", tested: never }
In short

Line 14 rebuilds by resyncing from genesis, line 7 monitors only free space, line 10 leaves UDP buffers at default, and line 5 mounts with strictatime.

What's broken
  • Line 14: Rebuild is a full resync from genesis and has never been tested, so losing a node means days of downtime discovered during an incident.
  • Line 7: Only disk_free_percent is monitored: NVMe wear, media errors, ECC, and thermal events are invisible, so hardware fails as a surprise.
  • Line 10: net.core.rmem_max left at the default is far too small for gossip-heavy chains, causing UDP receive-buffer drops.
  • Line 5: strictatime forces an atime write on every read, adding pointless write amplification to an already write-heavy workload.
Why

ext4 (line 4) is a fine choice, no RAID (line 6) is legitimate when rebuild-from-snapshot is fast, swappiness 60 (line 9) is a default worth revisiting but not the top problem, and Restart=always is reasonable. The untested rebuild path is the biggest operational risk here: everything else degrades performance, that one determines outage length.

Read the docs

5 Scenario: what do you do next?

One of six bare-metal RPC nodes shows rising p99 read latency over three days. Disk usage is 62%, CPU is normal, and the node is still in rotation serving traffic.

Step 1. First checks?

  1. Hardware health and I/O saturation together: nvme smart-log (percentage used, media and error-log entries), dmesg for NVMe or controller resets, iostat -xz for await and queue depth, and temperature/throttling from the BMC. Rising latency on one node with normal CPU points at the device; the counters distinguish wear, errors, and thermal throttling.
  2. Restart the node process. Does not address hardware and loses the evidence trail.
  3. Reduce the node's cache settings. Tuning a symptom before identifying the device problem.
  4. Assume it is the workload and rebalance traffic away permanently. Ejecting is a reasonable mitigation, but the cause must still be found before the same drive model fails elsewhere.

Step 2. smart-log shows percentage_used at 94% and a rising media error count; dmesg has two controller resets. Mitigation?

  1. Replace the drive during the next maintenance window in three weeks. 94% wear plus media errors plus resets is not a three-week problem.
  2. Drain the node out of rotation now, snapshot or copy what is useful, replace the drive (or the host), and rebuild from the tested snapshot path; check the same metric across the fleet because the other drives are the same age and model. Removes the failing node from serving, and treats the fleet-wide correlation immediately.
  3. Keep it serving until it fails; there are five other nodes. It is already returning degraded latency to customers, and failure during a busy period is worse.
  4. Move the whole fleet to cloud instances. A strategic change proposed as an incident response.

Step 3. Systemic follow-up?

  1. Wear and error metrics scraped fleet-wide with alerts at thresholds, a lifecycle policy that replaces drives before end-of-life, staggered purchase dates to avoid correlated wear, and the rebuild path exercised monthly. Turns a surprise into scheduled maintenance and breaks the correlation between identical drives bought together.
  2. Add a seventh node for redundancy. Capacity does not address a predictable, correlated wear-out.
  3. Buy spare drives and keep them on a shelf. Useful, but without monitoring you still find out by failing.
In short

Check the drive first: nvme smart-log wear and errors, dmesg for controller resets, and iostat for queue and wait times.

Why

Owning hardware means owning its telemetry and lifecycle. The interview signal is treating drives as consumables with monitored wear, recognizing correlated failure across a batch, and having a rebuild path that is measured rather than assumed.

Read the docs

6 Quick recall

When you spec NVMe for chain nodes, which rating tells you how long a drive will last under the write load?

In short

DWPD, or the equivalent TBW rating.

Accepted

DWPD · drive writes per day · endurance

Why

DWPD (drive writes per day) or the equivalent TBW rating; node compaction and write amplification consume endurance far faster than a general-purpose workload.

7 Read the output

Two configuration problems are visible in this output. What are they, and how do you fix them?

$ journalctl -u validator | tail -2
agave-validator: dropped 41,882 packets in last 60s
agave-validator: Too many open files (os error 24)
$ cat /proc/net/udp | wc -l
412
$ sysctl net.core.rmem_max net.core.wmem_max
net.core.rmem_max = 212992
net.core.wmem_max = 212992
$ grep 'open files' /proc/$(pgrep -o agave-validator)/limits
Max open files            1024                 1024                 files
$ nstat -az | grep -i udp | head -3
UdpInErrors                     1284410
UdpRcvbufErrors                 1284002
  1. UDP receive buffers are at the 208 KB default (rmem_max) while the gossip workload needs far more (Solana documents 128 MB), causing RcvbufErrors and dropped packets; and the process's open-file limit is 1024 instead of the hundreds of thousands a validator needs. Raise net.core.rmem_max/wmem_max and set LimitNOFILE in the unit. UdpRcvbufErrors tracks the drops exactly, and the limits file shows the descriptor cap.
  2. The network link is saturated; upgrade the NIC. Buffer errors, not link saturation; the kernel is dropping before the application reads.
  3. Too many UDP sockets are open; reduce peers. 412 sockets is unremarkable; the buffers and descriptor limit are the constraints.
  4. The validator has a memory leak causing packet loss. Nothing indicates memory pressure; the counters name the cause.
In short

UDP buffers are at the small default and the open-file limit is 1024; raise rmem_max and wmem_max and set LimitNOFILE in the unit.

Why

These two settings are the required tuning for gossip-heavy chains, not optional optimization. UdpRcvbufErrors is the counter that proves buffers are the cause; the process's own limits file is the authority on descriptors, not the shell's ulimit.

Read the docs

Next lesson Chain-aware monitoring: height and lag, peers, reorgs, missed duties, and the SLOs that matter
Drill · Bare metal for chain nodes
0:00

Loading…