Building cardano-node on debian 10


I’ve been trying several time to build the cardano-node on a debian10 installation and recently found this post Building the Haskell cardano-node on Linux. I have not yet tried its solution but I wanted to signal that although I installed pre-requisites as stated here

mkdir "$HOME/tmp";cd "$HOME/tmp"
chmod 755
. "${HOME}/.bashrc"

I run in an error running building $CNODE_HOME/scripts/

[ 6 of 30] Compiling Cardano.CLI.Byron.Key ( src/Cardano/CLI/Byron/Key.hs, /home/userfoo/git/cardano-node/dist-newstyle/build/x86_64-linux/ghc-8.6.5/cardano-cli-1.12.0/build/Cardano/CLI/Byron/Key.o )

src/Cardano/Tracing/Tracers.hs:49:1: error: [-Wunused-imports, -Werror=unused-imports]
    The import of ‘Ouroboros.Consensus.Ledger.SupportsProtocol’ is redundant
      except perhaps to import instances from ‘Ouroboros.Consensus.Ledger.SupportsProtocol’
    To import instances alone, use: import Ouroboros.Consensus.Ledger.SupportsProtocol()
49 | import           Ouroboros.Consensus.Ledger.SupportsProtocol (LedgerSupportsProtocol)

full error log paste


A distant Virtual Private Server (VPS) with Debian 10 (buster)

Preparation (updating stuff)

   sudo apt-get update -y
sudo apt-get -y install build-essential pkg-config libffi-dev libgmp-dev libssl-dev libtinfo-dev libsystemd-dev zlib1g-dev make g++ tmux git jq wget libncursesw5 -y

Install Haskell stuff


This was kind of new to me. I never touched Haskell stuff before. It did
not always go smoothly and I had to go back and forth a few times to the
Haskell Cabal overview . But
the the following worked

apt-get install cabal-install
cabal update
cabal install Cabal cabal-install 

Latest ghc version

I’m not sure why I ended up installing this Glorious Glasgow Haskell
. It’s probably because in
latter steps required it, but I can’t say which. Any how, I adapted the
code from the last snippet of this troubleshooting
I used the latest ghc for
Debian 10
and the

tar -xf ghc-<latest-os-version>-linux.tar.xz
rm ghc-<latest-os-version>-linux.tar.xz 
cd ghc-<latest-os-version>

Cardano-node stuff

At that point I have 2 cabal executables on the VPS.

  • /usr/bin/cabal --version -->
  • home/foouser.cabal/bin/cabal --version -->


I make sure to use the second, and the I check for the latest tag of the
cardano-node git

git clone 
cd cardano-node
git fetch --all --tags
git checkout tags/<latest-tag>
cabal install cardano-node cardano-cli  --installdir=$HOME/.local/bin


Before tired I another launch I quickly checked the cardano-node/scripts
folder and file. Very instructive.

cardano-node run --cabal

Cabalinnistic ! it’s a live !