Services
  • 𝐥𝐞𝐬𝐧𝐢𝐤 | 𝐔𝐓𝐒𝐀
  • 🌐Cosmos WIKI
    • 🔧Creating / Editing a Validator
    • 📨Cosmos / governance
    • 🛠️Useful commands
    • 🔨Changing ports in the Cosmos ecosystem
    • 🌁IBC (HERMES)
    • ⚒️Node-exporter + Grafana + Prometheus + Alertmanager
    • ⚒️TenderDuty v2 - monitoring and alerting
  • Mainnet
    • Arkeo
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Atomone
      • 💻Installation
      • ⌚State sync
      • ⌚Snapshots
      • 📬Updates
    • Aura
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Dora Factory
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Dymension
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Genesis L1
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Gitopia
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Jackal
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Konstellation
      • 💻Installation
      • ⌚Snapshot
      • 📬Updates
    • Nibiru
      • 💻Installation
      • ⌚State sync
      • 📬Updates
      • 📬Price feeder (✔️Oracle)
    • Provenance
      • 💻Installation
      • 📬Updates
    • Teritori
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Quicksilver
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Uptick
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Source protocol
      • 💻Installation
      • 📬Updates
    • Zenrock
      • 💻Installation
      • 💻Sidecar (✔️Oracle)
      • 💻Create a validator
      • ⌚State sync
      • ⌚Snapshot
      • 📬Updates
  • TESTNET
    • Atomone
      • 💻Installation
      • 📬Updates
    • Airchains
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Aura
      • 💻Installation
      • 📬Updates
    • Arkeo
      • 💻Installation
      • ⌚State sync
      • 📬Updates
      • 📬Providers
    • AXON PROTOCOL
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Dora Factory
      • 💻Installation
      • 📬Updates
    • Dymension
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Empeiria
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Galactica
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Jackal
      • 💻Installation
      • 📬Updates
    • Kira
      • 💻Installation
    • PRYSM
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Source protocol
      • 💻Installation
      • 📬Updates
    • Story Protocol
      • 💻Installation
      • 💻Create a validator
      • ⌚State sync
      • ⌚Snapshot
      • 📬Updates
    • Tellor
      • 💻Installation
      • ⌚State sync
      • 📬Updates
      • 📬Data Reporter (✔️Oracle)
    • Quicksilver
      • 💻Installation
      • 📬Updates
    • Warden Protocol
      • 💻Installation
      • ⌚State sync
      • 📬Updates
      • 📬Oracle
    • XRPL EVM
      • 💻Installation
      • ⌚State sync
      • ⌚Snapshots
      • 📬Updates
    • Zenrock
      • 💻Installation
      • 💻Sidecar (✔️Install)
      • 💻✔️config.yaml
      • 💻✔️eigen_operator_config.yaml
      • 💻Create a validator
      • 📬Updates
  • OTHER PROJECTS
    • Avail mainnet
      • 💻Installation
      • ⌚Snapshot
      • 📬Validator migration
    • Avail testnet
      • 💻Installation
      • ⌚Snapshot
      • 📬Validator migration
    • Kusama
      • 💻Decentralized nodes
      • 💻Installation
      • ⌚Snapshot
      • ⚙️Validator setup
      • ⚙️Validator migration
      • 🛠️Crunch bot
    • Polkadot
      • 💻Decentralized nodes
      • 💻Installation
      • ⌚Snapshot
      • ⚙️Validator setup
      • ⚙️Validator migration
      • 🛠️Crunch bot
    • Tangle Network
      • 💻Installation
      • 📬Validator migration
    • UOMI (GPU)
      • 💻Installation
      • ⌚Snapshot
      • 📬Validator migration
  • ARCHIVE
    • Entrypoint
      • 💻Installation
      • ⌚State sync
      • 📬Updates
    • Celestia
      • 💻Consensus Node
      • 🖥️Bridge node (Shwap)
      • 🖥️Full node (Shwap)
      • 🖥️Light node (Shwap)
      • ⌚Snapshots
      • ⌚State Sync [consensus node]
      • 🔎Analysis of the Bridge Node
    • Celestia-testnet
      • 💻Consensus Node
      • 🖥️Bridge node (Shwap)
      • 🖥️Full node (Shwap)
      • 🖥️Light node (Shwap)
      • ⌚Snapshots
      • ⌚State Sync [consensus node]
      • 🔎Analysis of the Bridge Node
    • Native [migration to SUI]
      • 💻Installation
      • ⌚Snapshots
      • ⌚State sync
      • 📬Updates
    • Nubit
      • 💻Light node
      • 📬Full Node
    • Lava network
      • 💻Installation
      • ⌚State sync
      • ⌚Snapshot
      • 📬Updates
      • ⌚Providers
    • Lava network
      • 💻Installation
      • ⌚State sync
      • ⌚Snapshot
      • 📬Updates
      • ⌚Providers
    • XAI
      • 💻Installation
    • Ojo
      • 💻Installation
      • ⌚State sync
      • ⌚Snapshot
      • 📬Updates
      • 📬Price feeder (✔️Oracle)
Powered by GitBook
On this page
  1. TESTNET
  2. PRYSM

State sync

State sync allows a new node to join a network by fetching a snapshot of the network state at a recent height, instead of fetching and replaying all historical blocks

Some blockchains do not yet know how to transfer wasm along with State sync. Download wasm if necessary

Important - different blockchains need a different amount of RAM to successfully start with State sync. Average 4 GB RAM

State sync

# stop the service and clear the database
systemctl stop prysmd
prysmd tendermint unsafe-reset-all --home ~/.prysm/ --keep-addr-book
# install lz4
apt update
apt install snapd -y
snap install lz4

# download wasm if necessary
curl -L https://share101.utsa.tech/prysm/wasm-prysm.tar.lz4 | lz4 -dc - | tar -xf - -C $HOME/.prysm --strip-components 2
# add peer
peers="88ad3a3b9b981f0bbb52d5c996d0f7e1aa9426fa@65.108.206.118:61256"
sed -i.bak -e "s/^persistent_peers *=.*/persistent_peers = \"$peers\"/" $HOME/.prysm/config/config.toml
SNAP_RPC=https://t-prysm.rpc.utsa.tech: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)

echo $LATEST_HEIGHT $BLOCK_HEIGHT $TRUST_HASH

sed -i.bak -E "s|^(enable[[:space:]]+=[[:space:]]+).*$|\1true| ; \
s|^(rpc_servers[[:space:]]+=[[:space:]]+).*$|\1\"$SNAP_RPC,$SNAP_RPC\"| ; \
s|^(trust_height[[:space:]]+=[[:space:]]+).*$|\1$BLOCK_HEIGHT| ; \
s|^(trust_hash[[:space:]]+=[[:space:]]+).*$|\1\"$TRUST_HASH\"| ; \
s|^(seeds[[:space:]]+=[[:space:]]+).*$|\1\"\"|" $HOME/.prysm/config/config.toml

after echo $LATEST_HEIGHT $BLOCK_HEIGHT $TRUST_HASH you should see something like this

# restart node
systemctl restart prysmd && journalctl -u prysmd -f -o cat

PreviousInstallationNextUpdates

Last updated 7 months ago

⌚