CryptoNodeID
  • Introduction
  • Basics
    • Server Preparation
    • Setting up DNS
    • Routing using NGINX
    • Setting up SSL
    • Security Setup
  • Advance
    • Proxmox Setup with 1 Public IP
  • Mainnet
    • Humanode
      • Installation
      • Node Activation
      • Monitoring
    • CrossFi
      • Endpoints and Sync
      • Installation
      • Validator Setup
      • Cheat Sheet
  • Testnet
    • Airchain
      • Endpoints and Sync
      • Installation
      • Validator Setup
    • Cortensor
      • Installation
      • Multiple Node Setup
        • VM Method
        • Docker Method
    • CrossFi
      • Endpoints and Sync
      • Installation
      • Validator Setup
      • Cheat Sheet
      • User ITN Guide
    • Empeiria
      • Endpoints and Sync
      • Installation
      • Validator Setup
      • Cheat Sheet
    • Ethereum and Arbitrum Sepolia
      • Installation
    • Symphony
      • Endpoints and Sync
      • Installation
      • Validator Setup
      • Cheat Sheet
    • NuLink
    • Shardeum
    • Warden Protocol
      • Endpoints and Sync
      • Installation
      • Validator Setup
      • Cheat Sheet
  • Supporting Tools
    • Cosmos Explorer
      • Installation
  • Archived
    • Galactica
      • Endpoints and Sync
      • Installation
    • Initia
      • Endpoints and Sync
      • Installation
    • Mantrachain
      • Endpoints and Sync
      • Installation
    • Side Protocol
      • Endpoints and Sync
      • Installation
    • Stratis EVM
Powered by GitBook
On this page
  • State Sync
  • Snapshot Restore

Was this helpful?

  1. Testnet
  2. Warden Protocol

Endpoints and Sync

PreviousWarden ProtocolNextInstallation

Last updated 9 months ago

Was this helpful?

RPC:

API:

Peers
85abfb1a10ef88d37277e7462830890ff2f7a1ac@sentry1.cryptonode.id:24656,400195374c9bde32385a4398719ba3f529066569@sentry2.cryptonode.id:24656

State Sync

DAEMON_HOME="${HOME}/.warden"
SERVICE_NAME="wardend"

sudo systemctl stop ${SERVICE_NAME}

cp ${DAEMON_HOME}/data/priv_validator_state.json ${DAEMON_HOME}/data/priv_validator_state.json.backup
cp ${DAEMON_HOME}/config/priv_validator_key.json ${DAEMON_HOME}/config/priv_validator_key.json.backup

wardend tendermint unsafe-reset-all --home ${DAEMON_HOME}

PEERS="85abfb1a10ef88d37277e7462830890ff2f7a1ac@sentry1.cryptonode.id:24656,400195374c9bde32385a4398719ba3f529066569@sentry2.cryptonode.id:24656,92ba004ac4bcd5afbd46bc494ec906579d1f5c1d@52.30.124.80:26656,ed5781ea586d802b580fdc3515d75026262f4b9d@54.171.21.98:26656"
SNAP_RPC="https://warden-testnet-rpc.cryptonode.id:443"

sed -i.bak -e "s/^persistent_peers *=.*/persistent_peers = \"$PEERS\"/" ${DAEMON_HOME}/config/config.toml 
LATEST_HEIGHT=$(curl -s $SNAP_RPC/block | jq -r .result.block.header.height);
BLOCK_HEIGHT=$((LATEST_HEIGHT - 5000));
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\"|" \
  -e "s|^.*seeds *=.*|seeds = \"\"|" \
  ${DAEMON_HOME}/config/config.toml
  
mv ${DAEMON_HOME}/data/priv_validator_state.json.backup ${DAEMON_HOME}/data/priv_validator_state.json
mv ${DAEMON_HOME}/config/priv_validator_key.json.backup ${DAEMON_HOME}/config/priv_validator_key.json

sudo systemctl restart ${SERVICE_NAME}
sudo journalctl -fu ${SERVICE_NAME} --no-hostname -o cat

Snapshot Restore

DAEMON_HOME=$HOME/.warden
SERVICE_NAME=wardend
NETWORK=warden-testnet

sudo systemctl stop ${SERVICE_NAME}
cp ${DAEMON_HOME}/data/priv_validator_state.json ${DAEMON_HOME}/priv_validator_state.json.backup
rm -rf ${DAEMON_HOME}/data
mkdir -p ${DAEMON_HOME}/data

SNAP_NAME=$(curl -s https://snapshot.cryptonode.id/${NETWORK}/ | egrep -o ">${NETWORK}-snapshot.*\.tar.lz4" | tr -d ">")
curl https://snapshot.cryptonode.id/${NETWORK}/${SNAP_NAME} | lz4 -dc - | tar -xf - -C ${DAEMON_HOME}/data
mv ${DAEMON_HOME}/priv_validator_state.json.backup ${DAEMON_HOME}/data/priv_validator_state.json

sudo systemctl restart ${SERVICE_NAME}
sudo journalctl -fu ${SERVICE_NAME} --no-hostname -o cat
https://warden-testnet-rpc.cryptonode.id
https://warden-testnet-api.cryptonode.id