Skip to content

Commit

Permalink
Merge pull request #11 from josh-wong/change-syntax-to-docusaurus
Browse files Browse the repository at this point in the history
Change syntax in docs from Material for MkDocs to Docusaurus; revise text; change Markdown file extension
  • Loading branch information
josh-wong authored May 19, 2024
2 parents 30d23c8 + 095ba93 commit 4af8983
Show file tree
Hide file tree
Showing 17 changed files with 239 additions and 263 deletions.
File renamed without changes.
10 changes: 6 additions & 4 deletions docs/index.md → docs/index.mdx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# How to install, configure, and upgrade Bitcoin Cash Node on a Raspberry Pi 4 running Ubuntu Desktop
# Overview

The set of Bitcoin Cash Node tutorials in this section includes instructions for the following:

Expand All @@ -7,9 +7,11 @@ The set of Bitcoin Cash Node tutorials in this section includes instructions for

These tutorials are intended for those who are familiar with the Ubuntu environment and Linux commands.

!!! note

I'm using a Raspberry Pi 4 simply to minimize carbon footprint while still contributing to the health and decentralization of Bitcoin Cash. However, these instructions should work on other types of devices running Ubuntu Desktop.
:::note

I'm using a Raspberry Pi 4 simply to minimize carbon footprint while still contributing to the health and decentralization of Bitcoin Cash. However, these instructions should work on other types of devices running Ubuntu Desktop.

:::

## Introduction to Bitcoin Cash Node

Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
# Preparing our device
# Prepare your device

This tutorial assumes that we have already installed and configured Ubuntu Desktop on our Raspberry Pi to our liking and have mounted the SSD to our Raspberry Pi.
This tutorial assumes that you've already installed and configured Ubuntu Desktop on your Raspberry Pi to your liking and have mounted the SSD to your Raspberry Pi.

1. **For details on installing Ubuntu Desktop (64-bit) on your Raspberry Pi**, please see [How to install Ubuntu Desktop on Raspberry Pi 4](https://ubuntu.com/tutorials/how-to-install-ubuntu-desktop-on-raspberry-pi-4#1-overview).
2. **For details on automounting your SSD in Ubuntu**, please see [How to properly automount a drive in Ubuntu Linux](https://www.techrepublic.com/article/how-to-properly-automount-a-drive-in-ubuntu-linux/).

## Check our Ubuntu architecture
## Check your Ubuntu architecture

Before we proceed, let's make sure we're running the aarch64 version of Ubuntu on our Raspberry Pi. Run the following command in **Terminal**.
Before you proceed, make sure you're running the aarch64 version of Ubuntu on your Raspberry Pi. Run the following command in **Terminal**.

```console
uname -m
Expand All @@ -17,7 +17,7 @@ If `aarch64` is not output, please follow the instructions in [How to install Ub

## Update and upgrade your Raspberry Pi and Ubuntu

After setting up Ubuntu Desktop and automounting your SSD, let's update and upgrade your Raspberry Pi and Ubuntu by running the following commands in **Terminal**.
After setting up Ubuntu Desktop and automounting your SSD, update and upgrade your Raspberry Pi and Ubuntu by running the following commands in **Terminal**.

```console
sudo apt update && sudo apt upgrade -y
Expand All @@ -27,26 +27,30 @@ Wait for updates and upgrades to install. If prompted, reboot your device and th

## Set a static IP address

We need to configure a static IP address and then set up port forwarding so that our Raspberry Pi can continue to communicate with other nodes even if we reboot the device.
You need to configure a static IP address and then set up port forwarding so that your Raspberry Pi can continue to communicate with other nodes even if you reboot the device.

For instructions on how to set a static IP address in Ubuntu, see Method 1 (command line) or Method 2 (GUI) in [How to Assign Static IP Address on Ubuntu Linux](https://itsfoss.com/static-ip-ubuntu/).

## Allow connections to port 8333

In our router, we need to allow connections to port 8333. This is the port that allows the node to sync properly.
In your router, you need to allow connections to port 8333. This is the port that allows the node to sync properly.

For details on how to allow port forwarding, please consult your router's manual. You typically need to include your device's static IP address and the port number (8333) in the Port Forwarding or NAT Forwarding setting, depending on your router.

!!! warning

If you don't configure a static IP address, you may encounter connection issues when you restart or reboot your Raspberry Pi. By setting a static IP address, you can make sure the same IP address is still allowing communication from port 8333.
:::warning

If you don't configure a static IP address, you may encounter connection issues when you restart or reboot your Raspberry Pi. By setting a static IP address, you can make sure the same IP address is still allowing communication from port 8333.

:::

## Turn on swap

We need our Bitcoin Cash Node to continue running if the RAM on our Raspberry Pi gets full. To address this, we need to enable swap on our device.
You need your Bitcoin Cash Node to continue running if the RAM on your Raspberry Pi gets full. To address this, you need to enable swap on your device.

For instructions on how to check if swap is enabled and configure swap appropriately, see [How to Add Swap Space on Ubuntu 20.04](https://www.cloudbooklet.com/how-to-add-swap-space-on-ubuntu-20-04/).

!!! note

You can experiment with this as necessary, but the Raspberry Pi might become unresponsive if swap is turned off or does not have enough RAM allocated.
:::note

You can experiment with this as necessary, but the Raspberry Pi might become unresponsive if swap is turned off or does not have enough RAM allocated.

:::
Original file line number Diff line number Diff line change
@@ -1,48 +1,50 @@
# Setting up Bitcoin Cash Node
# Set up Bitcoin Cash Node

## Download and extract the Bitcoin Cash Node package

Open a web browser on the Raspberry Pi, and go to the **[Download](https://bitcoincashnode.org/en/download.html)** page on the Bitcoin Cash Node website.

Make sure the latest version of BCHN is selected. Under **Linux**, download the **AARCH 64 (tar)** package to the home directory on our mounted SSD. Downloading this compressed package should take about 1 minute.
Make sure the latest version of BCHN is selected. Under **Linux**, download the **AARCH 64 (tar)** package to the home directory on your mounted SSD. Downloading this compressed package should take about 1 minute.

![Bitcoin Cash Node download screen](https://github.com/josh-wong/bitcoin-cash-node-on-raspberry-pi/blob/main/docs/assets/screenshots/bitcoin_cash_node_download.png?raw=true)

After the compressed package finishes downloading, let's extract the compressed package.
After the compressed package finishes downloading, you'll need to extract the compressed package.

To do so, let's open **Terminal** and go to the directory where you downloaded the package to. Be sure to replace `<SSD-DIRECTORY-CONTAINING-DOWNLOADED-PACKAGE>` in the command below with the directory where we saved the compressed package to.
To do so, open **Terminal** and go to the directory where you downloaded the package to, replacing `<SSD_DIRECTORY_CONTAINING_DOWNLOADED_PACKAGE>` in the command below with the directory where you saved the compressed package to.

```console
cd /<SSD-DIRECTORY-CONTAINING-DOWNLOADED-PACKAGE>
cd /<SSD_DIRECTORY_CONTAINING_DOWNLOADED_PACKAGE>
```

Next, let's extract the compressed package. When running the following command in **Terminal**, be sure to replace `<VERSION-NUMBER-DOWNLOADED>` with the version number that matches the package we downloaded.
Next, extract the compressed package. When running the following command in **Terminal**, replacing `<VERSION_NUMBER_DOWNLOADED>` with the version number that matches the package you downloaded.

```console
sudo tar -xvzf bitcoin-cash-node-<VERSION-NUMBER-DOWNLOADED>-aarch64-linux-gnu.tar.gz
sudo tar -xvzf bitcoin-cash-node-<VERSION_NUMBER_DOWNLOADED>-aarch64-linux-gnu.tar.gz
```

While we're in this directory, let's create a new directory to store the blockchain data and keep things tidy. In **Terminal**, run the following command.
While you're in this directory, create a new directory to store the blockchain data and keep things tidy. In **Terminal**, run the following command.

```console
mkdir blockchain-data
```

## Run Bitcoin Cash Node

Now that we've extracted the Bitcoin Cash Node package, let's run the software and start downloading the blockchain transactions to our node.
Now that you've extracted the Bitcoin Cash Node package, you need to run the software and start downloading the blockchain transactions to your node.

!!! note

Downloading all the transactions in the blockchain will take a while. You may want to start the Bitcoin Cash Node software a couple hours before going to bed, as you may experience a slow Internet connection.
:::note

To start the Bitcoin Cash Node software, run the following command in **Terminal**. Be sure to replace `<VERSION-NUMBER-DOWNLOADED>` with the version number that matches the package we downloaded.
Downloading all the transactions in the blockchain will take a while. You may want to start the Bitcoin Cash Node software a couple hours before going to bed, as you may experience a slow Internet connection.

:::

To start the Bitcoin Cash Node software, run the following command in **Terminal**, replacing `<VERSION_NUMBER_DOWNLOADED>` with the version number that matches the package you downloaded.

```console
sudo bitcoin-cash-node-<VERSION-NUMBER-DOWNLOADED>/bin/bitcoin-qt
sudo bitcoin-cash-node-<VERSION_NUMBER_DOWNLOADED>/bin/bitcoin-qt
```

The Bitcoin Cash Node software then prompts us to specify where to download the blockchain transactions to.
The Bitcoin Cash Node software then prompts you to specify where to download the blockchain transactions to.

Under **Use a custom data directory**, click the **three dots** to choose a directory.

Expand All @@ -60,8 +62,10 @@ After all the Bitcoin Cash transactions have finished downloading to your SSD, y

To monitor inbound and outbound traffic on your node, click **Window** in the menu bar and choose **Network Traffic**. From here, you can see how much data is being transferred to and from your node.

!!! note

The "Received" and "Sent" under "Totals" will reset if you restart the Bitcoin Cash Node software. Additionally, the network traffic will reset if you move the slider below the graph.
:::note

The "Received" and "Sent" under "Totals" will reset if you restart the Bitcoin Cash Node software. Additionally, the network traffic will reset if you move the slider below the graph.

:::

![Bitcoin Cash Node network traffic 30 minutes](https://github.com/josh-wong/bitcoin-cash-node-on-raspberry-pi/blob/main/docs/assets/screenshots/bitcoin_cash_node_network_traffic_30_minutes.png?raw=true)
Original file line number Diff line number Diff line change
@@ -1,44 +1,50 @@
# Setting up your Bitcoin Cash wallet
# Set up your Bitcoin Cash wallet

Your Bitcoin Cash wallet has already been created at this point, so let's secure it with a password and back it up.
Your Bitcoin Cash wallet has already been created at this point, so you should secure it with a password and back it up.

!!! warning

The instructions in this section are very important. Neglecting to secure your wallet with a password and backing it up could result in you losing the Bitcoin Cash that you receive from others.
:::warning

The instructions in this section are very important. Neglecting to secure your wallet with a password and backing it up could result in you losing the Bitcoin Cash that you receive from others.

:::

## Create a password for your wallet

Let's secure your wallet with a password. You will need this password to restore it from the backup, which you will create after setting a password.
You should secure your wallet with a password. You will need this password to restore it from the backup, which you will create after setting a password.

In the menu bar, click **Settings**, then select **Encrypt Wallet**. When the password setup window appears, enter a secure password. Enter the same password again to confirm it.

!!! warning

Be sure to remember this password. Write it down and put it in a safe, for example.
:::warning

Be sure to remember this password. Write it down and put it in a safe, for example.

:::

After you have successfully encrypted your wallet with a password, the following confirmation screen will appear. Please carefully read the notice, then click **OK**.

![Bitcoin Cash Node wallet encrypted notice](https://github.com/josh-wong/bitcoin-cash-node-on-raspberry-pi/blob/main/docs/assets/screenshots/bitcoin_cash_node_wallet_encrypted_notice.png?raw=true)

## Back up your wallet

Now, let's back up your wallet.
Now, you should back up your wallet.

Backing up your wallet let's you restore it if the device hosting your node and wallet encounters a catastrophic failure.
Backing up your wallet lets you restore it if the device hosting your node and wallet encounters a catastrophic failure.

In the menu bar, click **File** and select **Backup Wallet**.

When the directory window appears, choose a directory to save the wallet data (.dat) file to. If you don't have your Raspberry Pi set up to communicate with other computers on your network, save the wallet file (.dat) to your Raspberry Pi first and then immediately save it to another device for safe-keeping.

!!! warning

Do not keep your wallet backup on the same device that hosts your node and wallet. If your device encounters a catastrophic failure, you will not be able to restore the wallet from the backup. Instead, save the wallet backup to a secure, reliable device or devices.
:::warning

Do not keep your wallet backup on the same device that hosts your node and wallet. If your device encounters a catastrophic failure, you will not be able to restore the wallet from the backup. Instead, save the wallet backup to a secure, reliable device or devices.

:::

Once you have chosen a location, click **OK**.

## Optional: Receive Bitcoin Cash in your wallet

Finally, let's test your wallet.
Finally, you should test your wallet.

Click the **Receive** icon. Fill out the information that you consider necessary for your records. All fields are optional and are for your reference.

Expand Down
24 changes: 0 additions & 24 deletions docs/installation-and-setup/index.md

This file was deleted.

26 changes: 26 additions & 0 deletions docs/installation-and-setup/index.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
# Overview

This tutorial describes how to install and set up [Bitcoin Cash Node](https://bitcoincashnode.org/) on a Raspberry Pi 4 running Ubuntu Desktop (64-bit). You'll focus on using the Bitcoin Cash Node graphical user interface (GUI) so that you can visualize processes on the blockchain and your Bitcoin Cash wallet transactions.

These instructions are intended for those who have basic knowledge of the Ubuntu environment and Linux commands.

## Prerequisites

- Raspberry Pi 4 (4 GB of RAM or more)
- Ubuntu Desktop (64-bit) OS
- microSD card (32 GB or more)
- Micro USB-C power cable
- Micro HDMI cable
- Monitor with an HDMI interface
- Keyboard (USB or Bluetooth)
- USB mouse (USB or Bluetooth)
- External SSD (500 GB or more)

:::note

For the data associated with the Bitcoin Cash blockchain, you should reserve at least 200 GB. Be sure your SSD is large enough to accommodate the growing blockchain if you want to keep verifying transactions for the foreseeable future on your Raspberry Pi.

- Raspberry Pi case with a GPIO fan and heat sinks (recommended)
- Reliable Internet connection

:::
File renamed without changes.
52 changes: 0 additions & 52 deletions docs/test.md

This file was deleted.

Loading

0 comments on commit 4af8983

Please sign in to comment.