Block |
Size |
Snapshot Time |
Download |
Install lz4 if needed
sudo apt install lz4
Stop service
sudo systemctl stop {{appName}}.service
Backup priv_validator_state.json
cp $HOME/.{{dirName}}/{{chainId}}/cometbft/data/priv_validator_state.json $HOME/priv_validator_state.json
Remove old data
rm -rf ~/.{{dirName}}/{{chainId}}/cometbft/data ~/.{{dirName}}/{{chainId}}/{db,wasm}
Download snapshot
wget https://snapshots.stakeup.tech/{{chainName}}/{{chainId}}_latest.tar.lz4
lz4 -d -c {{chainId}}_latest.tar.lz4 | tar -xf - -C $HOME/.{{dirName}}/{{chainId}}
Return your priv_validator_state.json
mv $HOME/priv_validator_state.json $HOME/.{{dirName}}/{{chainId}}/cometbft/data/priv_validator_state.json
Start service and check logs
sudo systemctl restart {{appName}} && journalctl -u {{appName}} -f -o cat
Create a new wallet
namadaw gen --alias $wallet
Restore existing wallet
namada wallet derive --alias $wallet --hd-path default
Find your wallet address
namadaw find --alias $wallet
Check balance
namadac balance --owner $wallet
Check all known keys and addresses in wallet
namadaw list
Remove keys
namadaw remove --alias $wallet --do-it
Validator operations
New validator
namadac init-validator \
--name $NAME \
--commission-rate 0.1 \
--max-commission-rate-change 1 \
--signing-keys $wallet \
--alias $ALIAS \
--email $EMAIL \
--website $WEBSITE \
--discord-handle $DISCORD \
--account-keys $wallet \
--memo $MEMO
Update metadata
namadac change-metadata \
--validator $validator_address \
--description $DESCRIPTION \
--email $EMAIL \
--discord-handle $DISCORD_HANDLE \
--website $WEBSITE \
--avatar $AVATAR \
--name $NAME
Deactivation validator
namadac deactivate-validator --validator $validator_address
Reactivation validator
namadac reactivate-validator --validator $validator_address
Check sync status and node info
curl http://127.0.0.1:26657/status | jq
Check balance
namadac balance --owner ALIAS
Find your validator address
namadac find-validator --tm-address=$(curl -s localhost:26657/status | jq -r .result.validator_info.address)
Stake funds
namadac bond --source $wallet --validator $validator_address --amount 100 --memo MEMO
Check validator bond status
namadac bonds --validator $validator_address
Unbonding funds
namadac unbond --source $wallet --validator $validator_address --amount 100 --memo MEMO
Withdraw unbonded tokens
namadac withdraw --validator $validator_address --memo MEMO
Self-withdrawal
namadac withdraw --validator $validator_address --memo MEMO
Claim rewards
namadac claim-rewards --source $wallet --validator $validator_address --memo MEMO
Query pending reward tokens without claiming
namadac rewards --source $wallet --validator $validator_address
Change consensus key
namadac change-consensus-key --validator $validator_address --signing-keys $wallet
Generate a new consensus key
namadaw convert --alias $NEW_CONSENSUS_KEY
Token operations
Send payment from one address to another
namadac transfer --source $wallet --target $wallet1 --token NAAN --amount 100 --signing-keys $wallet --memo MEMO
Delegate tokens
namadac bond --source $wallet --validator $validator_address --amount 100 --memo MEMO
Check user bonds
namadac bonds --owner $wallet
Check all bonded nodes
namadac bonded-stake
Unbond tokens
namadac unbond --source $wallet --validator $validator_address --amount 100 --memo MEMO
Withdraw unbonded tokens
namadac withdraw --source $wallet --validator $validator_address --memo MEMO
Redelegate
namadac redelegate --owner $wallet --source-validator $validator_address --destination-validator destination-validator-address --amount 100 --memo MEMO
Claim rewards
namadac claim-rewards --source $wallet --validator $validator_address --memo MEMO
Query pending reward tokens without claiming
namadac rewards --source $wallet --validator $validator_address
Multisign
Generate key_1
namadaw gen --alias $wallet
Generate key_2
namadaw gen --alias $wallet1
Check your public key
namadaw find --alias $wallet | awk '/Public key:/ {print $3}'
Init non-multisig account (single signer)
namadac init-account --alias $wallet-multisig --public-keys $wallet --signing-keys $wallet --memo MEMO
Init multisig account (at least 2 signers)
namadac init-account --alias $wallet1-multisig --public-keys $wallet,$wallet1 --signing-keys $wallet,$wallet1 --threshold 100 --memo MEMO
Create a folder for a transaction
mkdir tx_dumps
Create transaction
namadac transfer --source $wallet1-multisig --target $wallet1 --token NAAN --amount 100 --signing-keys $wallet,$wallet1 --dump-tx --output-folder-path tx_dumps --memo MEMO
Sign the transaction
namadac sign-tx --tx-path "path-to-.tx-file" --signing-keys $wallet,$wallet1 --owner $wallet1-multisig --memo MEMO
Save as a variable offline_signature 1
export SIGNATURE_ONE="signature-file-name"
Save as a variable offline_signature 2
export SIGNATURE_TWO="signature-2-file-name"
Submit transaction
namadac tx --tx-path "path-to-.tx-file" --signatures SIGNATURE_ONE,SIGNATURE_TWO --owner $wallet1-multisig --gas-payer $wallet --memo MEMO
Change multisig threshold
namadac update-account --address $wallet1-multisig --threshold 1 --signing-keys $wallet,$wallet1 --memo MEMO
Check that the threshold is updated correctly
namadac query-account --owner $wallet1-multisig
Change public keys of a multisig account
namadac update-account --address $wallet1-multisig --public-keys $wallet2,$wallet3,$wallet4 --signing-keys $wallet,$wallet1 --memo MEMO
Initialize an established account
namadac init-account --alias $wallet1-multisig --public-keys $wallet2,$wallet3,$wallet4 --signing-keys $wallet,$wallet1 --threshold 1 --memo MEMO
MASP
Randomly generate a new spending key:
namadaw gen --shielded --alias ${$wallet}-shielded
Create a new payment address:
namadaw gen-payment-addr --key ${wallet}-shielded --alias ${wallet}-shielded-addr
Send a shielding transfer:
namadac transfer --source $wallet --target ${wallet}-shielded-addr --token NAAN --amount 100 --memo $MEMO
View balance:
namadac balance --owner ${wallet}-shielded
Generate another spending key:
namadaw gen --shielded --alias ${wallet}1-shielded
Create a payment address:
namadaw gen-payment-addr --key ${wallet}1-shielded --alias ${wallet}1-shielded-addr
Shielded transfers:
namadac transfer --source ${wallet}-shielded --target ${wallet}1-shielded-addr --token NAAN --amount 100 --signing-keys <your-implicit-account-alias> --memo $MEMO
Unshielding transfers:
namadac transfer --source ${wallet}-shielded --target $wallet --token NAAN --amount 100 --signing-keys <your-implicit-account-alias> --memo $MEMO
Governance
All proposals list:
namadac query-proposal
Edit proposal:
namadac query-proposal --proposal-id <PROPOSAL_ID>
Save wallet address:
wallet_address=$(namadaw find --alias $wallet | grep "Implicit" | awk '{print $3}')
Vote:
namadac vote-proposal --proposal-id <proposal-id> --vote yay --address $wallet_address --signing-keys $wallet --memo $MEMO
Check your vote:
namadac query-proposal-votes --proposal-id <proposal_id> --voter $wallet_address
Node operations
Check logs:
sudo journalctl -u namadad -f
Check sync status and node info:
curl http://127.0.0.1:26657/status | jq
Check consensus state:
curl -s localhost:26657/consensus_state | jq .result.round_state.height_vote_set[0].prevotes_bit_array
Check previous consensus state:
curl -s localhost:26657/consensus_state | jq .result.round_state.height_vote_set[-2].prevotes_bit_array
Full consensus state:
curl -s localhost:26657/dump_consensus_state
Your validator votes (prevote):
curl -s http://localhost:26657/dump_consensus_state | jq '.result.round_state.votes[0].prevotes' | grep $(curl -s http://localhost:26657/status | jq -r '.result.validator_info.address[:12]')