Setting Up Bitcoin Core and Remote Procedure Call (RPC) Over a Local Area Network
As you set up your Bitcoin node on a small computer, you are taking a significant step towards a decentralized cryptocurrency ecosystem. In this article, we will walk you through the proper configuration and commands to run Bitcoin Core and enable Remote Procedure Calls (RPC) for remote access within your LAN.
Prerequisites
- Bitcoin Node running Bitcoin Core 0.15.3 or later
- Ethernet connection on your small computer
- IP address of your computer
Step-by-Step Guide
1. Install Bitcoin Core
First, download and install Bitcoin Core from the official repository: [ (version 0.15.3 or later)
Follow the installation instructions for your operating system:
- Ubuntu/Debian:
sudo apt-get install bitcoin-qt
- Fedora/CentOS/RHEL:
sudo dnf install bitcoin-qt
- Arch Linux:
sudo pacman -S bitcoin-qt
2. Start Bitcoin Core
Start the Bitcoin Node by running:
bitcoin-qt
This will start the node and start listening for incoming connections.
3. Configure RPC settings
To enable Remote Procedure Calls (RPC) on the node, you need to configure a few settings:
- rpcuser: Specify a username for the node.
- rpcpassword: Enter a password for the node.
- rpcport: Set the port number on which the node will listen.
For example:
bitcoin-qt
> rpcset
rpcuser=myusername
rpcpassword=mypassword
rpcport=55555
bitcoin-qt (version 0.15.3)
4. Start the RPC server
After configuring the RPC settings, start the RPC server by running:
bitcoin-qt -rpcport=55555
This will start the RPC server and begin listening for incoming connections from the LAN.
Using RPC to Access the Node
To access the node remotely using RPC, you need to do the following:
- Get a Bitcoin Address
: You can get a Bitcoin address by running:
bitcoincli getaddresslist
Choose a new address and save it to a file (e.g. “myaddress.txt”).
- Use the RPC URL
: The node’s RPC URL is
You can now use this RPC URL to send Bitcoin transactions, retrieve transaction information, or perform other node-related tasks remotely.
Tips and Variations
- If you want to use a specific port for RPC connections, you can specify it in thebitcoin-qt
command:
bitcoin-qt -rpcport=8080
- You can set multiple RPC users and passwords with the -rpcusers
option:
bitcoin-qt -rpcuser=username -rpcpassword=mypassword -rpcport=55555
Remember to replace
By following these steps, you can set up a Bitcoin Node on your small computer and enable Remote Procedure Calls (RPC) for remote access within your LAN. Happy mining!