logo

Chain Database Snapshot

Darwinia provides node database snapshots for node maintainers, facilitating a quick start for a node without syncing from the genesis block. The archive node snapshot contains the state of the blockchain at a certain block height, allowing the node to start from that point instead of starting from the genesis block. Node maintainers can download the latest archive node snapshot and start a node instantly, significantly reducing the block syncing time from several days to about 30 minutes.

Available Snapshots

The number in the file names indicates the block height of the snapshot. For example, the block number of snapshot darwinia2-883924.tar.zst is 883924.

Usage

  1. Install zstd
    1. shell
      # Debian, Ubuntu apt install zstd # CentOS, Rad Hat dnf install zstd # Arch Linux pacman -S zstd
  1. Download the snapshot archive and extract
    1. Copy the archive URL to the specific snapshot(Latest Snapshot recommended) and run the following command:
      shell
      wget -c https://snapshots.darwinia.network/darwinia-xxxx.tar.zst mkdir -p /path/to/chain-dir tar xv --zstd -f darwinia2-xxxx.tar.zst -C /path/to/chain-dir
      It's worth noting that /path/to/chain-dir depends on two factors:
      • the node CLI option -base.
      • the chain name.
      For example, assume with --base data, the chain dirs for the networks are:
      • Darwinia Network: data/chains/darwinia2
      • Crab Network: data/chains/crab2
  1. Start node
    1. Once you have placed these extracted database files in the correct locations, then you can start your node either a full node or an archive node, by following the other tutorials.