Files are compressed with the Zstandard compression algorithm.
ZStandard can be installed using your platforms' package manager, such as apt or brew:
- Ubuntu: apt install zstd
- MacOS: brew install zstd
Snapshots are taken daily, and are available in the applicable blockchain directory below. A history of 1 week of snapshots is maintained on this archive.
Backups are broken in to 3 seperate files to minimize bandwidth utilization and transfer times, and are updated weekly. Backups are maintained in the blockchain directory, under /backup
- latest.snapshot.[nodeos version].tar.zst | Contains the snapshot taken at the time of /blocks and /state-history directory backup.
- latest.blocks.backup.[nodeos version].tar.zst | Contains a portable /blocks directory backup from chain genesis.
- latest.state-history.backup.[nodeos version].tar.zst | Contains a portable /state-history directory backup from chain genesis.
File generation
The snapshot is taken while the nodeos instance is running. Nodeos is allowed to run for 90 seconds after snapshot generation, before the node is stopped.
/blocks and /state-history backups are taken from the stopped nodeos instance.
Decompression can be performed with tar and zstd: tar --use-compress-program=unzstd -xvf [archive].tar.zst
To restore a nodeos Producer, API and P2P node with no block history, restore the following backup files:
- Download latest.snapshot.[nodeos version].tar.zst, latest.blocks.backup.[nodeos version].tar.zst, and latest.state-history.backup.[nodeos version].tar.zst files to your nodeos data directory.
- Remove the nodeos /snapshots directory, if it exists.
- Remove the nodeos /blocks directory, if it exists.
- Remove the nodeos /state-history directory, if it exists.
- Remove the nodeos /state directory, if it exists.
- Extract any applicable snapshot file to the nodeos /snapshots directory using tar and zstd: tar --use-compress-program=unzstd -xvf [snapshot file].tar.zst
- Start your nodeos instance with the --snapshot option, and pointing to the correct nodeos /snapshot directory and file.
To restore a nodeos Producer, API and P2P node with full block history, restore the following backup files:
- Download latest.snapshot.[nodeos version].tar.zst, latest.blocks.backup.[nodeos version].tar.zst, and latest.state-history.backup.[nodeos version].tar.zst files to your nodeos data directory.
- Remove the nodeos /snapshots directory, if it exists.
- Remove the nodeos /blocks directory, if it exists.
- Remove the nodeos /state-history directory, if it exists.
- Remove the nodeos /state directory, if it exists.
- Extract the latest.snapshot.[nodeos version].tar.zst file using tar and zstd: tar --use-compress-program=unzstd -xvf latest.snapshot.[nodeos version].tar.zst
- Extract the latest.blocks.backup.[nodeos version].tar.zst file using tar and zstd: tar --use-compress-program=unzstd -xvf latest.blocks.backup.[nodeos version].tar.zst
- Start your nodeos instance with the --snapshot option, and pointing to the correct nodeos /snapshot directory and file.
To restore a nodeos Producer, API, and P2P node with full block history, restore the following backup files:
- Download latest.snapshot.[nodeos version].tar.zst, latest.blocks.backup.[nodeos version].tar.zst, and latest.state-history.backup.[nodeos version].tar.zst files to your nodeos data directory.
- Remove the nodeos /snapshots directory, if it exists.
- Remove the nodeos /blocks directory, if it exists.
- Remove the nodeos /state-history directory, if it exists.
- Remove the nodeos /state directory, if it exists.
- Extract the latest.snapshot.[nodeos version].tar.zst file using tar and zstd: tar --use-compress-program=unzstd -xvf latest.snapshot.[nodeos version].tar.zst
- Extract the latest.blocks.backup.[nodeos version].tar.zst file using tar and zstd: tar --use-compress-program=unzstd -xvf latest.blocks.backup.[nodeos version].tar.zst
- Start your nodeos instance with the --snapshot option, and pointing to the correct nodeos /snapshot directory and file.
To restore a nodeos Producer, API, P2P, and State History node with full block history, restore the following backup files:
- Download latest.snapshot.[nodeos version].tar.zst, latest.blocks.backup.[nodeos version].tar.zst, and latest.state-history.backup.[nodeos version].tar.zst files to your nodeos data directory.
- Remove the nodeos /snapshots directory, if it exists.
- Remove the nodeos /blocks directory, if it exists.
- Remove the nodeos /state-history directory, if it exists.
- Remove the nodeos /state directory, if it exists.
- Extract the latest.snapshot.[nodeos version].tar.zst file using tar and zstd: tar --use-compress-program=unzstd -xvf latest.snapshot.[nodeos version].tar.zst
- Extract the latest.blocks.backup.[nodeos version].tar.zst file using tar and zstd: tar --use-compress-program=unzstd -xvf latest.blocks.backup.[nodeos version].tar.zst
- Extract the latest.state-history.backup.[nodeos version].tar.zst file using tar: tar --use-compress-program=unzstd -xvf latest.state-history.backup.[nodeos version].tar.zst
- Start your nodeos instance with the --snapshot option, and pointing to the correct nodeos /snapshot directory and file.
To restore and unpack a backup file on the fly to a custom location:
- curl https://archive.pdx.cryptobloks.io/snapshots/[path]/[file name].tar.zst | tar -I zstd -xvf - -C /your/path/here
Snapshots and backup files:
Techncial Information:
- Mainnet: chain-state-db-size-mb = 32768
- Testnet: chain-state-db-size-mb = 16384