Step 1: Run an Octez node
The first thing you need to run a baker and a DAL node is a Tezos layer 1 node, which is an instance of the octez-node
program and part of the Octez suite of programs.
Installing Octez
The version of Octez to use depends on the Tezos network that you are using.
-
For Mainnet or Ghostnet, install the most recent release of Octez, including
octez-client
,octez-node
,octez-dal-node
, and the baker for the current protocol:-
On MacOS, run these commands:
brew tap serokell/tezos-packaging-stable https://github.com/serokell/tezos-packaging-stable.git
brew install tezos-client tezos-node tezos-dal-node tezos-baker-PsParisC -
On Linux and Windows WSL, download and install the built binaries from the Octez release page, as in this example for Ubuntu:
wget -O octez-binaries-20.3-linux-x86_64.tar.gz https://gitlab.com/tezos/tezos/-/package_files/150896058/download
tar xf octez-binaries-20.3-linux-x86_64.tar.gz
sudo cp octez-x86_64/octez* /usr/local/bin/
-
-
For Weeklynet, look up the necessary version of Octez at https://teztnets.com/weeklynet-about and install it with the instructions there.
For more installation options, see Installing Octez in the Octez documentation.
If you build from source, you can use the latest-release
branch to work with Ghostnet.
Running the layer 1 node
-
Initialize the Octez node for the network. For example, to initialize it for Ghostnet, run this command:
octez-node config init --network ghostnet
By default, the node stores its data in the folder
$HOME/.tezos-node
. If this directory is not empty, you may have need to rename it (to keep its data) or remove it. -
Download a rolling snapshot of the network from https://snapshot.tzinit.org based on the instructions on that site. For example, the command to download a Ghostnet snapshot from the European servers might look like this:
wget -O snapshot_file https://snapshots.eu.tzinit.org/ghostnet/rolling
-
Load the snapshot in the node by running this command:
octez-node snapshot import snapshot_file
-
Install the Zcash parameters as described Install Zcash Parameters in the Octez documentation.
-
Start the node:
octez-node run --rpc-addr 127.0.0.1:8732 --log-output="$HOME/octez-node.log"
At first launch, the node generates a fresh identity file used to identify itself on the network. Then it bootstraps the chain, which takes a variable amount of time depending on how many blocks need to be loaded. You don't need to wait for the node to bootstrap now.
-
Ensure that the node runs persistently. Look up how to run programs persistently in the documentation for your operating system. You can also refer to Run a persistent baking node on opentezos.com.
-
Optional: When the node has bootstrapped and caught up with the current head block, you can delete the snapshot file to save space.
In the meantime, you can continue the baking infrastructure while the node is bootstrapping. Continue to Step 2: Set up a baker account.