Basic tools for a validator node in Celestia
The first modular blockchain
Table of contents
Β· π Overview
Β· π Useful links
β Social media:
β Explorers:
Β· βοΈHardware requirements
Β· π Manual installation
β Updating packages and installing dependencies
β Environment variables
β Install go
β Download and compile binaries
β Setup the P2P networks
β Configure and start the application
β Download genesis
β Set seeds and peers
β Configure pruning
β Set the minimum gas price
β Activate prometheus
β Clean up old data
Β· β»οΈ Fast synchronisation with snapshot (Optional)
Β· π Service with SystemD
β Create the service file
β Enable, start service and check logs
Β· πWallet
β Create wallet
β Restore wallet
β Deposit funds into your wallet
Β· Configure the QGB Keys
Β· πValidator
β Create validator
β Check synchronisation status
β Check your balance
β Create validator
Β· π SystemD commands
β Stop the service
β Start service
β Restart service
β Check logs
β Check status
Β· π Node information
β Synchronization information
β Node information
β Validator information
β Get peers
Β· π Wallet operation
β Check balance
β Wallet Key List
β Create a new wallet
β Wallet recovering
β Delete wallet
β Transfer funds
Β· π¬ Governance
β List all proposals
β Vote YES
β Vote NO
β Refrain
Β· π° Staking, delegation and rewards
β Withdraw all rewards
β Withdraw commission
β Delegate Stake
Β· βοΈ Validator operation
β Edit validator
β Validator information
β Jailing information
β Validator unjailing
Β· π Delete node
π Overview
Celestia is the first modular blockchain with a scalable general purpose data availability layer for decentralised applications and trust-minimised sidechains.
The core idea of Celestia is to decouple transaction execution (and validity) from the consensus layer, so that the consensus is only responsible for a) ordering transactions and b) guaranteeing their data availability. They believe that is the next generation of scalable blockchain architectures.
TIA is the native token of Celestia.
Chain ID: mocha | arabica
π Useful links
β Website: https://celestia.org/
β GitHub: https://github.com/celestiaorg
β Celestia documentation: https://docs.celestia.org/
β Frequently Asked Questions: https://celestia.org/faq/
β Cumulo Spanish Resources: http://cumulo.pro/celestia.html
Social media:
β Twitter: https://twitter.com/CelestiaOrg
β Telegram: https://t.me/CelestiaCommunity
β Discord: https://discord.gg/celestiacommunity
β Blog: https://blog.celestia.org/
β LinkedIn: https://www.linkedin.com/company/celestiaorg/
β Youtube: https://www.youtube.com/@celestia7066
Explorers:
β https://celestia.explorers.guru/
β https://testnet-explorer.brocha.in/celestia/
βοΈHardware requirements
β Memory: 8 GB RAM
β CPU: Quad-Core
β Disk: 250 GB of storage
β Bandwidth: 1 Gbps for Download/100 Mbps for Upload
π Manual installation
Updating packages and installing dependencies
sudo apt update && sudo apt upgrade -y
sudo apt install curl tar wget clang pkg-config libssl-dev jq build-essential git make ncdu -y
Environment variables
To set environment variables replace your wallet and moniker <YOUR_WALLET_NAME> < YOUR_MONIKER>, save and import the variables into the system.
echo "export CELESTIA_WALLET="<YOUR_WALLET_NAME>"" >> $HOME/.bash_profile
echo "export CELESTIA_MONIKER="<YOUR_MONIKER>"" >> $HOME/.bash_profile
echo "export CELESTIA_CHAIN_ID="mocha"" >> $HOME/.bash_profile
source $HOME/.bash_profile
Install go
cd $HOME
VER="1.19.1"
wget "https://golang.org/dl/go$VER.linux-amd64.tar.gz"
sudo tar -C /usr/local -xzf "go$VER.linux-amd64.tar.gz"
rm -rf "go$VER.linux-amd64.tar.gz"
echo "export PATH=$PATH:/usr/local/go/bin:$HOME/go/bin" >> $HOME/.bash_profile
source $HOME/.bash_profile
go version
Download and compile binaries
cd $HOME
rm -rf celestia-app
git clone https://github.com/celestiaorg/celestia-app.git
cd celestia-app/
APP_VERSION=v0.11.0
git checkout tags/$APP_VERSION -b $APP_VERSION
make install
Setup the P2P networks
cd $HOME
rm -rf networks
git clone https://github.com/celestiaorg/networks.git
Configure and start the application
celestia-appd config chain-id mocha
celestia-appd init $CELESTIA_MONIKER --chain-id mocha
Download genesis
cp $HOME/networks/mocha/genesis.json $HOME/.celestia-app/config
Set seeds and peers
Peers
peers=$(curl -sL https://raw.githubusercontent.com/celestiaorg/networks/master/mocha/peers.txt | tr -d '\n')
bootstrap_peers=$(curl -sL https://raw.githubusercontent.com/celestiaorg/networks/master/mocha/bootstrap-peers.txt | tr -d '\n')
sed -i.bak -e 's|^bootstrap-peers *=.*|bootstrap-peers = "'"$bootstrap_peers"'"|; s|^persistent_peers *=.*|persistent_peers = "'$peers'"|' $HOME/.celestia-app/config/config.toml
You can find more peers here:
Configure pruning
PRUNING="custom"
PRUNING_KEEP_RECENT="100"
PRUNING_INTERVAL="10"
sed -i -e "s/^pruning *=.*/pruning = \"$PRUNING\"/" $HOME/.celestia-app/config/app.toml
sed -i -e "s/^pruning-keep-recent *=.*/pruning-keep-recent = \
\"$PRUNING_KEEP_RECENT\"/" $HOME/.celestia-app/config/app.toml
sed -i -e "s/^pruning-interval *=.*/pruning-interval = \
\"$PRUNING_INTERVAL\"/" $HOME/.celestia-app/config/app.toml
Set the minimum gas price
sed -i -e "s/^minimum-gas-prices *=.*/minimum-gas-prices = \"0utia\"/" $HOME/.celestia-app/config/app.toml
sed -i -e "s/prometheus = false/prometheus = true/" $HOME/.celestia-app/config/config.toml
sed -i -e "s/^indexer *=.*/indexer = \"null\"/" $HOME/.celestia-app/config/config.toml
Activate prometheus
sed -i -e "s/prometheus = false/prometheus = true/" $HOME/.celestia-app/config/config.toml
Clean up old data
celestia-appd tendermint unsafe-reset-all --home $HOME/.celestia-app --keep-addr-book
β»οΈ Fast synchronisation with snapshot (Optional)
You can sync your Celestia node quickly by downloading a recent snapshot:
cd $HOME
rm -rf ~/.celestia-app/data
mkdir -p ~/.celestia-app/data
SNAP_NAME=$(curl -s https://snaps.qubelabs.io/celestia/ | \
egrep -o ">mocha.*tar" | tr -d ">")
wget -O - https://snaps.qubelabs.io/celestia/${SNAP_NAME} | tar xf - \
-C ~/.celestia-app/data/
π Service with SystemD
Create the service file
sudo tee <<EOF >/dev/null /etc/systemd/system/celestia-appd.service
[Unit]
Description=celestia-appd Cosmos daemon
After=network-online.target
[Service]
User=$USER
ExecStart=$HOME/go/bin/celestia-appd start
Restart=on-failure
RestartSec=3
LimitNOFILE=4096
[Install]
WantedBy=multi-user.target
EOF
Enable, start service and check logs
sudo systemctl daemon-reload
sudo systemctl enable celestia-appd
sudo systemctl restart celestia-appd
sudo journalctl -u celestia-appd -f
πWallet
Create wallet
Donβt forget to save the mnemonic.
celestia-appd keys add $CELESTIA_WALLET
Restore wallet
celestia-appd keys add $CELESTIA_WALLET --recover
Deposit funds into your wallet
Before creating a validator, you have to deposit funds in your wallet, go to the Celestia Discord server and request them in the faucet channel.
$request <address wallet>
Configure the QGB Keys
This step helps you prepare for when the Quantum Gravity Bridge is ready to be deployed. You need to perform this step before running a validator, by configuring 2 additional keys.
β EVM-address: This flag must contain a 0x EVM address. Here, you can add any Ethereum-based address. You can also modify it later if you decide to change your address. To get this wallet address you can use a MetaMask address or an Ethereum wallet.
β orchestrator-address: This flag must contain a newly generated Celestia address. Validators can use their existing Celestia addresses, but it is recommended to create a new one:
celestia-appd keys add ${CELESTIA_WALLET}_2
You can set both values as environment variables:
ERC20_ADDRESS="0xdd5xxxxxxxxxxxxxxxx3a2720840001bC5F87D7x"
CELESTIA_WALLET_ADDRESS=$(celestia-appd keys show $CELESTIA_WALLET -a)
CELESTIA_VALOPER_ADDRESS=$(celestia-appd keys show $CELESTIA_WALLET --bech val -a)
ORCHESTRATOR_ADDRESS=$(celestia-appd keys show ${CELESTIA_WALLET}_2 -a)
echo "export CELESTIA_WALLET_ADDRESS="${CELESTIA_WALLET_ADDRESS} >> $HOME/.bash_profile
echo "export CELESTIA_ORCHESTRATOR_ADDRESS="${ORCHESTRATOR_ADDRESS} >> $HOME/.bash_profile
echo "export CELESTIA_VALOPER_ADDRESS="${CELESTIA_VALOPER_ADDRESS} >> $HOME/.bash_profile
echo "export EVM_ADDRESS=""$ERC20_ADDRESS" >> $HOME/.bash_profile
source $HOME/.bash_profile
πValidator
Create validator
Before creating a validator, you should make sure that the node is synchronised and check the balance of your wallet.
Check synchronisation status
Once your node is fully synchronised, the output will read false.
celestia-appd status 2>&1 | jq .SyncInfo
Check your balance
celestia-appd query bank balances $CELESTIA_WALLET_ADDRESS
Create validator
celestia-appd tx staking create-validator \
--amount 1000000utia \
--from $CELESTIA_WALLET \
--commission-max-change-rate "0.01" \
--commission-max-rate "0.2" \
--commission-rate "0.05" \
--min-self-delegation "1" \
--pubkey $(celestia-appd tendermint show-validator) \
--moniker $CELESTIA_MONIKER \
--chain-id $CELESTIA_CHAIN_ID \
--evm-address "$EVM_ADDRESS" \
--orchestrator-address "$CELESTIA_ORCHESTRATOR_ADDRESS" \
--gas auto \
--gas-adjustment 1.3 \
--fees 1000utia
You can add the flags β website β security-contact β identity β details (optional)
--website <WEB_SITE_URL> \
--security-contact <YOUR_CONTACT> \
--identity <KEYBASE_IDENTITY> \
--details <YOUR_VALIDATOR_DETAILS>
π SystemD commands
Stop the service
sudo systemctl stop celestia-appd
Start service
sudo systemctl start celestia-appd
Restart service
sudo systemctl restart celestia-appd
Check logs
sudo journalctl -u celestia-appd -f
Check status
sudo systemctl status celestia-appd
π Node information
Synchronization information
celestia-appd status 2>&1 | jq .SyncInfo
Node information
celestia-appd status 2>&1 | jq .NodeInfo
Validator information
celestia-appd status 2>&1 | jq .ValidatorInfo
Get peers
echo $(celestia-appd tendermint show-node-id)'@'$(curl -s ifconfig.me)':'$(cat $HOME/.celestia-appd/config/config.toml | sed -n '/Address to listen for incoming connection/{n;p;}' | sed 's/.*://; s/".*//')
π Wallet operation
Check balance
celestia-appd query bank balances $CELESTIA_WALLET_ADDRESS
Wallet Key List
celestia-appd keys list
Create a new wallet
celestia-appd keys add $CELESTIA_WALLET
Wallet recovering
celestia-appd keys add $CELESTIA_WALLET --recover
Delete wallet
celestia-appd keys delete $CELESTIA_WALLET
Transfer funds
celestia-appd tx bank send $CELESTIA_WALLET_ADDRESS <ANOTHER_CELESTIA_WALLET_ADDRESS> 800000000utia --gas auto --gas-adjustment 1.3
π¬ Governance
List all proposals
celestia-appd query gov proposal 1
Vote YES
celestia-appd tx gov vote 1 yes --from $CELESTIA_WALLET --chain-id $CELESTIA_CHAIN_ID --gas-adjustment 1.4 --gas auto -y
Vote NO
celestia-appd tx gov vote 1 no --from $CELESTIA_WALLET --chain-id $CELESTIA_CHAIN_ID --gas-adjustment 1.4 --gas auto -y
Refrain
celestia-appd tx gov vote 1 abstain --from $CELESTIA_WALLET --chain-id $CELESTIA_CHAIN_ID --gas-adjustment 1.4 --gas auto -y
π° Staking, delegation and rewards
Withdraw all rewards
celestia-appd tx distribution withdraw-all-rewards --from $CELESTIA_WALLET --chain-id $CELESTIA_CHAIN_ID --gas auto --gas-adjustment 1.3
Withdraw commission
celestia-appd tx distribution withdraw-rewards $CELESTIA_VALOPER_ADDRESS --from $CELESTIA_WALLET --commission --fees 20utia
Delegate Stake
celestia-appd tx staking delegate $CELESTIA_VALOPER_ADDRESS 10000000utia --from $CELESTIA_WALLET --chain-id $CELESTIA_CHAIN_ID --gas=auto --gas-adjustment 1.3
βοΈ Validator operation
Edit validator
celestia-appd tx staking edit-validator \
--moniker=$NODENAME \
--identity=<keybase_id> \
--website="<website>" \
--details="<validator_description>" \
--chain-id=$CELESTIA_CHAIN_ID \
--from=$CELESTIA_WALLET
--fees=200utia
Validator information
celestia-appd status 2>&1 | jq .ValidatorInfo
Jailing information
celestia-appd q slashing signing-info $(celestia-appd tendermint show-validator)
Validator unjailing
celestia-appd tx slashing unjail --broadcast-mode=block --from $CELESTIA_WALLET --chain-id $CELESTIA_CHAIN_ID --gas auto --gas-adjustment 1.5
π Delete node
sudo systemctl stop celestia-appd
sudo systemctl disable celestia-appd
sudo rm -rf /etc/systemd/system/celestia-appd*
sudo systemctl daemon-reload
sudo rm $(which celestia-appd)
sudo rm -rf $HOME/.celestia-appd
sudo rm -fr $HOME/ celestia-appd
sed -i "/CELESTIA_/d" $HOME/.bash_profile