Stop bandd and reset database
Copy sudo systemctl stop bandd
cp $HOME /.band/data/priv_validator_state.json $HOME /.band/priv_validator_state.json.backup
bandd tendermint unsafe-reset-all --home $HOME /.band --keep-addr-book
Copy STATE_SYNC_RPC = https://rpc.cosmos.directory:443/bandchain
BACKUP_RPC = https://bandchain-rpc.lavenderfive.com:443
LATEST_HEIGHT = $( curl -s $STATE_SYNC_RPC /block | jq -r .result.block.header.height )
BLOCK_HEIGHT = $( echo LATEST_HEIGHT | awk '{print $1 - ($1 % 6000)}' ); \
TRUST_HASH = $( curl -s "$STATE_SYNC_RPC/block?height=$BLOCK_HEIGHT" | jq -r .result.block_id.hash )
SEEDS="8d42bdcb6cced03e0b67fa3957e4e9c8fd89015a@34.87.86.195:26656,543e0cab9c3016a0e99775443a17bcf163038912@34.150.156.78:26656,2c884e60a0944958a2a9389f07f2f66dcfc3add0@seeds-bandprotocol.activenodes.io:36656,ebc272824924ea1a27ea3183dd0b9ba713494f83@bandchain-mainnet-seed.autostake.com:26666,4ded49b3a718828eb64cf35da1ed791ecb201bc1@seed-band-01.stakeflow.io:25017,400f3d9e30b69e78a7fb891f60d76fa3c73f0ecc@band.rpc.kjnodes.com:16959,8542cd7e6bf9d260fef543bc49e59be5a3fa9074@seed.publicnode.com:26656,08bc9afd0cac4ae6cf8f1877920b0cc7e58a6f42@seeds.tendermint.roomit.xyz:40000,10ed1e176d874c8bb3c7c065685d2da6a4b86475@seed-band.ibs.team:16672"
echo -e "Modifying $HOME/.band/config/config.toml based on the following values:"
echo -e "RPC Address: $STATE_SYNC_RPC"
echo -e "Latest Block Height: $LATEST_HEIGHT"
echo -e "Sync Block Height: $BLOCK_HEIGHT"
echo -e "Trust Hash: $TRUST_HASH"
sed -i \
-e "s|^enable *=.*|enable = true|" \
-e "s|^rpc_servers *=.*|rpc_servers = \"$STATE_SYNC_RPC,$BACKUP_RPC\"|" \
-e "s|^trust_height *=.*|trust_height = $BLOCK_HEIGHT|" \
-e "s|^trust_hash *=.*|trust_hash = \"$TRUST_HASH\"|" \
-e "s|^seeds *=.*|seeds = \"$SEEDS\"|" \
$HOME /.band/config/config.toml
mv $HOME /.band/priv_validator_state.json.backup $HOME /.band/data/priv_validator_state.json
Copy curl -L https://snapshots.lavenderfive.com/wasm/ $HOME /.band/wasmonly.tar.zst | tar -xaf - -C $HOME /.band
Restart bandd and check the log
Copy sudo systemctl restart bandd && sudo journalctl -u bandd -f --no-hostname -o cat