Installation Node
Hardware requirements
The following requirements are recommended for running Defund:
- 4 or more physical CPU cores
- At least 200GB of SSD disk storage
- At least 8GB of memory (RAM)
- At least 100mbps network bandwidth
Install dependencies Required
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
Install go
We are gonna use GO Version 1.21.7 If you already have GO installed you can skip this
ver="1.21.7"
cd $HOME
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" >> ~/.bash_profile
source ~/.bash_profile
go version
Intall Ignite
sudo curl https://get.ignite.com/cli
sudo mv ignite /usr/local/bin/
Install binary
cd $HOME
git clone https://github.com/dhealthproject/dhealth.git
cd dhealth
git checkout v1.0.0
ignite chain build
Initialize Node
Please change <YOUR_MONIKER>
To your own Moniker.
dhealthd init <YOUR_MONIKER> --chain-id dhealth
Download Genesis file and addrbook
- Genesis
wget -O $HOME/.dhealth/config/genesis.json "https://raw.githubusercontent.com/dhealthproject/mainnet/main/genesis.json"
- Addrbook
wget -O $HOME/.dhealth/config/addrbook.json "https://raw.githubusercontent.com/vinjan23/Mainnet/main/DHealth/addrbook.json"
Configure Seeds and Peers
peers="67243a0ed11567250aa02d5e47f6c4a0b8313975@142.93.174.93:26656,69d16d1147e90cdfb8ed066331a0abb9c71c3ae2@162.19.223.89:26656"
sed -i -e "s|^persistent_peers *=.*|persistent_peers = \"$peers\"|" $HOME/.dhealth/config/config.toml
Config 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/.dhealth/config/app.toml
create service file and start node
Create service file Create a dhealth.service
file in the /etc/systemd/system
folder with the following code.
sudo tee /etc/systemd/system/dhealthd.service > /dev/null <<EOF
[Unit]
Description=dhealth
After=network-online.target
[Service]
User=$USER
ExecStart=$(which dhealthd) start
Restart=always
RestartSec=3
LimitNOFILE=65535
[Install]
WantedBy=multi-user.target
EOF
- Enable Service and Start Node
sudo systemctl daemon-reload
sudo systemctl enable dhealthd
sudo systemctl restart dhealthd
sudo journalctl -u dhealthd -f -o cat
Statesync
Create Validator
Heads up to the Cheat Sheets to create validator