garlicoin.org

Run a Garlicoin node

A node keeps its own copy of the blockchain and shares it with others. Running one makes the network stronger and lets you check everything yourself. Setup takes about 20 minutes, then the first sync runs on its own for an hour or more with our bootstrap file.

Disk space About 16 GB For the full chain, growing slowly. A pruned node needs about 5 GB.
Memory 1–2 GB A small VPS, an old laptop or a 4 GB Raspberry Pi 4 is enough
Network Port 42069 Open it (TCP) so other nodes can connect to you

Set up a node

  1. Install Garlicoin Core from the official downloads page. On a server, the download includes garlicoind and garlicoin-cli for running without a window.
  2. Skip most of the sync with our bootstrap file. Start the client once, close it, put bootstrap.dat in the data directory and start it again.
  3. Add a config file named garlicoin.conf in the data directory. The example config on this page connects to nodes that are online right now.
  4. Open port 42069 on your router or firewall and forward it to the machine running the node. This is what makes you useful to others: new nodes download blocks from you.
  5. Check it's working. Your block height should match the network status page, and garlicoin-cli getnetworkinfo should show some inbound connections a while after you open the port.

Keep it running on Linux

Save this as /etc/systemd/system/garlicoind.service, change User and the paths to match your system, then run sudo systemctl enable --now garlicoind. The node then starts on boot and restarts if it stops.

[Unit]
Description=Garlicoin node
After=network-online.target

[Service]
User=garlic
ExecStart=/usr/local/bin/garlicoind -daemon=0 -datadir=/home/garlic/.garlicoin
ExecStop=/usr/local/bin/garlicoin-cli -datadir=/home/garlic/.garlicoin stop
Restart=on-failure
TimeoutStopSec=300

[Install]
WantedBy=multi-user.target

Example garlicoin.conf

# Accept connections from other nodes
listen=1
# Keep at most this many connections
maxconnections=40
# Uncomment to save disk space (size in MB). A pruned
# node still validates everything but can't serve old blocks.
#prune=3000
# Nodes that are online right now:
addnode=66.151.242.154
addnode=155.94.251.214
addnode=98.149.17.72
addnode=183.88.212.13
addnode=149.56.19.7
addnode=83.221.211.116

peers.txt

Where the data directory is

Windows%APPDATA%\Garlicoin
macOS~/Library/Application Support/Garlicoin
Linux~/.garlicoin

Handy commands

  • garlicoin-cli getblockcount · your block height
  • garlicoin-cli getconnectioncount · how many peers
  • garlicoin-cli getnetworkinfo · version and connections
  • garlicoin-cli stop · shut down cleanly

Why run a node?

Every node keeps a full copy of the rules and the chain. More nodes make Garlicoin harder to censor or fork, help new wallets sync faster, and let you check your own transactions without trusting anyone else.