Cronos EVM Docs
  • Getting Started
    • Getting Started
    • Background
    • Architecture
    • Cronos roadmap
  • FOR USERS
    • 💳Crypto.com Card Top Up
    • 🔥Crypto Wallets
    • 🦊MetaMask Configuration
    • 🦁Brave Wallet
    • 🌉Bridges
      • From the Crypto.com App and Exchange
        • From the Crypto.com App
        • From the Crypto.com Exchange
      • IBC (Cronos POS Chain, other Cosmos chains)
        • Cronos Bridge Web App
      • Independent bridges
      • FAQs for Bridge transfers
      • FAQs for transactions from/to centralized exchanges
    • 🚰Testnet Faucet
    • 💡Tips & FAQs
    • 👮Key Principles for Wallet Security
    • GasTracker
  • FOR DAPP DEVELOPERS
    • 💡Founder FAQs
    • 🏅Hacker's Getting Started Resources
    • 📃Smart Contracts
      • Contract Development on Testnet
      • Contract Deployment and Verification
      • Contract Verification Export: Cronoscan To Cronos Explorer
      • Best Practices
      • Token Contract Addresses
    • 💻dApp Creation
      • Free and commercial RPC endpoints
      • Wallet integrations
      • Web3-wallet
      • JSON-RPC methods
      • Address Conversion
      • Swagger Playground
    • ⚙️Dev Tools & Integrations
      • All dev tools & integrations
      • Account Abstraction
      • Band Protocol
      • Banxa
      • GoldRush
      • Cronos Safe
      • Flair
      • Google Bigquery
      • Moralis
      • Pyth
      • Secret Network
      • SubQuery
      • Witnet
    • Crypto.com AI Agent SDK
  • FOR NODE HOSTS
    • Running nodes
      • Cronos Mainnet
        • Quicksync
        • State-sync
        • Public Node Sync
        • KSYNC
        • The "Huygen" upgrade guide (v0.6.* to v0.7.*)
        • The "v0.7.0-hotfix" upgrade guide (v0.7.* to v0.8.*)
        • The "Galileo" upgrade guide (v0.8.* to v1.0.*)
        • The "Titan" upgrade guide (v1.0.* to v1.1.0)
        • The "v1.2" upgrade guide (v1.1.* to v1.2.0)
        • The "v1.3" upgrade guide (v1.2.* to v1.3.0)
        • The "v1.4" Pallene upgrade guide (v1.3.* to v1.4.1)
        • Patching Unlucky & Duplicate Tx
      • Cronos Testnet
      • Devnet
      • Best Practices
      • Cronosd build with Nix
      • VersionDB
      • MemIAVL
      • Local State Sync
    • Cronosd
  • CRONOS PLAY
    • Introduction
    • Unity Engine
      • Current Version
      • Legacy Version
        • EVM
        • Login Example
        • Custom RPC
        • ERC20
        • ERC721
        • ERC1155
      • Useful Links
    • Unreal Engine
      • Installation and Enabling
      • Working with Blueprint
        • Actors and Blueprint Classes
        • Cronos Configuration
        • Connect Defi Desktop/Onchain Wallet with URI
        • Connect Wallets with QR Code
        • Connect WalletConnect Step by Step
        • WalletConnect 2.0 and Unreal Engine 5: Hello World Example
        • Wallet
        • ERC20
        • ERC721
        • ERC1155
        • Broadcast Transactions
        • Get Tokens or Transactions
      • Working with C++
        • Creating a C++ Project
        • Creating a child DefiWalletCoreActor
        • Querying a contract
        • Customizing Network
      • Demo
    • Cronos Play C++ SDK
    • Crypto.com Pay Integration
    • Cronos Play FAQ
  • Block Explorers
    • Block Explorer and API Keys
    • Cronos Explorer
    • Cronoscan
  • CRONOS CHAIN PROTOCOL
    • Chain ID and Address Format
    • Cronos General FAQ
    • Genesis
    • Modules
      • module_bank
      • module_distribution
      • module_slashing
      • module_feemarket
    • Chain Details
      • List of parameters
      • Technical glossary
      • Protocol Documentation
    • Common IBC Commands
  • Cronos zkEVM
    • Cronos zkEVM
  • Resources
    • Media / brand kit
Powered by GitBook
On this page
  • Pre-requisites
  • Supported OS
  • Prepare your machine
  • Introduction
  • Step 1. Get the latest cronosd binary
  • Step 2. Configure cronosd
  • Step 3. Run everything

Was this helpful?

Edit on GitHub
  1. FOR NODE HOSTS
  2. Running nodes
  3. Cronos Mainnet

State-sync

PreviousQuicksyncNextPublic Node Sync

Last updated 1 month ago

Was this helpful?

Pre-requisites

Supported OS

Linux x86_64 is confirmed to work. Other platforms may work but there is no guarantee. We will extend our support to other operating systems after we have stabilised our current architecture.

Prepare your machine

To run Cronos Mainnet nodes, you will need a machine with the following minimum requirements:

  • 4-core, x86_64 / ARM architecture processor

  • 16 GB RAM

  • 1 TB of storage space.

Introduction

The fastest way to get a node synced to the latest block-height, is by using . With state-sync your node downloads a data snapshot near the head of the chain and verifies this data. This leads to drastically shorter times to join the network.

Keep in mind that the blocks before state-sync trust height will not be queryable. So, in order to run a full node, it is better not to use state-sync, but use 's archive snapshot instead.

IMPORTANT

State-sync depends on the ability to pull a snapshot from its persistent-peers, so there is some amount of timing and luck involved with this method. Although it is the fastest way, it is not always going to work, in case state-sync is not syncing, we recommend using , although it takes a longer time to download the snapshot, this method is more guaranteed to work.

Step 1. Get the latest cronosd binary

  • Install the Cronos Mainnet binaries from GitHub:

curl -LOJ https://github.com/crypto-org-chain/cronos/releases/download/v1.4.5/cronos_1.4.5_Darwin_x86_64.tar.gz
tar -zxvf cronos_1.4.5_Darwin_x86_64.tar.gz
  • Check that cronosd is effectively installed:

./bin/cronosd version
1.4.5

Step 2. Configure cronosd

  • Initialize cronosd. Replace the [moniker] with an ID for your node.

./bin/cronosd init [moniker] --chain-id cronosmainnet_25-1
  • Download and replace the Cronos Mainnet genesis.json by:

curl https://raw.githubusercontent.com/crypto-org-chain/cronos-mainnet/master/cronosmainnet_25-1/genesis.json > ~/.cronos/config/genesis.json
  • Verify the sha256sum checksum of thegenesis.json. You should see OK! if the sha256sum checksum matches.

if [[ $(sha256sum ~/.cronos/config/genesis.json | awk '{print $1}') = "58f17545056267f57a2d95f4c9c00ac1d689a580e220c5d4de96570fbbc832e1" ]]; then echo "OK"; else echo "MISMATCHED"; fi;
OK!
  • Replace the following parameters in the ~/.cronos/config/config.toml file, by executing:

LATEST_HEIGHT=$(curl -s https://rpc.cronos.org:443/block | jq -r .result.block.header.height); \
BLOCK_HEIGHT=$((LATEST_HEIGHT - 1000)); \
TRUST_HASH=$(curl -s "https://rpc.cronos.org:443/block?height=$BLOCK_HEIGHT" | jq -r .result.block_id.hash)

sed -i.bak -E "s|^(enable[[:space:]]+=[[:space:]]+).*$|\1true| ; \
s|^(rpc_servers[[:space:]]+=[[:space:]]+).*$|\1\"https://rpc.cronos.org:443,https://rpc.cronos.org:443\"| ; \
s|^(trust_height[[:space:]]+=[[:space:]]+).*$|\1$BLOCK_HEIGHT| ; \
s|^(trust_hash[[:space:]]+=[[:space:]]+).*$|\1\"$TRUST_HASH\"| ; \
s|^(persistent_peers[[:space:]]+=[[:space:]]+).*$|\1\"0d5cf1394a1cfde28dc8f023567222abc0f47534@cronos-seed-0.crypto.org:26656,3032073adc06d710dd512240281637c1bd0c8a7b@cronos-seed-1.crypto.org:26656,04f43116b4c6c70054d9c2b7485383df5b1ed1da@cronos-seed-2.crypto.org:26656,337377dcda43d79c537d2c4d93ad3b698ce9452e@bd-cronos-mainnet-seed-node-01.bdnodes.net:26656\"| ; \
s|^(seeds[[:space:]]+=[[:space:]]+).*$|\1\"\"|" ~/.cronos/config/config.toml

Step 3. Run everything

  • Now that cronosd has been configured, we are ready to start the node:

./bin/cronosd start

1:40AM INF Unlocking keyring
1:40AM INF starting ABCI with Tendermint
1:40AM INF service start impl=multiAppConn module=proxy msg={} server=node
1:40AM INF service start connection=query impl=localClient module=abci-client msg={} server=node
1:40AM INF service start connection=snapshot impl=localClient module=abci-client msg={} server=node
1:40AM INF service start connection=mempool impl=localClient module=abci-client msg={} server=node
1:40AM INF service start connection=consensus impl=localClient module=abci-client msg={} server=node
1:40AM INF service start impl=EventBus module=events msg={} server=node
1:40AM INF service start impl=PubSub module=pubsub msg={} server=node
1:40AM INF service start impl=IndexerService module=txindex msg={} server=node
1:40AM INF Version info block=11 p2p=8 server=node tendermint_version=0.34.20
1:40AM INF This node is not a validator addr=DB03363D854BA491F280177BE33DE527F7542094 module=consensus pubKey=/L3Qe1oaNfrDael3QAmILSz5bLre9NAmKd48wd4eW8w= server=node
1:40AM INF P2P Node ID ID=d799c596250f27b5435775fdabb86d469dc5a784 file=/home/ubuntu/.cronos/config/node_key.json module=p2p server=node
1:40AM INF Adding persistent peers

This will take a couple of minutes, if your node manages to state-sync, you should see that snapshot chunks are being downloaded, and your node starts signing blocks.

To check the current node syncing status:

./bin/cronosd status 2>&1 | jq '.SyncInfo.catching_up'

That's it! You are now running a synced node on Cronos Mainnet!

The latest Cronosd release is cronosd v1.4.5

State-sync
Quicksync
quicksync
version