Chain Data Snapshots
A snapshot is a recording of the state of a blockchain at a particular block height.
Latest snapshot: download (91 GB, md5sum 0b23a48b0d6585690350e91b0f6c9f14)
The following commands are step by step instructions for TomoChain Masternode operators that can be used for two major use-cases:
  1. 1.
    Fixing nodes that are stuck; evidenced by a node that stays on a block and doesn't progress
  2. 2.
    Jumpstarting a newly setup Masternode; avoid waiting a week for synchronization
Basically, a compressed version of the last-known "good" chaindata is downloaded. This comes from TomoChain on a weekly basis. Remove the node's old data and update it with the newly downloaded data. Finally, restart the sync-process from this known-good checkpoint.
Note: Ensure there is enough disk space for both the tar file AND its uncompressed contents. Double the space or more.
1
# Login as user that has access to tmn
2
# Download Tomo's chaindata archive (make sure you have enough disk space available)
3
wget -c https://chaindata.tomochain.com/20190813.tar -P /tmp
4
5
# Stop your node (for tmn users)
6
tmn stop
7
# or in the node folder (for docker-compose users)
8
docker-compose stop
9
10
# Find the name of your volume
11
docker volume ls
12
13
# Remove your node old data
14
sudo rm -rf /var/lib/docker/volumes/NAME_OF_YOUR_VOLUME/_data/data/tomo/chaindata
15
16
# Find the name of your volume
17
docker volume ls
18
19
# Extract the data
20
cd /tmp
21
sudo tar xvC /var/lib/docker/volumes/NAME_OF_YOUR_VOLUME/_data/data/tomo/ -f 20190813.tar
22
23
# Start your node back(for tmn users)
24
tmn start
25
# or in the node folder (for docker-compose users)
26
docker-compose start
27
28
# If you're really running out of space, remove the tar file
29
# keeping it might be a good idea if you get stuck further before a new snapshot is released
30
rm /tmp/20190813.tar
Copied!
Tip: extract the data in background
In case you can not wait for the extraction finish, you can run it in the background
1
nohup tar xvC /var/lib/docker/volumes/NAME_OF_YOUR_VOLUME/_data/data/tomo/ -f 20190813.tar &
Copied!
Last modified 1yr ago
Copy link