Old CodeBlockLabs
VPS Recomendation
  • Home
  • 🌹Social Media
  • 🚰Testnet Faucet List
  • 🚰Mainnet Faucet List
  • 🔥Mainnet
    • Akash
    • Arcadia (Paw)
      • Installation
      • RPC Command
      • CLI
      • Fast Sync
    • Arkhadian
      • Installation
      • Update
      • Useful Commands
    • Banano
      • Installation
      • Node Configuration
      • RPC Command
      • CLI
      • Useful Command
    • DO Network
      • Install & Update
      • RPC Documentation
    • Kadena
      • Installation
      • Mining
    • Massa
      • Installation
    • Newrl
      • Installation
      • Useful Command
      • Update
    • Q Blockchain
      • Installation
      • Block stuck?
    • RaiblocksOne
      • Installation
      • Update
      • RPC Command
    • Raicoin
      • Installation
    • SGE
      • Installation
      • Update
      • Useful Commands
  • 💎Testnet
    • 0G Labs
      • Installation
      • Useful Commands
    • 5ire Chain
      • Installation
      • WASM Contract Deployment
    • Avail
      • Installation
    • BEVM
      • Installation
        • Docker
        • Binary
    • Blockx
      • Installation
      • Useful Commands
      • Incentivized Task
    • Elys
      • Installation
      • Useful Commands
    • Empeiria
      • Installation
      • Snapshot
      • Useful Commands
        • Wallet Management
        • Validator Management
        • Node Management
        • Governance
    • Impact Protocol
      • Installation
    • Erbie (wormholes)
      • Installation
      • RPC Documentation
      • Debug
    • Inery
      • Installation
      • Create Token
      • Value Contract
      • IneryCRUD
      • IneryPHP
      • Snapshots
    • Mantra
      • Installation
      • Useful commands
    • Naruno
      • Baklava Testnet
    • Nolus Protocol
      • Installation
      • Update
      • Snapshots
      • Relayer
      • Useful Commands
    • Noria
      • Installation
      • Update
      • State Sync
      • Useful Commands
    • Nibiru
      • Installation
      • Update
      • Useful Commands
    • Nulink
      • Installation
    • Ojo Network
      • Installation
      • Update
      • Useful Commands
    • PowerLoom
      • Pretest Task
    • The Power
      • Installation
    • Transformers Chain
      • Install & Update
      • RPC Documentation
  • âš¡VPS Provider
    • Contabo
      • Links To Provider
      • Promotion / Coupon
    • Vultr
      • Link To Provider
      • Promotion / Coupon
  • 😇solution
    • Docker
    • EVM Wallet by PrivateKey
    • Multiple Go
Powered by GitBook
On this page
  • Setup validator name
  • Install dependencies
  • Download and build binaries
  • Install Cosmovisor and create a service
  • Initialize the node
  • Download latest chain snapshot
  • Start service and check the logs
  1. Testnet
  2. Nibiru

Installation

Setup validator name

Replace YOUR_MONIKER_GOES_HERE with your validator name

MONIKER="YOUR_MONIKER_GOES_HERE"

Install dependencies

Update system and install build tools

sudo apt -q update
sudo apt -qy install curl git jq lz4 build-essential
sudo apt -qy upgrade

Install Go

sudo rm -rf /usr/local/go
curl -Ls https://go.dev/dl/go1.19.6.linux-amd64.tar.gz | sudo tar -xzf - -C /usr/local
eval $(echo 'export PATH=$PATH:/usr/local/go/bin' | sudo tee /etc/profile.d/golang.sh)
eval $(echo 'export PATH=$PATH:$HOME/go/bin' | tee -a $HOME/.profile)

Download and build binaries

# Clone project repository
cd $HOME
rm -rf nibiru
git clone https://github.com/NibiruChain/nibiru.git
cd nibiru
git checkout v0.19.2

# Build binaries
make build

# Prepare binaries for Cosmovisor
mkdir -p $HOME/.nibid/cosmovisor/genesis/bin
mv build/nibid $HOME/.nibid/cosmovisor/genesis/bin/
rm -rf build

# Create application symlinks
ln -s $HOME/.nibid/cosmovisor/genesis $HOME/.nibid/cosmovisor/current
sudo ln -s $HOME/.nibid/cosmovisor/current/bin/nibid /usr/local/bin/nibid

Install Cosmovisor and create a service

# Download and install Cosmovisor
go install cosmossdk.io/tools/cosmovisor/cmd/cosmovisor@v1.4.0

# Create service
sudo tee /etc/systemd/system/nibid.service > /dev/null << EOF
[Unit]
Description=nibiru-testnet node service
After=network-online.target

[Service]
User=$USER
ExecStart=$(which cosmovisor) run start
Restart=on-failure
RestartSec=10
LimitNOFILE=65535
Environment="DAEMON_HOME=$HOME/.nibid"
Environment="DAEMON_NAME=nibid"
Environment="UNSAFE_SKIP_BACKUP=true"
Environment="PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:$HOME/.nibid/cosmovisor/current/bin"

[Install]
WantedBy=multi-user.target
EOF
sudo systemctl daemon-reload
sudo systemctl enable nibid

Initialize the node

# Set node configuration
nibid config chain-id nibiru-itn-1
nibid config keyring-backend test
nibid config node tcp://localhost:38657

# Initialize the node
nibid init $MONIKER --chain-id nibiru-itn-1

# Download genesis and addrbook
curl -Ls https://snapshots.kjnodes.com/nibiru-testnet/genesis.json > $HOME/.nibid/config/genesis.json
curl -Ls https://snapshots.kjnodes.com/nibiru-testnet/addrbook.json > $HOME/.nibid/config/addrbook.json

# Add seeds
sed -i -e "s|^seeds *=.*|seeds = \"3f472746f46493309650e5a033076689996c8881@nibiru-testnet.rpc.kjnodes.com:38659\"|" $HOME/.nibid/config/config.toml

# Set minimum gas price
sed -i -e "s|^minimum-gas-prices *=.*|minimum-gas-prices = \"0.025unibi\"|" $HOME/.nibid/config/app.toml

# Set pruning
sed -i \
  -e 's|^pruning *=.*|pruning = "custom"|' \
  -e 's|^pruning-keep-recent *=.*|pruning-keep-recent = "100"|' \
  -e 's|^pruning-keep-every *=.*|pruning-keep-every = "0"|' \
  -e 's|^pruning-interval *=.*|pruning-interval = "19"|' \
  $HOME/.nibid/config/app.toml

# Set custom ports
sed -i -e "s%^proxy_app = \"tcp://127.0.0.1:26658\"%proxy_app = \"tcp://127.0.0.1:38658\"%; s%^laddr = \"tcp://127.0.0.1:26657\"%laddr = \"tcp://127.0.0.1:38657\"%; s%^pprof_laddr = \"localhost:6060\"%pprof_laddr = \"localhost:38060\"%; s%^laddr = \"tcp://0.0.0.0:26656\"%laddr = \"tcp://0.0.0.0:38656\"%; s%^prometheus_listen_addr = \":26660\"%prometheus_listen_addr = \":38660\"%" $HOME/.nibid/config/config.toml
sed -i -e "s%^address = \"tcp://0.0.0.0:1317\"%address = \"tcp://0.0.0.0:38317\"%; s%^address = \":8080\"%address = \":38080\"%; s%^address = \"0.0.0.0:9090\"%address = \"0.0.0.0:38090\"%; s%^address = \"0.0.0.0:9091\"%address = \"0.0.0.0:38091\"%; s%^address = \"0.0.0.0:8545\"%address = \"0.0.0.0:38545\"%; s%^ws-address = \"0.0.0.0:8546\"%ws-address = \"0.0.0.0:38546\"%" $HOME/.nibid/config/app.toml

Download latest chain snapshot

curl -L https://snapshots.kjnodes.com/nibiru-testnet/snapshot_latest.tar.lz4 | tar -Ilz4 -xf - -C $HOME/.nibid
[[ -f $HOME/.nibid/data/upgrade-info.json ]] && cp $HOME/.nibid/data/upgrade-info.json $HOME/.nibid/cosmovisor/genesis/upgrade-info.json

Start service and check the logs

sudo systemctl start nibid && sudo journalctl -u nibid -f --no-hostname -o cat

Useful Command

Check Version: nibid version --long

CHECK STATUS BINARY: systemctl status nibid CHECK RUNNING LOGS: journalctl -fu nibid -o cat CHECK LOCAL STATUS: curl -s localhost:38657/status | jq .result.sync_info

PreviousNibiruNextUpdate

Last updated 2 years ago

💎