Welcome to validator AlxVoy ⚡ ANODE.TEAM



Althea

Links

Testnet service

Explorers

Sync

RPC & API

Peers and seeds

Genesis and addrbook

Service script (Install, State-Sync, Snapshot, Delete)

wget -O Althea.sh https://anode.team/Althea/test/Althea.sh && chmod u+x Althea.sh && ./Althea.sh

Installation

Software Requirements

  • Prerequisite: go1.18.5+ required. ref
  • Prerequisite: git. ref

Install last binary

git clone https://github.com/althea-net/althea-chain
cd althea-chain
git checkout v0.5.5
make install

Init the config files

althea init <moniker> --chain-id althea_417834-3
althea config chain-id althea_417834-3

Create a wallet

althea keys add <wallet_name> --algo secp256k1 --coin-type 118

Download genesis and addrbook

curl https://anode.team/Althea/test/genesis.json > ~/.althea/config/genesis.json
curl https://anode.team/Althea/test/addrbook.json > ~/.althea/config/addrbook.json

Add peers, seed

SEEDS=""
PEERS="bc47f3e8f9134a812462e793d8767ef7334c0119@chainripper-2.althea.net:23296"
sed -i.bak -e "s/^seeds *=.*/seeds = \"$SEEDS\"/; s/^persistent_peers *=.*/persistent_peers = \"$PEERS\"/" $HOME/.althea/config/config.toml

Add min gas

sed -i.bak -e "s/^minimum-gas-prices *=.*/minimum-gas-prices = \"0aalthea\"/" $HOME/.althea/config/app.toml

Create the service file

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

[Service]
User=$USER
ExecStart=$(which althea) start
Restart=always
RestartSec=3
LimitNOFILE=4096

[Install]
WantedBy=multi-user.target
EOF

Load service and start

sudo systemctl daemon-reload && sudo systemctl enable althea
sudo systemctl restart althea && journalctl -fu althea -o cat

Create Validator

althea tx staking create-validator \
  --amount=1000000000000000000aalthea \
  --pubkey=$(althea tendermint show-validator) \
  --moniker="<moniker>" \
  --identity="<identity>" \
  --website="<website>" \
  --details="<details>" \
  --security-contact="<contact>" \
  --chain-id="althea_417834-3" \
  --commission-rate="0.10" \
  --commission-max-rate="0.20" \
  --commission-max-change-rate="0.01" \
  --min-self-delegation="1" \
  --fees="0ualthea" \
  --from=<wallet_name>

State-Sync

SNAP_RPC=https://althea.rpc.t.anode.team:443 && \
LATEST_HEIGHT=$(curl -s $SNAP_RPC/block | jq -r .result.block.header.height); \
BLOCK_HEIGHT=$((LATEST_HEIGHT - 1000)); \
TRUST_HASH=$(curl -s "$SNAP_RPC/block?height=$BLOCK_HEIGHT" | jq -r .result.block_id.hash) && \
echo $LATEST_HEIGHT $BLOCK_HEIGHT $TRUST_HASH
sudo systemctl stop althea && althea tendermint unsafe-reset-all --home $HOME/.althea --keep-addr-book
peers="79875677d71e3213d34bd0fb8ede172d376bcff5@144.76.97.251:35656"
sed -i.bak -e  "s/^persistent_peers *=.*/persistent_peers = \"$peers\"/" $HOME/.althea/config/config.toml
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\"| ; \
s|^(seeds[[:space:]]+=[[:space:]]+).*$|\1\"\"|" $HOME/.althea/config/config.toml
sudo systemctl restart althea && journalctl -fu althea -o cat