Installing Bitcoin and Bitcoin Cash on Ubuntu Server
In this article, we will guide you through the process of installing Bitcoin Core (BTC) and Bitcoin Cash (BCH) on an Ubuntu server.
Prerequisites:
- Ubuntu 18.04 or later (we’ll use 20.04 for this example)
- A basic understanding of Linux commands
- The necessary packages must be installed on your system:
sudo apt update
sudo apt install -y curl git build-essential libssl-dev libz-dev libidn2-dev lzo-dev libsnmp-dev
Step 1: Download and Extract Bitcoin Cash
First, you’ll need to download the Bitcoin Cash (BCH) package:
wget
tar xzf bcc-0.32.0.tar.gz
cd bcc-0.32.0
This will extract the BCH tarball and create a directory structure.
Step 2: Set Up Bitcoin Cash
Before you can use Bitcoin Cash, you need to configure it:
./configure --prefix=/usr/local/bin
This command sets up the Bitcoin Cash configuration on your Ubuntu system.
Step 3: Build and Install Bitcoin Cash
Now that you’ve configured Bitcoin Cash, build the package:
make -j$(nproc)
sudo make install
The -j
option specifies the number of CPU cores to use when compiling. The (nproc)
command counts the available CPU cores.
Step 4: Configure and Install Bitcoin Core (BTC)
Next, you’ll need to download and extract the Bitcoin Core package:
wget
tar xzf Bitcoin-Qt-0.19.1.tar.gz
cd Bitcoin-Qt-0.19.1
This will extract the Bitcoin Core tarball and create a directory structure.
Step 5: Configure and Build Bitcoin Core (BTC)
Before you can use Bitcoin Core, you need to configure it:
./configure --prefix=/usr/local/bin
And then build the package:
make -j$(nproc)
sudo make install
Step 6: Add Bitcoin Cash and Bitcoin Core to Your System
After installing both packages, you’ll need to add them to your system’s PATH so that they can be used from anywhere on your server.
sudo ln -s /usr/local/bin/bcc /usr/local/bin/
sudo ln -s /usr/local/bin/Bitcoin-Qt /usr/local/bin/
Step 7: Verify Your Installation
To verify that you’ve successfully installed Bitcoin Cash and Bitcoin Core, launch the Bitcoin client:
bitcoin-client --address=your-bch-address-here
Replace your-bch-address-here
with your BCH wallet address.
And if you want to use Bitcoin Cash for payments or other purposes:
bitcoxcash-cli --address=your-bitcoin-cash-address-here -l 2>/home/user/your-bitcoin-cash-logs/
Replace your-bitcoin-cash-address-here
with your BCH wallet address and -l
option specifies the log level.
Troubleshooting
If you encounter any issues during the installation process, check the Bitcoin Core documentation for troubleshooting guides: <
Additionally, you can contact the Bitcoin community support or visit the official Bitcoin website (< which provides extensive resources and tutorials for learning more about cryptocurrency.
By following these steps, you’ve successfully installed Bitcoin Cash on your Ubuntu server alongside Bitcoin Core.