Useful Commands
Service operations ⚙️
Check logs
sudo journalctl -u prysmd -f
Start service
sudo systemctl start prysmd
Stop service
sudo systemctl stop prysmd
Restart service
sudo systemctl restart prysmd
Check service status
sudo systemctl status prysmd
Reload services
sudo systemctl daemon-reload
Enable Service
sudo systemctl enable prysmd
Disable Service
sudo systemctl disable prysmd
Node info
prysmd status 2>&1 | jq
Your node peer
echo $(prysmd tendermint show-node-id)'@'$(wget -qO- eth0.me)':'$(cat $HOME/.prysm/config/config.toml | sed -n '/Address to listen for incoming connection/{n;p;}' | sed 's/.*://; s/".*//')
Key management
Add New Wallet
prysmd keys add $WALLET
Restore executing wallet
prysmd keys add $WALLET --recover
List All Wallets
prysmd keys list
Delete wallet
prysmd keys delete $WALLET
Check Balance
prysmd q bank balances $WALLET_ADDRESS
Export Key (save to wallet.backup)
prysmd keys export $WALLET
View EVM Prived Key
prysmd keys unsafe-export-eth-key $WALLET
Import Key (restore from wallet.backup)
prysmd keys import $WALLET wallet.backup
Tokens
To valoper addressTo wallet addressAmount, uprysm
Withdraw all rewards
prysmd tx distribution withdraw-all-rewards --from $WALLET --chain-id prysm-devnet-1 --gas auto --gas-adjustment 1.5
Withdraw rewards and commission from your validator
prysmd tx distribution withdraw-rewards $VALOPER_ADDRESS --from $WALLET --commission --chain-id prysm-devnet-1 --gas auto --gas-adjustment 1.5 -y
Check your balance
prysmd query bank balances $WALLET_ADDRESS
Delegate to Yourself
prysmd tx staking delegate $(prysmd keys show $WALLET --bech val -a) 1000000uprysm --from $WALLET --chain-id prysm-devnet-1 --gas auto --gas-adjustment 1.5 -y
Delegate
prysmd tx staking delegate <TO_VALOPER_ADDRESS> 1000000uprysm --from $WALLET --chain-id prysm-devnet-1 --gas auto --gas-adjustment 1.5 -y
Redelegate Stake to Another Validator
prysmd tx staking redelegate $VALOPER_ADDRESS <TO_VALOPER_ADDRESS> 1000000uprysm --from $WALLET --chain-id prysm-devnet-1 --gas auto --gas-adjustment 1.5 -y
Unbond
prysmd tx staking unbond $(prysmd keys show $WALLET --bech val -a) 1000000uprysm --from $WALLET --chain-id prysm-devnet-1 --gas auto --gas-adjustment 1.5 -y
Transfer Funds
prysmd tx bank send $WALLET_ADDRESS <TO_WALLET_ADDRESS> 1000000uprysm --gas auto --gas-adjustment 1.5 -y
Validator operations
Create New Validator
prysmd tx staking create-validator \
--amount 1000000uprysm \
--from $WALLET \
--commission-rate 0.1 \
--commission-max-rate 0.2 \
--commission-max-change-rate 0.01 \
--min-self-delegation 1 \
--pubkey $(prysmd tendermint show-validator) \
--moniker "$MONIKER" \
--identity "" \
--details "" \
--chain-id prysm-devnet-1 \
--gas auto --gas-adjustment 1.5 \
-y
Edit Existing Validator
prysmd tx staking edit-validator \
--commission-rate 0.1 \
--new-moniker "$MONIKER" \
--identity "" \
--details "" \
--from $WALLET \
--chain-id prysm-devnet-1 \
--gas auto --gas-adjustment 1.5 \
-y
Validator info
prysmd status 2>&1 | jq
Validator Details
prysmd q staking validator $(prysmd keys show $WALLET --bech val -a)
Jailing info
prysmd q slashing signing-info $(prysmd tendermint show-validator)
Slashing parameters
prysmd q slashing params
Unjail validator
prysmd tx slashing unjail --from $WALLET --chain-id prysm-devnet-1 --gas auto --gas-adjustment 1.5 -y
Active Validators List
prysmd q staking validators -oj --limit=2000 | jq '.validators[] | select(.status=="BOND_STATUS_BONDED")' | jq -r '(.tokens|tonumber/pow(10; 6)|floor|tostring) + " " + .description.moniker' | sort -gr | nl
Check Validator key
[[ $(prysmd q staking validator $VALOPER_ADDRESS -oj | jq -r .consensus_pubkey.key) = $(prysmd status | jq -r .ValidatorInfo.PubKey.value) ]] && echo -e "Your key status is ok" || echo -e "Your key status is error"
Signing info
prysmd q slashing signing-info $(prysmd tendermint show-validator)
Governance
Create New Text Proposal
prysmd tx gov submit-proposal \
--title "" \
--description "" \
--deposit 1000000uprysm \
--type Text \
--from $WALLET \
--gas auto --gas-adjustment 1.5 \
-y
Proposals List
prysmd query gov proposals
View proposal
prysmd query gov proposal 1
Vote
prysmd tx gov vote 1 yes --from $WALLET --chain-id prysm-devnet-1 --gas auto --gas-adjustment 1.5 -y
Last updated