March 7, 2023
Installing the OJO node in the Sauron test network !!!
OJO is an IBC-native decentralized price oracle incubated by Umee, created for all IBC assets. It offers secure and robust interchain communication for accurate price data from various authenticated centralized and decentralized data sources.
minimum recommended hardware configuration :
sudo apt update && sudo apt upgrade -y
install the necessary utilities:
sudo apt install curl build-essential git wget jq make gcc tmux chrony -y
specify the name of your validator, which will be visible in the explorer:
NODENAME=<NAME_VALIDATOR>
saving and importing variables :
echo "export NODENAME=$NODENAME" >> $HOME/.bash_profile if [ ! $WALLET ]; then echo "export WALLET=wallet" >> $HOME/.bash_profile fi echo "export OJO_CHAIN_ID=ojo-devnet" >> $HOME/.bash_profile source $HOME/.bash_profile
ver="1.19.1" && \ wget "https://golang.org/dl/go$ver.linux-amd64.tar.gz" && \ sudo rm -rf /usr/local/go && \ sudo tar -C /usr/local -xzf "go$ver.linux-amd64.tar.gz" && \ rm "go$ver.linux-amd64.tar.gz" && \ echo "export PATH=$PATH:/usr/local/go/bin:$HOME/go/bin" >> $HOME/.bash_profile && \ source $HOME/.bash_profile && \ go version
clone and assemble the binary file:
cd $HOME wget https://github.com/ojo-network/ojo/releases/download/v0.1.2/ojod-v0.1.2-linux-amd64.tar.gz tar -xvzf ojod-v0.1.2-linux-amd64.tar.gz sudo chmod +x ojod && sudo mv ./ojod /usr/local/bin/ojod sudo rm -rf ojod_linux_amd64.tar.gz
ojod init $NODENAME --chain-id $OJO_CHAIN_ID
curl -s https://rpc.devnet-n0.ojo-devnet.node.ojo.network/genesis | jq -r .result.genesis > $HOME/.ojo/config/genesis.json
SEEDS="" PEERS="[email protected]:26656,[email protected]:39656,[email protected]:21656,[email protected]:12656,[email protected]:31656,[email protected]:26656,[email protected]:26656,[email protected]:50656,[email protected]:25356,[email protected]:17656"; \ sed -i.bak -e "s/^seeds *=.*/seeds = \"$SEEDS\"/; s/^persistent_peers *=.*/persistent_peers = \"$PEERS\"/" $HOME/.ojo/config/config.toml
pruning="custom" pruning_keep_recent="100" pruning_keep_every="0" pruning_interval="10" sed -i -e "s/^pruning *=.*/pruning = \"$pruning\"/" $HOME/.ojo/config/app.toml sed -i -e "s/^pruning-keep-recent *=.*/pruning-keep-recent = \"$pruning_keep_recent\"/" $HOME/.ojo/config/app.toml sed -i -e "s/^pruning-keep-every *=.*/pruning-keep-every = \"$pruning_keep_every\"/" $HOME/.ojo/config/app.toml sed -i -e "s/^pruning-interval *=.*/pruning-interval = \"$pruning_interval\"/" $HOME/.ojo/config/app.toml
sed -i.bak -e "s/^minimum-gas-prices *=.*/minimum-gas-prices = \"0.025uojo\"/;" ~/.ojo/config/app.toml
if necessary, disable indexing (indexer = "null"):
cd ~
nano $HOME/.ojo/config/config.toml
ctrl O, enter, ctrrl X
ojod tendermint unsafe-reset-all --home $HOME/.ojo
sudo tee /etc/systemd/system/ojod.service > /dev/null <<EOF [Unit] Description=ojo After=network-online.target [Service] User=$USER ExecStart=/usr/local/bin/ojod start Restart=on-failure RestartSec=3 LimitNOFILE=65535 [Install] WantedBy=multi-user.target EOF
sudo systemctl daemon-reload sudo systemctl enable ojod sudo systemctl restart ojod && sudo journalctl -u ojod -f -o cat
after the synchronization is complete, load the variables into the system:
source $HOME/.bash_profile
creating or restoring a wallet:
ojod keys add $WALLET
ojod keys add $WALLET --recover
we save the information, enter the commands in turn, enter your password in 1 and 2:
OJO_WALLET_ADDRESS=$(ojod keys show $WALLET -a) OJO_VALOPER_ADDRESS=$(ojod keys show $WALLET --bech val -a) echo 'export OJO_WALLET_ADDRESS='${OJO_WALLET_ADDRESS} >> $HOME/.bash_profile echo 'export OJO_VALOPER_ADDRESS='${OJO_VALOPER_ADDRESS} >> $HOME/.bash_profile source $HOME/.bash_profile
ojod tx staking create-validator \ --amount 10000000uojo \ --from $WALLET \ --commission-max-change-rate "0.01" \ --commission-max-rate "0.2" \ --commission-rate "0.05" \ --min-self-delegation "1" \ --pubkey $(ojod tendermint show-validator) \ --moniker $NODENAME \ --identity=<__> \ --website="__" \ --details="__" \ --chain-id $OJO_CHAIN_ID \ --fees=5500uojo \ --gas=auto -y
sudo systemctl stop ojod sudo systemctl disable ojod sudo rm /etc/systemd/system/ojo* -rf sudo rm $(which ojod) -rf sudo rm $HOME/.ojo* -rf sudo rm $HOME/ojo -rf sed -i '/OJO_/d' ~/.bash_profile