Smart Systems for Home

Plain how-to guides for smart home, security and home Wi-Fi

Bitcoin Full Node Dojo Linux Setup Guide

· 5 min read · Home Tech

In this article
  1. What You'll Need
  2. Step-by-Step
  3. Common Mistakes
  4. Tips
  5. Troubleshooting
  6. Frequently Asked Questions

Setting up a Bitcoin full node with Dojo on Linux gives you a private, self-sovereign way to interact with the Bitcoin network and your own wallet data. Dojo is a privacy-focused Bitcoin node and indexer that works with Samourai Wallet and other compatible wallets. This guide walks you through the entire process on a fresh Ubuntu/Debian Linux system, from installing dependencies to verifying your node is fully synced.

What You'll Need

  • A Linux machine (Ubuntu 20.04+ or Debian 11+ recommended) with at least 2GB RAM, 500GB free disk space (SSD strongly recommended), and a stable internet connection.
  • Root or sudo access to the machine.
  • Basic familiarity with the terminal.
  • Optional: a domain name if you plan to expose Dojo remotely (not covered here).

Step-by-Step

  1. Update your system. Open a terminal and run:
    sudo apt update && sudo apt upgrade -y
  2. Install required packages. Dojo needs Git, Docker, and Docker Compose. Install them with:
    sudo apt install -y git docker.io docker-compose
  3. Enable and start Docker. Run:
    sudo systemctl enable docker
    sudo systemctl start docker
    Then add your user to the docker group so you don't need sudo for Docker commands:
    sudo usermod -aG docker $USER
    Log out and back in (or run newgrp docker) for the group change to take effect.
  4. Clone the Dojo repository. Choose a directory (e.g., ~/dojo) and run:
    git clone https://github.com/Samourai-Wallet/samourai-dojo.git ~/dojo
    cd ~/dojo
  5. Configure Dojo. Copy the sample configuration file:
    cp conf/docker-sample.conf conf/docker.conf
    Edit conf/docker.conf with your preferred text editor (e.g., nano conf/docker.conf). At minimum, set a strong DOJO_ADMIN_API_KEY (a long random string) and decide whether you want to run a full node or a pruned node. For a full node, leave DOJO_BITCOIND_PRUNE as 0. Save the file.
  6. Install Dojo. Run the installer script:
    ./install.sh
    This will pull Docker images and set up the environment. It may take several minutes depending on your connection.
  7. Start Dojo. After installation, start the node with:
    ./dojo.sh start
    This launches the Bitcoin Core, indexer, and other services in Docker containers.
  8. Monitor the initial sync. The Bitcoin blockchain must be fully downloaded and validated. Check progress with:
    ./dojo.sh logs bitcoind
    Look for the block height and “IBD” (Initial Block Download) status. This can take days on a slow connection or HDD.
  9. Verify sync completion. Once the block height matches the current network height (check on a block explorer), your node is synced. You can also run ./dojo.sh status to see service health.
  10. Connect your wallet. Use Samourai Wallet (Android) or a compatible desktop wallet like Sparrow. In the wallet, enter your Dojo’s IP address (or localhost if on the same machine) and the API key you set in docker.conf. The default port is 443 (HTTPS) or 80 (HTTP) if you disabled SSL.

Common Mistakes

  • Not enough disk space. The full Bitcoin blockchain is over 500GB. Check available space with df -h before starting.
  • Using an HDD. Synchronization can take weeks on a hard drive; an SSD is almost mandatory.
  • Forgetting to edit docker.conf. The default API key is weak; change it to a long random string.
  • Running as root. Dojo may have permission issues if run as root. Use a normal user with sudo.
  • Not waiting for full sync. Wallets will not work correctly until the node is fully synced.

Tips

  • Use a dedicated machine or a VPS with a static IP for better uptime.
  • Set up automatic updates for your OS, but be careful with Docker updates—always back up your conf/docker.conf.
  • Consider using a pruned node (DOJO_BITCOIND_PRUNE=1) if you're low on disk space; it still validates the entire blockchain but only keeps recent blocks.
  • Back up your conf/docker.conf and your wallet's recovery phrase. Dojo does not store your wallet keys.
  • If you plan to expose Dojo remotely, set up a reverse proxy with SSL (e.g., using Caddy or Nginx). Dojo's own SSL is self-signed and may cause warnings.

Troubleshooting

Dojo won't start. Check Docker is running (sudo systemctl status docker). Then run ./dojo.sh logs to see error messages. Common issues: port conflicts (change DOJO_BITCOIND_RPC_PORT or DOJO_NODE_PORT in docker.conf), or insufficient permissions (ensure your user is in the docker group).

Sync is stuck. First, verify your internet connection. Then check ./dojo.sh logs bitcoind for errors. If you see “out of memory”, increase your system RAM or add swap space. If the block height hasn't changed in hours, restart the bitcoind container: ./dojo.sh restart bitcoind.

Wallet cannot connect. Ensure your wallet is using the correct IP and port. If you're on the same machine, use 127.0.0.1. Make sure the API key matches exactly. If you changed the API key after initial setup, restart Dojo (./dojo.sh restart).

Port 443 already in use. This often happens if you have a web server running. Change DOJO_NODE_PORT to something like 8443 in docker.conf and restart Dojo.

Docker images fail to pull. Check your internet connection and try docker pull manually for the failing image. If you're behind a firewall, ensure Docker's domains are allowed.

If all else fails, you can reset Dojo without losing your wallet (your keys are in your wallet, not Dojo). Run ./dojo.sh clean to remove all data, then reinstall. This will require a full re-sync.

Frequently Asked Questions

Do I need a full node to use Dojo?

Yes, Dojo runs its own Bitcoin Core node. You cannot use Dojo with a third-party node; it must be self-hosted.

How long does the initial sync take?

On a fast SSD with a good internet connection (100 Mbps+), it can take 24-48 hours. On slower hardware, it may take a week or more.

Can I use Dojo with a pruned node?

Yes, set DOJO_BITCOIND_PRUNE=1 in docker.conf. This reduces disk usage to about 10GB, but you lose the ability to serve historical blocks to other nodes.

Is Dojo compatible with all wallets?

Dojo is primarily designed for Samourai Wallet and Sparrow Wallet. Other wallets that support the Dojo API (like Sentinel) may work, but check compatibility first.

How do I update Dojo?

Back up your conf/docker.conf, then pull the latest code with git pull inside the ~/dojo directory, and run ./install.sh again. This will preserve your blockchain data.

Can I run Dojo on a Raspberry Pi?

Technically yes, but it's not recommended. The Pi's limited RAM and CPU make sync extremely slow. A minimum of 4GB RAM and an SSD is advised.