# Install SV Node

> For the complete documentation index, see [llms.txt](https://bsvblockchain.com/docs/llms.txt).

Get the SV Node software, bitcoind, from the official Docker image or by building the release source.

import SvNodeInstallRoutes from '/snippets/SvNodeInstallRoutes.jsx';

Install SV Node, the BSV blockchain node software, so you can run `bitcoind` on testnet or Mainnet. The GitHub releases publish source only, so you download the Linux binary from the BSV download server, run the official Docker image, or build the release yourself. Most applications do not need their own node. If you only send and receive payments, use a wallet or a broadcast service instead, and install SV Node when you operate a miner or need direct node access. This page was written against SV Node 1.2.3, release tag `v1.2.3`.

> Start on testnet. Pass `-testnet` to `bitcoind` until you have confirmed your setup, and never point a test setup at Mainnet funds.

## Check the system requirements

Size the host for the work the node will do before you install. These are the recommended requirements from internal testing of `bitcoind`, and they are expected to change as the network scales.

| | Development (regtest and testnet only) | Production, minimum | Production, recommended |
| --- | --- | --- | --- |
| Use | Follow the chain with the most proof of work and handle a small volume of other tasks, such as RPC requests | Handle a medium workload and stay in real-time sync with the chain tip | Handle a high workload, run with `txindex` enabled, or mine |
| Processor | 4 cores, 8 threads | 8 cores, 16 threads | 10 cores, 20 threads or more |
| Memory | 16 GB RAM and 10 GB swap | 64 GB RAM and 64 GB swap | 64 GB RAM and 64 GB swap |
| Network | 10 Mbit/s or more, up and down | 100 Mbit/s or more, up and down | 1 Gbit/s or more, up and down |
| Disk, pruned | 10 GB magnetic disk | 500 GB SSD | 1 TB SSD |
| Disk, unpruned | 20 GB magnetic disk | 16 TB SSD | 32 TB SSD |

For the two production columns, more RAM and less swap is better, as long as the host keeps 128 GB of memory in total. From release 1.0.14, the prune settings fine-tune how much disk the node uses. If you mine, also give your nodes the highest connectivity you can to other miners.

## Choose how to install

The three routes install the same release, 1.2.3 at the time of writing. Pick the one that fits your host, then follow its steps below.

<SvNodeInstallRoutes />

Three routes install the same release, 1.2.3. Linux binary: the release as published, Linux on x86_64 only with no Windows binary, a checksum to verify the download, and `bitcoind` runs straight from the archive. Docker image: a container from the official image, pinned by tag, which generates a `bitcoin.conf`, keeps data in `/data` and is the route for hosts without a Linux binary. Build from source: a build you control, for a custom build, needing GCC 10.2 or later and the build dependencies.

There is no Windows binary for 1.2.3, so on Windows run the Docker image.

## Install the software

Follow the steps for the route you chose.

### Download the Linux binary

The release tarball is on the [BSV download server](https://download.bitcoinsv.io/bitcoinsv/1.2.3/), next to a signed list of checksums.

**1. Download and verify the release**

Download the tarball and compute its hash:

```bash
curl -O https://download.bitcoinsv.io/bitcoinsv/1.2.3/bitcoin-sv-1.2.3-x86_64-linux-gnu.tar.gz
sha256sum bitcoin-sv-1.2.3-x86_64-linux-gnu.tar.gz
```

The output must be this line:

```text
13f222f5b466fe4af2bb867628354e4ae9711a10019e89fc7bf018b90e30b3c8  bitcoin-sv-1.2.3-x86_64-linux-gnu.tar.gz
```

The same hash is in the signed `SHA256SUMS.asc` next to the tarball on the server. It is a clear-signed PGP file, so you can check the signature with `gpg --verify SHA256SUMS.asc` once you hold the publisher's public key.

**2. Unpack and start on testnet**

In the folder that holds the tarball, unpack it and start `bitcoind` on testnet. The archive holds `bitcoind`, `bitcoin-cli` and `bitcoin-tx` in `bin/`:

```bash
tar xzf bitcoin-sv-1.2.3-x86_64-linux-gnu.tar.gz
bitcoin-sv-1.2.3/bin/bitcoind -testnet -excessiveblocksize=10GB -maxstackmemoryusageconsensus=100MB -minminingtxfee=0.00000001
```

SV Node 1.2.3 refuses to start unless these three parameters are set, and exits with "Mandatory consensus parameter is not set" otherwise. [Configure SV Node](https://bsvblockchain.com/docs/nodes/sv-node/configuration/) explains them.

To confirm the release, run `bitcoind --version` from the unpacked folder:

```bash
bitcoin-sv-1.2.3/bin/bitcoind --version | head -1
```

```text
Bitcoin SV version v1.2.3
```

### Run the Docker image

The image `bitcoinsv/bitcoin-sv` on Docker Hub provides `bitcoind`, `bitcoin-cli` and `bitcoin-tx`. It has a tag per release, for example `1.2.3`, plus `latest`.

**1. Start the node on testnet**

Pin the release tag so an upgrade is your decision:

```bash
docker run -d --name bitcoind-testnet bitcoinsv/bitcoin-sv:1.2.3 bitcoind -testnet -minminingtxfee=0.00000001
```

SV Node 1.2.3 refuses to start unless `minminingtxfee` is set. Without it the container exits with "Mandatory policy parameter is not set". The value above is the one used for testnet in the SV Node configuration examples. The image sets the two consensus parameters in the `bitcoin.conf` it generates.

Confirm the node is running and syncing. `bitcoin-cli` inside the container reads its credentials from the generated file, so point it there with `-conf`:

```bash
docker ps --filter name=bitcoind-testnet --format '{{.Names}} {{.Status}}'
docker exec bitcoind-testnet bitcoin-cli -conf=/data/bitcoin.conf -testnet getblockcount
```

```text
bitcoind-testnet Up 40 seconds
3419
```

The second line is the number of blocks the node has synced so far, so yours differs and grows while the node catches up. Without `-conf`, `bitcoin-cli` fails with "Could not locate RPC credentials". `docker logs bitcoind-testnet` shows the node connecting to peers and the new best block of each sync step.

**2. Keep the blockchain data**

A container is ephemeral, so without a volume the node starts from an empty chain every time. The image keeps its data and a generated `bitcoin.conf` in `/data`, so remove the container from the previous step and start it again with a volume mounted there:

```bash
docker rm -f bitcoind-testnet
docker run -d --name bitcoind-testnet -v bitcoin-data:/data bitcoinsv/bitcoin-sv:1.2.3 bitcoind -testnet -minminingtxfee=0.00000001
```

After that you can remove the container and run the same command again, and the node continues from the data in the volume.

### Build from source

The build instructions live in the repository for each release. The steps below follow `doc/build-unix.md` at [v1.2.3](https://github.com/bitcoin-sv/bitcoin-sv/blob/v1.2.3/doc/build-unix.md), the file to read at the tag you install. To build without installing the toolchain on your own machine, use a source image instead, see [Build in a source image](#build-in-a-source-image).

**1. Check the toolchain and dependencies**

The build needs GCC 10.2 or later (C++20), plus the libssl, libboost and libevent development packages. The repository lists optional dependencies such as ZMQ and Berkeley DB, and the package commands for Debian, Ubuntu and CentOS.

**2. Get the source**

Clone the release tag:

```bash
git clone --depth 1 --branch v1.2.3 https://github.com/bitcoin-sv/bitcoin-sv.git
cd bitcoin-sv
```

**3. Build**

From the source root:

```bash
./autogen.sh
./configure
make
```

`make` puts `bitcoind` and `bitcoin-cli` in `src/`. Installing the binaries with `make install` is optional.

**4. Start on testnet**

Start the built `bitcoind` with the same three required parameters as the binary route:

```bash
src/bitcoind -testnet -excessiveblocksize=10GB -maxstackmemoryusageconsensus=100MB -minminingtxfee=0.00000001
```

A build from the release tag reports its version as `v1.2.3-dev`.

#### Build in a source image

For each release, the [`bitcoinsv/bitcoin-sv-src`](https://hub.docker.com/r/bitcoinsv/bitcoin-sv-src/tags) images on Docker Hub contain the release source and every tool the build needs. There is one image per Linux distribution, tagged by version and distribution. For 1.2.3 the tags are:

- Debian: `1.2.3-debian-bookworm`, `1.2.3-debian-trixie`
- Ubuntu: `1.2.3-ubuntu-jammy`, `1.2.3-ubuntu-noble`
- CentOS: `1.2.3-centos-9`, `1.2.3-centos-10`

The images are built for x86_64 (amd64) only, so the commands below pass `--platform linux/amd64`. On an Arm host, such as an Apple silicon Mac, Docker Desktop runs them under emulation with no setup, and the build is slower. Docker Engine on an Arm Linux host needs QEMU registered first, see "Install QEMU manually" in [Docker's multi-platform guide](https://docs.docker.com/build/building/multi-platform/).

The build and the node both run inside the container. The binaries are x86_64 Linux programs linked against libraries from the image, such as Boost, libevent, OpenSSL's libcrypto and Berkeley DB, so they do not run on Mac or Windows, and on Linux only on the same distribution and release as the image, with those libraries installed. To run a node on Mac or Windows, use [the Docker image](#run-the-docker-image) instead.

**1. Start a shell in the image**

On your machine, start the image for your distribution. The example uses Ubuntu noble. For another distribution, change `ubuntu-noble` to one of the tag endings above.

```bash
docker run -it --name bitcoinsv-src --platform linux/amd64 bitcoinsv/bitcoin-sv-src:1.2.3-ubuntu-noble bash
```

The prompt changes to a shell inside the container.

**2. Build**

Inside the container, build from the source folder in `/opt`:

```bash
cd /opt/bitcoin-sv-1.2.3
./autogen.sh
./configure
make
```

`make` takes a while, and longer under emulation. When it finishes, the last lines are:

```text
make[1]: Entering directory '/opt/bitcoin-sv-1.2.3'
make[1]: Nothing to be done for 'all-am'.
make[1]: Leaving directory '/opt/bitcoin-sv-1.2.3'
```

`make` puts `bitcoind`, `bitcoin-cli` and `bitcoin-tx` in `src/`. Check the build:

```bash
src/bitcoind --version | head -1
```

```text
Bitcoin SV version v1.2.3.0-g6504a3aff-dev
```

**3. Start on testnet**

Inside the container, start the built `bitcoind` with the same three required parameters as the binary route:

```bash
src/bitcoind -testnet -excessiveblocksize=10GB -maxstackmemoryusageconsensus=100MB -minminingtxfee=0.00000001
```

The node runs in the foreground of that shell. From a second terminal on your machine, check it:

```bash
docker exec bitcoinsv-src /opt/bitcoin-sv-1.2.3/src/bitcoin-cli -testnet getblockcount
```

The output is the number of blocks the node has synced so far. It starts at `0` and grows while the node catches up. Stop the node with Ctrl+C in the container shell.

The container keeps the build after you exit. Start it again with `docker start -ai bitcoinsv-src`, and remove it with `docker rm bitcoinsv-src` when you no longer need it.

## Next steps

With the node installed, set its parameters and then look up the calls you can make.

- [Configure SV Node](https://bsvblockchain.com/docs/nodes/sv-node/configuration/)
- [SV Node RPC methods](https://bsvblockchain.com/docs/nodes/sv-node/rpc-methods/)