Zcash Full Node and Wallet Setup ( Zcashd and Zcash-cli )
We are going to show you how to build, install, and setup a Zcash wallet which will functiona as a full node. We tested this on Ubuntu Server 20.04.
WARNING - Keep your private key PRIVATE. Anyone with the key can fully control the wallet.
Pull down and install prerequisites ( including build tools ) like this:
sudo apt update
sudo apt-get install \
build-essential pkg-config libc6-dev m4 g++-multilib \
autoconf libtool ncurses-dev unzip git python3 python3-zmq \
zlib1g-dev curl bsdmainutils automake libtinfo5
Clone, checkout, setup, and build Zcash like this:
git clone https://github.com/zcash/zcash.git
cd zcash/
git checkout v4.5.1
./zcutil/fetch-params.sh
./zcutil/clean.sh
./zcutil/build.sh -j$(nproc)
Make sure that his directory and config file exist. It is OK if they are empty but they should exist. The default values will be used if the config file is empty.
mkdir -p ~/.zcash
touch ~/.zcash/zcash.conf
Start the node like this. It will take a while to actually download the entire blockchain.
./src/zcashd
After fully syncing You shoujld be albe to run commands like this:
./src/zcash-cli getinfo
./src/zcash-cli getwalletinfo
./src/zcash-cli getbalance
You can find your private keys and transaction information for the embedded wallet here. KEEP THIS PRIVATE.
~/.zcash/wallet.dat
Upgrading Zcash
If you need to upgrade you gan goto your Zcash directory ( the same one you built from ) and run the following:
git fetch origin
git checkout v4.5.1
./zcutil/clean.sh
./zcutil/build.sh -j$(nproc)