How to Fork Bitcoin — Part 3

Jordan Baczuk
5 min readMay 24, 2019

In this Part 3 (Part 2 here) we will test our blockchain based on the customizations made previously.

Learn more and join people in 48 countries around the world in the Complete Bitcoin/Blockchain Course.

Testing

Now that we have designed our blockchain, let’s try it out. First let’s make sure it builds and installs:

$ sudo make install

Then, let’s make sure it runs. We’ll just run it in the foreground to see the output on standard out:

$ learncoind -debug -printtoconsole -regtest

If there are no errors, then we can stop it (CTRL+c), then run it in the background with:

$ learncoind -debug -daemon

Configuration File

Let’s create a configuration file, we can start with this template from the Bitcoin wiki and we’ll save it to ~/.learncoin/learncoin.conf:

##
## bitcoin.conf configuration file. Lines beginning with # are comments.
##

# Network-related settings:
# Run on the test network instead of the real bitcoin network.
#testnet=0
# Run a regression test network
#regtest=0
# Connect via a SOCKS5 proxy
#proxy=127.0.0.1:9050

--

--