1. Why Host a Garlicoin Full Node
- Bragging rights
- Interact closest to Garlicoin blockchain
- Create a faucet (How to create a Faucet)
2. Prepare the Host Server
2.1 System Requirements
- 1 vCPU or better
- 4 GB of Memory (2GB systems may work with configured swap space)
- ACL or Firewall open to port 42069
2.2 Update the Server
sudo apt update
sudo apt upgrade
sudo apt install systemd
2.3 Create a Garlicoin User
Create a new user to run the node service:
sudo adduser garlicoin
Switch to the new user:
sudo su - garlicoin
3. Install garlicoind
3.1 Download & Configure garlicoind
Download the package and extract it:
wget https://github.com/GarlicoinOrg/Garlicoin/releases/download/v0.18.0/garlicoin-0.18.0-x86_64-linux-gnu.tar.gz
tar xvzf garlicoin-0.18.0-x86_64-linux-gnu.tar.gz
Create a directory for Garlicoin data and configuration:
mkdir .garlicoin
Create and edit the configuration file:
cd ~/.garlicoin
touch garlicoin.conf
vim garlicoin.conf
Add the following to garlicoin.conf
(replace <username> and <password> with secure values):
txindex=1
rpcuser=<username>
rpcpassword=<password>
server=1
listen=1
daemon=1
3.2 Configure the Service
Create and configure the service file:
cd /etc/systemd/system
sudo touch garlicoind.service
sudo vim garlicoind.service
Paste the following configuration:
[Unit]
Description=garlicoin
After=network.target
[Service]
Type=forking
User=garlicoin
Group=garlicoin
Environment=GARLICOIN_PID=/home/garlicoin/.garlicoin/garlicoin.pid
Environment=GARLICOIN_HOME=/home/garlicoin/.garlicoin
ExecStart=/home/garlicoin/garlicoin-0.18.0/bin/garlicoind
ExecStop=/bin/kill -15 $MAINPID
[Install]
WantedBy=multi-user.target
Start the service:
sudo systemctl start garlicoind.service
3.3 Checking Sync Progress
To check the sync progress, use the following command:
sudo su - garlicoin
/home/garlicoin/garlicoin-0.18.0/bin/garlicoin-cli getblockchaininfo
If syncing does not progress, add a node manually:
/home/garlicoin/garlicoin-0.18.0/bin/garlicoin-cli addnode freshgrlc.net onetry
4. Bootstrap
4.1 Start Garlicoind with Bootstrap
Install prerequisites and download the bootstrap:
sudo apt update
sudo apt install python3-pip unzip
pip3 install gdown
Update your PATH:
vim ~/.bashrc
Add the following line:
PATH=$PATH:~/.local/bin
Load the new PATH configuration:
source ~/.bashrc
Download and extract the bootstrap file:
gdown --id 15lQG5kwFvvIYpeNjAr2rp0fknIQxNVAi -O bootstrap.zip
unzip bootstrap.zip
mv bootstrap.dat .garlicoin/bootstrap.dat
Start garlicoind with bootstrap:
cd ~/garlicoin-0.18.0/bin/
./garlicoind -loadblock=~/.garlicoin/bootstrap.dat
5. Debugging Guide
5.1 Node not syncing?
If the node is not syncing, check the log for DNS issues:
cat ~/.garlicoin/debug.log
Ensure port 42069
is open, and try manually connecting to a peer:
garlicoin-cli addnode freshgrlc.net onetry