6

I'm in the process of setting up a HA baking infrastructure with multiple full nodes and a single baking service that can move to a different node if one goes down. I think I've got a handle on most things except nonce-revelations. What are nonce-revelations and what does it mean to miss one?

7

Fundamentally, nonces are used by the blockchain to create randomness, such as choosing the snapshot for a cycle. Nonces are created by bakers and all the nonces for the cycle are combined to create a random seed. When baking blocks, you may be required to reveal a nonce in the next cycle. This nonce requirement is determinstic and happens every 32 blocks. Specifically, if you baked blockNumber % 32 == 0, you will be required to announce it the following cycle.

If you are using the tezos binaries, the nonce will be saved by default in ~/.tezos-client/nonces. In the following cycle, the baker binary will automatically detects the saved nonce and reveal it. This usually happens in the first 5 blocks in the next cycle. The penalty for not revealing the nonce is the lost of the rewards for the baked block. Therefore, bakers have incentives to reveal their nonce. As a side note, I should mention that making the nonce reveal has a 1/8 XTZ reward for the block baker (not the revealer but the baker who includes the nonce operation in their block).

In your scenario, to make the infrastructure highly available across multiple nodes. You will definitely need to account for how to handle the nonce file(s) as you'll have one cycle to reveal the nonce or you will forfeit your block rewards.

| improve this answer | |
  • 1
    Noted! Thanks for a great and enlightening answer 👍 Sounds like the nonce data ideally should be synced between all nodes (so if the baker moves it can still reveal them). However I'm happy to hear there is no penalty (other than missed reward) to not reveal them. – asbjornenge Feb 24 '19 at 20:27
  • If you're using a hardware wallet, the nonce is deterministically derived from an HMAC signature on your HW device so you can't lose your nonces. – Elliot Cameron Nov 20 '19 at 18:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.