-
Notifications
You must be signed in to change notification settings - Fork 181
Open
Labels
Type: TaskDiscrete task to implementDiscrete task to implement
Description
Forest uses checkpoints to improve performance when loading a snapshot. Without checkpoints, the blockchain has to be fully traversed to verify we have the right genesis block. Checkpoints short-circuit this search and shave off tens of minutes in boot time.
Checkpoints have to be regularly updated, though, and this issue is automatically created once per month. Follow the procedure below to update build/known_blocks.yaml, and close this issue.
Procedure
#!/bin/bash
# Perform this for `calibnet` AND `mainnet`
chains=("mainnet" "calibnet")
for chain in "${chains[@]}"
do
# download the latest snapshot.
# =============================
# - calibnet ~3G, ~1min on a droplet
# - mainnet ~60G, ~15mins on a droplet
aria2c -x5 https://forest-archive.chainsafe.dev/latest/"$chain"/ -o "$chain"
# print out the checkpoints.
# ==========================
# The whole operation takes a long time, BUT you only need the first line or so.
timeout 15s forest-tool archive checkpoints "$chain"
done
# Update `build/known_blocks.yaml` as appropriate, manually.Metadata
Metadata
Assignees
Labels
Type: TaskDiscrete task to implementDiscrete task to implement
Type
Projects
Status
New