Skip to main content

Node Installation

image.png

Minumum Requirements

  • 4 or more physical CPU cores.
  • At least 100 GB of SSD disk storage.
  • At least 8 GB of memory (RAM).
  • At least 50 mbps network bandwidth.
 

 

Custom User (optional)

sudo adduser entangle
sudo adduser entangle sudo
su - entangle

 

Custom Port (optional)

Skip this step if running default port configurations

PORT=35
echo "export PORT=${PORT}" >> $HOME/.bash_profile
source $HOME/.bash_profile

 

Install Update and Dependencies

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

 

Install GO(ver. 20.5)

For new Go Installation, run this command

sudo rm -rf /usr/local/go && \
curl -Ls https://go.dev/dl/go1.20.5.linux-amd64.tar.gz | sudo tar -xzf - -C /usr/local && \
echo "export PATH=$PATH:/usr/local/go/bin:$HOME/go/bin" >> $HOME/.bash_profile && \
source $HOME/.bash_profile && \
go version

If you already install GO on your previous project, run this command

echo "export PATH=$PATH:/usr/local/go/bin:$HOME/go/bin" >> $HOME/.bash_profile && \
source $HOME/.bash_profile && \
go version

 

Get Binary

cd $HOME
rm -rf entangle-blockchain
git clone https://github.com/Entangle-Protocol/entangle-blockchain
cd entangle-blockchain
make install
entangled version

 

Init Generation

Replace moniker_name with your own moniker name

entangled config chain-id entangle_33133-1
entangled config keyring-backend test
entangled init moniker_name --chain-id entangle_33133-1

 

Download Genesis and Addrbook

wget -O $HOME/.entangled/config/genesis.json https://raw.githubusercontent.com/Entangle-Protocol/entangle-blockchain/main/config/genesis.json

 

Set Peers and Seeds

SEEDS="[email protected]:26656"
sed -i -e "s|^seeds *=.*|seeds = \"$SEEDS\"|" $HOME/.entangled/config/config.toml
peers="76492a1356c14304bdd7ec946a6df0b57ba51fe2@json-rpc.testnet.entangle.fi:26656" 
sed -i.bak -e "s/^persistent_peers *=.*/persistent_peers = \"$peers\"/" $HOME/.entangled/config/config.toml

 

Set Port app.toml and config.toml

This Step If you running custom port, if you running default port, skip this step

entangled config node tcp://localhost:${PORT}657
sed -i.bak -e "s%^proxy_app = \"tcp://127.0.0.1:26658\"%proxy_app = \"tcp://127.0.0.1:${PORT}658\"%; s%^laddr = \"tcp://127.0.0.1:26657\"%laddr = \"tcp://127.0.0.1:${PORT}657\"%; s%^pprof_laddr = \"localhost:6060\"%pprof_laddr = \"localhost:${PORT}060\"%; s%^laddr = \"tcp://0.0.0.0:26656\"%laddr = \"tcp://0.0.0.0:${PORT}656\"%; s%^prometheus_listen_addr = \":26660\"%prometheus_listen_addr = \":${PORT}660\"%" $HOME/.entangled/config/config.toml
sed -i.bak -e "s%^address = \"tcp://0.0.0.0:1317\"%address = \"tcp://0.0.0.0:${PORT}317\"%; s%^address = \":8080\"%address = \":${PORT}080\"%; s%^address = \"0.0.0.0:9090\"%address = \"0.0.0.0:${PORT}090\"%; s%^address = \"0.0.0.0:9091\"%address = \"0.0.0.0:${PORT}091\"%" $HOME/.entangled/config/app.toml

 

Set Config Pruning

pruning="custom"
pruning_keep_every="0"
pruning_keep_recent="100"
pruning_interval="10"
sed -i -e "s/^pruning *=.*/pruning = \"$pruning\"/" $HOME/.entangled/config/app.toml
sed -i -e "s/^pruning-keep-recent *=.*/pruning-keep-recent = \"$pruning_keep_recent\"/" $HOME/.entangled/config/app.toml
sed -i -e "s/^pruning-keep-every *=.*/pruning-keep-every = \"$pruning_keep_every\"/" $HOME/.entangled/config/app.toml
sed -i -e "s/^pruning-interval *=.*/pruning-interval = \"$pruning_interval\"/" $HOME/.entangled/config/app.toml

 

Set minimum gas price

sed -i 's|^minimum-gas-prices *=.*|minimum-gas-prices = "0.025aNGL"|g' $HOME/.entangled/config/app.toml

 

Create Service

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

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

[Install]
WantedBy=multi-user.target
EOF

 

Register And Start Service

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