January 31, 2023

Jaсkal Testnet

Official Links

Official Website

Explorer

Server requirements:

  • No. of CPUs: 4
  • Memory: 8GB
  • Disk: 150GB
  • OS: Ubuntu 22.04 LTS

Install Node Guide (Testnet)

Preparing the server

sudo apt update && sudo apt upgrade -y && \
sudo apt install curl tar wget clang pkg-config libssl-dev jq build-essential bsdmainutils git make ncdu gcc git jq chrony liblz4-tool -y

GO 19 (one command)

version="1.19.3" \
&& cd $HOME \
&& wget "https://golang.org/dl/go$version.linux-amd64.tar.gz" \
&& sudo rm -rf /usr/local/go \
&& sudo tar -C /usr/local -xzf "go$version.linux-amd64.tar.gz" \
&& rm "go$version.linux-amd64.tar.gz" \
&& echo "export PATH=$PATH:/usr/local/go/bin:$HOME/go/bin" >> $HOME/.bash_profile \
&& source $HOME/.bash_profile

Download and install Binaries

cd $HOME
git clone https://github.com/JackalLabs/canine-chain
cd canine-chain
git checkout v23.01-beta
make install

UPDATE 28.01.23

cd $HOME/canine-chain
git fetch --all
git checkout v23.01-beta
make install
canined version
#23.01-beta
sudo systemctl restart canined && sudo journalctl -u canined -f -o cat

Init

canined init <MONIKER> --chain-id lupulella-2
canined config chain-id lupulella-2

Replace <MONIKER> To your moniker

Create/recover wallet

canined keys add <walletname>
canined keys add <walletname> --recover

when creating, do not forget to write down the seed phrase

Genesis

cd $HOME
wget -O $HOME/.canine/config/genesis.json "https://raw.githubusercontent.com/JackalLabs/jackal-chain-assets/main/testnet/genesis.json"

Memory optimization (optional)

# Memory optimization. Removes unused data from the database. | ONE COMMAND

CONFIG=.canine

indexer="null" && \
snapshot_interval="100" && \
pruning="custom" && \
pruning_keep_recent="100" && \
pruning_keep_every="0" && \
pruning_interval="10" && \
min_retain_blocks="1" && \
inter_block_cache="false" && \
sed -i.bak -e "s/^indexer *=.*/indexer = \"$indexer\"/" $HOME/$CONFIG/config/config.toml && \
sed -i.bak -e "s/^snapshot-interval *=.*/snapshot-interval = \"$snapshot_interval\"/" $HOME/$CONFIG/config/app.toml && \
sed -i.bak -e "s/^pruning *=.*/pruning = \"$pruning\"/" $HOME/$CONFIG/config/app.toml && \
sed -i.bak -e "s/^pruning-keep-recent *=.*/pruning-keep-recent = \"$pruning_keep_recent\"/" $HOME/$CONFIG/config/app.toml && \
sed -i.bak -e "s/^pruning-keep-every *=.*/pruning-keep-every = \"$pruning_keep_every\"/" $HOME/$CONFIG/config/app.toml && \
sed -i.bak -e "s/^pruning-interval *=.*/pruning-interval = \"$pruning_interval\"/" $HOME/$CONFIG/config/app.toml && \
sed -i.bak -e "s/^min-retain-blocks *=.*/min-retain-blocks = \"$min_retain_blocks\"/" $HOME/$CONFIG/config/app.toml && \
sed -i.bak -e "s/^inter-block-cache *=.*/inter-block-cache = \"$inter_block_cache\"/" $HOME/$CONFIG/config/app.toml

Live Peers for Jackal

Here is a script for you to update persistent_peers setting with these peers in config.toml.

PEERS=5eedbfbe64b942f4ab54db3842acf3bfab034c24@161.97.74.88:46656
sed -i.bak -e "s/^persistent_peers *=.*/persistent_peers = \"$PEERS\"/" $HOME/.canine/config/config.toml

Download addrbook

wget -O $HOME/.canine/config/addrbook.json "https://raw.githubusercontent.com/obajay/nodes-Guides/main/Jakal/Jackal-Testnet/addrbook.json"

Create a service file

sudo tee /etc/systemd/system/canined.service > /dev/null <<EOF
[Unit]
Description=Jackal Node
After=network-online.target

[Service]
User=$USER
ExecStart=$(which canined) start
Restart=on-failure
RestartSec=3
LimitNOFILE=65535

[Install]
WantedBy=multi-user.target
EOF

Start your node

sudo systemctl daemon-reload
sudo systemctl enable canined
sudo systemctl restart canined
sudo journalctl -u canined -f -o cat

Create validator

After your node is synced , Create your mainnet validator

canined tx staking create-validator \
--amount=1000000ujkl \
--pubkey=$(canined tendermint show-validator) \
--moniker="<Moniker>" \
--identity="" \
--details="" \
--website="" \
--chain-id="lupulella-2" \
--commission-rate="0.10" \
--commission-max-rate="0.20" \
--commission-max-change-rate="0.1" \
--min-self-delegation="1" \
--fees 500ujkl \
--from=<wallet> -y

Replace <Moniker> With your moniker and replace <wallet> with your wallet name

Usefull comlambs

Service management

Check logs

journalctl -fu canined -o cat

Start service

sudo systemctl start canined

Stop service

sudo systemctl stop canined

Restart service

sudo systemctl restart canined

Node info

Synchronization info

canined status 2>&1 | jq .SyncInfo

Validator info

canined status 2>&1 | jq .ValidatorInfo

Node info

canined status 2>&1 | jq .NodeInfo

Show node id

canined tendermint show-node-id

Wallet operations

List of wallets

canined keys list

Recover wallet

canined keys add <wallet> --recover

Delete wallet

canined keys delete <wallet>

Get wallet balance

canined query bank balances <address>

Transfer funds

canined tx bank send <FROM ADDRESS> <TO_jackal_WALLET_ADDRESS> 10000000ujkl

Voting

canined tx gov vote 1 yes --from <wallet> --chain-id=lupulella-2

Staking, Delegation and Rewards

Delegate stake

canined tx staking delegate <jackal valoper> 10000000ujkl --from=<wallet> --chain-id=lupulella-2 --gas=auto

Redelegate stake from validator to another validator

canined tx staking redelegate <srcValidatorAddress> <destValidatorAddress> 10000000ujkl --from=<wallet> --chain-id=lupulella-2 --gas=auto

Withdraw all rewards

canined tx distribution withdraw-all-rewards --from=<wallet> --chain-id=lupulella-2 --gas=auto

Withdraw rewards with commision

canined tx distribution withdraw-rewards <jackal valoper> --from=<wallet> --commission --chain-id=lupulella-2

Validator management

Edit validator

canined tx staking edit-validator \
  --moniker=<moniker> \
  --identity=<your_keybase_id> \
  --website="<your_website>" \
  --details="<your_validator_description>" \
  --chain-id=lupulella-2 \
  --from=<wallet>

Unjail validator

canined tx slashing unjail \
  --broadcast-mode=block \
  --from=<wallet> \
  --chain-id=lupulella-2 \
  --gas=auto

Delete node

This comlambs will completely remove node from server. Use at your own risk!

sudo systemctl stop canined
sudo systemctl disable canined
sudo rm /etc/systemd/system/canined* -rf
sudo rm $(which canined) -rf
sudo rm $HOME/.canined* -rf
sudo rm $HOME/canine-chain -rf
sed -i '/JACKAL_/d' ~/.bash_profile