Skip to main content

Dynamic Build

We at the Armada Alliance actively build the required software packages needed to run a Cardano stake pool node on ARM-based computers like the Raspberry Pi or Apple's MacMini M1._

caution

To use our dynamic arm64 cardano-node build requires libsodium and secp256k1.

tip

Current Official Cardano Node Version: 8.1.2

Overview 🗒

  • Check if libsodium is installed on the local machine
    • Build libsodium if not installed already
  • Download Cardano Node Dynamic build & configuration file
  • Extract the file's content
  • Check if you already have Cardano Node service running
    • Safely shutdown your Cardano node if it is running
  • Replace the old binaries with the new cardano-node and cardano-cli
  • Check cardano-node and cli version is updated to the current version
  • Replace old configuration files with new ones (if needed)
  • Restart your Cardano Node
  • Check that node has started properly

Prerequisites for Ubuntu 20.04

>_ Terminal
sudo apt install automake build-essential pkg-config libffi-dev libgmp-dev libssl-dev libtinfo-dev libsystemd-dev zlib1g-dev make g++ tmux git jq wget libncursesw5 libtool autoconf liblmdb-dev -y

For Ubuntu 22.04 LTS fresh install (missing libssl.so.1.1)

>_ Terminal
wget http://ports.ubuntu.com/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2_arm64.deb

sudo dpkg -i libssl1.1_1.1.1f-1ubuntu2_arm64.deb

rm libssl1.1_1.1.1f-1ubuntu2_arm64.deb

Building Libsodium

Check if libsodium is already installed first.

>_ Terminal
which libsodium

If this returns no output you need to install libsodium.

Instructions to install libsodium

Create a working directory for your builds:

>_ Terminal
mkdir -p ~/src
cd ~/src

Download and install libsodium:

>_ Terminal
git clone https://github.com/input-output-hk/libsodium
>_ Terminal
cd libsodium
git checkout dbb48cce5429cb6585c9034f002568964f1ce567
>_ Terminal
./autogen.sh
>_ Terminal
./configure
>_ Terminal
make
sudo make install

Add the following to your .bashrc file and source it:

>_ Terminal
echo "export LD_LIBRARY_PATH="/usr/local/lib:$LD_LIBRARY_PATH"" >> ~/.bashrc

echo "export PKG_CONFIG_PATH="/usr/local/lib/pkgconfig:$PKG_CONFIG_PATH"" >> ~/.bashrc

source ~/.bashrc

Instructions to install secp256k1

Create a working directory if you have not already

>_ Terminal
mkdir -p ~/src && cd ~/src

Download and install secp256k1

>_ Terminal
git clone https://github.com/bitcoin-core/secp256k1.git
>_ Terminal
cd secp256k1
git checkout ac83be33
>_ Terminal
git reset --hard $SECP256K1_REF
>_ Terminal
./autogen.sh
>_ Terminal
./configure  --enable-module-schnorrsig --enable-experimental
>_ Terminal
make
sudo make install

For those who run cardano-node as a systemd service, run the following:

sudo ldconfig

This ensures the system is aware of libsodium (not just at the user level).

Download the cardano-node & cli

Dynamic binaries and Cardano node configuration files provided by SRN pool 🙏 at our Github repository.

>_ Terminal
wget -O cardano-8_1_2-aarch64-ubuntu_2004.zip https://github.com/armada-alliance/cardano-node-binaries/blob/main/dynamic-binaries/8.1.2/cardano-8_1_2-aarch64-ubuntu_2004.zip?raw=true

Extract the content from the zip file.

>_ Terminal
unzip cardano-8_1_2-aarch64-ubuntu_2004.zip

Check if cardano-node is running already

caution

Now we need to make sure we do not have a cardano-node already running. If we do we must shut it down before proceeding.

You can check if you have a cardano-node process already running a few ways like usinghtop or by checking your systemd service.

If you have been following our Pi-Node guide you can check your cardano-node status and stop it using the following commands.

>_ Terminal
cardano-service status
cardano-service stop
info

If you use Linux's htop service just check for a processing running starting with cardano-node run and use SIGINT to terminate the process.

Replace the old binaries and config files with the new ones

If you are using the Pi-Node guide and your cardano-node & cli in ~/.local/bin

>_ Terminal
mv cardano-8_1_2-aarch64-ubuntu_2004/* ~/.local/bin

Check your cardano-node version

>_ Terminal
cardano-node --version

Output:

>_ Terminal
cardano-node 8.1.2 - linux-aarch64 - ghc-8.10
git rev d2d90b48c5577b4412d5c9c9968b55f8ab4b9767

Check your cardano-cli version

>_ Terminal
cardano-cli --version

Output:

>_ Terminal
cardano-cli 8.1.2 - linux-aarch64 - ghc-8.10
git rev d2d90b48c5577b4412d5c9c9968b55f8ab4b9767

Replace the Cardano node configuration files

info

This step is not needed every time you update your node, typically you only need to update/replace config files after hard fork events when moving into new eras of the Cardano blockchain.

Download the configuration files needed for the networks, now we just need to move them to our pool files directory.

>_ Terminal
cd $NODE_FILES
wget https://book.world.dev.cardano.org/environments/mainnet/config.json
wget https://book.world.dev.cardano.org/environments/mainnet/byron-genesis.json
wget https://book.world.dev.cardano.org/environments/mainnet/shelley-genesis.json
wget https://book.world.dev.cardano.org/environments/mainnet/alonzo-genesis.json
wget https://book.world.dev.cardano.org/environments/mainnet/topology.json
wget https://book.world.dev.cardano.org/environments/mainnet/conway-genesis.json

Restart the Cardano Node

Now we just need to restart our cardano-node service if you are using our Pi-Node guide use this command

>_ Terminal
cardano-service start

Wait a few seconds or so then check the status

>_ Terminal
cardano-service status