💡
Prepare your baker for Ithaca2
Ithaca2 is one of the most important amendments so far. To continue baking after activation, bakers need to upgrade their infrastructure before the end of the adoption period.
This tutorial provides practical commands to successfully upgrade a baker's infrastructure. As a reminder, we recently wrote an article describing the breaking changes regarding Ithaca2 (Psithaca2) and its new consensus algorithm: Tenderbake.
After Ithaca2 is activated, it will be technically impossible to bake without Octez v12.2 or later.
This version contains all binaries (baker and accuser) necessary for Ithaca2 and the associated testnet.

Changes regarding the baker's signing scheme

With Tenderbake, endorsement operations now consist of a level, a round, a slot, and a payload hash. A Baker can emit at most one endorsement per round, but it is allowed to emit more endorsements per level. The former high-water mark mechanism used by the signer has been adapted accordingly. The tezos-signer for previous protocols signed messages with the following format:
<magic_byte><chain_id><block|endorsement>
Now, they have the following shape:
<magic_byte><chain_id><block|preendorsement|endorsement>,
where the magic byte has changed from 0x01 (for blocks) and 0x02 (for endorsements), to 0x11 (for blocks), 0x12 (for preendorsements), 0x13 (for endorsements).
The signer is authorized to sign whenever the level is strictly higher than the previous level, or the level is the same, but the round is strictly higher. Octez v12.2 contains the updated signer. Bakers using a Ledger Nano must upgrade their Ledger's software (see instructions). Any other custom solution must be adapted to the signing logic.
Likewise, if you use tezos-signerdon't forget to update, and relaunch it.

Upgrading to v12.2 using released binaries

See our official technical documentation here.

Upgrading to v12.2 using Docker

Without Docker Compose

If you launch your node with a simple docker command, you should use the v12.2 image and the following image to run your node:
1
docker run -d --name container_name tezos/tezos:v12.2 tezos-node --rpc-addr 127.0.0.1:8732
Copied!
Then you can, for example, access the created container and launch your Ithaca2 daemons:
1
docker exec -it container_name sh
2
#import your baking key
3
4
#The baking daemon
5
tezos-baker-012-Psithaca --endpoint http://127.0.0.1:8732 run with local node /run/tezos/node/data/
6
7
#The accuser daemon
8
tezos-accuser-012-Psithaca --endpoint http://127.0.0.1:8732 run
Copied!

With Docker Compose

Docker Compose users only need to change the docker image and relaunch the containers to update Octez:
... services: [type]-node: image: tezos/tezos:v12.2 ...
Afterward, launch your baking/accuser daemons as you normally do.

Upgrading to v12.2 building from sources

Note: it requires basic knowledge of the OPAM package manager and the OCaml packages workflow.
Step 1: Access your tezos repository and execute the following commands:
1
git fetch
2
git checkout v12.2
3
rm -rf _opam _build
4
make build-deps
5
eval $(opam env)
6
make
Copied!
Step 2: Launch the binaries
Note, that there is no endorser daemon anymore. The baker daemon performs both baking and endorsement operations. Launch your baker:
1
tezos-baker-012-Psithaca run #with optional arguments
2
Global options:
3
-d --base-dir <path>: client data directory (absent: TEZOS_CLIENT_DIR env)
4
-c --config-file <path>: configuration file
5
-t --timings: show RPC request times
6
--chain <hash|tag>: chain on which to apply contextual commands (possible tags are 'main' and 'test')
7
-b --block <hash|tag>: block on which to apply contextual commands (possible tags are 'head' and 'genesis')
8
-w --wait <none|<int>>: how many confirmation blocks before to consider an operation as included
9
-p --protocol <hash>: use commands of a specific protocol
10
-l --log-requests: log all requests to the node
11
-A --addr <IP addr|host>: [DEPRECATED: use --endpoint instead] IP address of the node
12
-P --port <number>: [DEPRECATED: use --endpoint instead] RPC port of the node
13
-S --tls: [DEPRECATED: use --endpoint instead] use TLS to connect to node.
14
-m --media-type <json, binary, any or default>: Sets the "media-type" value for the "accept" header for RPC requests t
15
Copied!
And the accuser:
1
tezos-accuser-012-Psithaca run
Copied!
Bakers using a Ledger hardware wallet for operation signing will need to upgrade the Tezos Baking app to v.2.2.15 or later. See instructions below.

Upgrading Ledger Nano software

Only the Tezos Baking app v2.2.15 or later is compatible with Ithaca2 (due to the changes imposed by the adoption of the Tenderbake consensus algorithm). It is however also compatible with the current protocol version, so it is safe (and advisable) to upgrade now.
Henceforth, this is the list of tags supported by the Ledger apps:
1
EMMY_BLOCK 0x01
2
EMMY_ENDORSEMENT 0x02
3
TRANSFER 0x03
4
TENDERBAKE_BLOCK 0x11
5
TENDERBAKE_PREENDORSEMENT 0x12
6
TENDERBAKE_ENDORSEMENT 0x13
Copied!
To upgrade, bakers will need to
  • Exit the Tezos Baking app;
  • Upgrade the Tezos Wallet and Tezos Baking apps using the Ledger Live application;
  • Authorize the Ledger to bake for their specific key;
  • Relaunch the Baking App.
To avoid missing assigned baking/endorsing slots, owning a second Ledger Nano can be useful for signing operations while the first Ledger Nano is being upgraded.
The following example uses a Ledger Nano S.
Step 1: Exit Tezos Baking application and launch Ledger Live.
On the bar at the bottom left, access the Manager section and search for Tezos. Upgrade both the Tezos Wallet and Tezos Baking applications to version 2.2.15.
If you don't see the Tezos Baking app, you may need to activate Ledger Live's developer mode.
Ledger Live application
Step 2: Import your Tezos baking address by clicking on Add account, and follow the steps to add your Tezos account.
Add account
Choose an account to import
Account successfully added
Step 3: Before launching the baker and accuser daemons, you need to re-authorize your Ledger to bake for your baking key.
1
tezos-client setup ledger to bake for <account-alias-or-ledger-uri> #it is possible to provide a watermark with --main-hwm <HWM>
Copied!
Step 4: Your Nano S is now upgraded, and you are ready to bake on Ithaca2. Don't forget to launch the Tezos Baking app! Happy baking!