RPC : https://lava-test-rpc.theamsolutions.info | API : https://lava-test-api.theamsolutions.info
Official docs HERE
STEP BY STEP INSTRUCTIONS
Install GO and dependencies HERE
git clone https://github.com/lavanet/lava.git
cd lava
ver=$(curl -s https://lava-test-rpc.theamsolutions.info/abci_info | jq -r ."result"."response"."version")
git checkout v${ver}
export LAVA_BINARY=lavad
make install
lavad init <node_name> --chain-id lava-testnet-2
wget -qO $HOME/.lava/config/genesis.json https://raw.githubusercontent.com/lavanet/lava-config/main/testnet-2/genesis_json/genesis.json
sed -i \
-e 's/timeout_commit = ".*"/timeout_commit = "30s"/g' \
-e 's/timeout_propose = ".*"/timeout_propose = "1s"/g' \
-e 's/timeout_precommit = ".*"/timeout_precommit = "1s"/g' \
-e 's/timeout_precommit_delta = ".*"/timeout_precommit_delta = "500ms"/g' \
-e 's/timeout_prevote = ".*"/timeout_prevote = "1s"/g' \
-e 's/timeout_prevote_delta = ".*"/timeout_prevote_delta = "500ms"/g' \
-e 's/timeout_propose_delta = ".*"/timeout_propose_delta = "500ms"/g' \
-e 's/skip_timeout_commit = ".*"/skip_timeout_commit = false/g' \
$HOME/.lava/config/config.toml
sudo tee /etc/systemd/system/lavad.service << EOF
[Unit]
Description=Lava Node
After=network-online.target
[Service]
User=$USER
ExecStart=$(which lavad) start --home="$HOME/.lava"
Restart=always
RestartSec=30
LimitNOFILE=infinity
LimitNPROC=infinity
[Install]
WantedBy=multi-user.target
EOF
sudo systemctl enable lavad
sudo systemctl daemon-reload
STATE SYNC SERVICE
Please make sure You have latest, officially launched version of Lava binaries.
sudo systemctl stop lavad.service
mv $HOME/.lava/data/priv_validator_state.json $HOME
lavad tendermint unsafe-reset-all
mv $HOME/priv_validator_state.json $HOME/.lava/data
SNAP_RPC="https://lava-test-rpc.theamsolutions.info:443"; \
LATEST_HEIGHT=$(curl -s $SNAP_RPC/block | jq -r .result.block.header.height); \
BLOCK_HEIGHT=$(($LATEST_HEIGHT - 5000)); \
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\"|" $HOME/.lava/config/config.toml; \
wget -qO $HOME/.lava/config/addrbook.json https://snapshots.theamsolutions.info/lava-addrbook.json
sudo systemctl restart lavad
sudo journalctl -u lavad -f -o cat
DATA SNAPSHOT
(updated every 6 hrs.)
#check snapshot info : curl -s https://snapshots.theamsolutions.info | egrep -o ">lava-snap*.*tar" | tr -d ">"
snap=$(curl -s https://snapshots.theamsolutions.info | egrep -o ">lava-snap*.*tar" | tr -d ">")
mv $HOME/.lava/data/priv_validator_state.json $HOME
rm -rf $HOME/.lava/data
wget -P $HOME https://snapshots.theamsolutions.info/${snap}
tar xf $HOME/${snap} -C $HOME/.lava
rm $HOME/${snap}
mv $HOME/priv_validator_state.json $HOME/.lava/data
wget -qO $HOME/.lava/config/addrbook.json https://snapshots.theamsolutions.info/lava-addrbook.json
sudo systemctl restart lavad
sudo journalctl -u lavad -f -o cat
CREATE VALIDATOR
lavad tx staking create-validator \
--amount="1000000ulava" \
--pubkey=$(lavad tendermint show-validator --home "$HOME/.lava/") \
--moniker="<Validaor-Name>" \
--chain-id=lava-testnet-2 \
--commission-rate="0.10" \
--commission-max-rate="0.20" \
--commission-max-change-rate="0.01" \
--min-self-delegation="1000" \
--gas="auto" \
--home="$HOME/.lava/" \
--from=<key-name>
USEFUL COMMANDS
#check node status
curl localhost:26657/status
#or
lavad status | jq
#add wallet
lavad keys add <wallet-name>
#check all available wallets
lavad keys list
#balance of your wallet
lavad query bank balances <wallet-key>
#find valoper address
lavad keys show <wallet-name> --bech val -a
#check validator staking state
lavad query staking validator <lava@valoper1...-address> --chain-id <CHAIN-ID>
#command for delegating
lavad tx staking delegate <lava@valoper1...-address> 1000000ulava --chain-id <CHAIN-ID> --from <wallet-name> --gas=auto
#Withdraw all-rewards with commisions
lavad tx distribution withdraw-rewards <lava@valoper1...-address> --from <wallet-name> --chain-id <CHAIN-ID> --commission --yes --gas=auto
#unjail command
lavad tx slashing unjail --from <wallet_name> --chain-id <CHAIN-ID> --gas=auto
#vote | options : yes/no/no_with_veto/abstain
lavad tx gov vote 1 yes --from <wallet_name> --chain-id <CHAIN-ID> --gas=auto
GOOD LUCK!
AM Solutions © Copyright. All rights reserved.
We need your consent to load the translations
We use a third-party service to translate the website content that may collect data about your activity. Please review the details in the privacy policy and accept the service to view the translations.