Statesync

  • Network Type: Mainnet
  • Chain-id: mucoin-1
  • Current Node version: rewards-v0.8.0
  • sudo systemctl stop mucoind
    cp $HOME/.mucoin/data/priv_validator_state.json $HOME/.mucoin/priv_validator_state.json.backup
    mucoind comet unsafe-reset-all --home $HOME/.mucoin --keep-addr-book
    SNAP_RPC="https://rpc.mucoin.org:443"
    LATEST_HEIGHT=$(curl -s $SNAP_RPC/block | jq -r .result.block.header.height); \
    BLOCK_HEIGHT=$((LATEST_HEIGHT - 1000))
    TRUST_HASH=$(curl -s "$SNAP_RPC/block?height=$BLOCK_HEIGHT" | jq -r .result.block_id.hash)
    sed -i \
    -e "s|^enable *=.*|enable = true|" \
    -e "s|^rpc_servers *=.*|rpc_servers = \"$SNAP_RPC,$SNAP_RPC\"|" \
    -e "s|^trust_height *=.*|trust_height = $BLOCK_HEIGHT|" \
    -e "s|^trust_hash *=.*|trust_hash = \"$TRUST_HASH\"|" \
    $HOME/.mucoin/config/config.toml
    mv $HOME/.mucoin/priv_validator_state.json.backup $HOME/.mucoin/data/priv_validator_state.json
    sudo systemctl restart mucoind
    sudo journalctl -u mucoind -f -o cat