Skip to main content

Zetachain

Download daily snapshot:

LATEST HEIGHTSIZECHAIN IDPRUNINGDATETIMELINK
600984644.2Gzetachain_7000-1full2024-12-0407:39:59s3://sc-snapshots/zetachain_7000-1_2024-12-04.tar.gz

s5cmd Installation

  1. Install s5cmd client:
wget https://github.com/peak/s5cmd/releases/download/v2.2.2/s5cmd_2.2.2_Linux-64bit.tar.gz
tar -xf s5cmd_2.2.2_Linux-64bit.tar.gz
rm s5cmd_2.2.2_Linux-64bit.tar.gz
  1. Configure s3 bucket access:
cat <<EOF > s5cmd-r2.cfg
[default]
aws_access_key_id = 6b4b819da0d66d9ddf7bb37520c46a16
aws_secret_access_key = ab2dc9b991f4b5055787e8ba9c09c8b4ceb3e183561fbfa7f6475f23fa474766
aws_region = auto
host_base = dd74dc687a5ce54107082a6849814c19.r2.cloudflarestorage.com
host_bucket = dd74dc687a5ce54107082a6849814c19.r2.cloudflarestorage.com
enable_multipart = True
EOF
Our tips

We have tested two ways of downloading files.

a) Download and unpack the files to the destination folder directly. You will have unpacked files in the target directory, but only with single download session. b) Download the archive in several concurent sessions. In this case you can get more speed(depends from your uplink), but need double space.

Download Instructions

  1. Backup priv_validator_state.json:
cp $HOME/.zetacored/data/priv_validator_state.json $HOME/priv_validator_state.json
  1. Stop zetacored service
systemctl stop zetacored
  1. Delete data directory:
rm -rf ~/.zetacored/data/

3.a Download bor snapshot in a single session and unpack to target folder:

./s5cmd --credentials-file ~/s5cmd-r2.cfg --endpoint-url https://dd74dc687a5ce54107082a6849814c19.r2.cloudflarestorage.com cat --raw s3://sc-snapshots/zetachain_7000-1_2024-11-24.tar.gz | sudo tar -zxvf - -C ~/.zetacored/ 

3.b Download bor snapshot in multisession mode:

./s5cmd --credentials-file ~/s5cmd-r2.cfg --endpoint-url https://dd74dc687a5ce54107082a6849814c19.r2.cloudflarestorage.com cp --show-progress --concurrency 50 s3://sc-snapshots/zetachain_7000-1_2024-11-24.tar.gz ~/.zetacored/
  1. Start zetacored service
systemctl start zetacored