You don't want to stay in the Byron era forever, right? Of course not. Then move on to the Shelley era, but before you can do that you need to go to protocol version 1.0.0 (Ouroboros BFT). This was referred to as the Byron Reboot and was the only real hard fork in the traditional sense.
Upgrading to Ouroboros BFT
Update your scripts that run the nodes to include Shelley keys.
Create, submit, and vote on an update proposal:
Copy cardano-cli byron governance create-update-proposal \
--filepath transactions/updateprotov1.proposal \
--testnet-magic 42 \
--signing-key bft0/byron.000.key \
--protocol-version-major "1" \
--protocol-version-minor "0" \
--protocol-version-alt "0" \
--application-name "cardano-sl" \
--software-version-num "1" \
--system-tag "linux" \
--installer-hash 0
Submit the update proposal:
Copy cardano-cli byron submit-update-proposal \
--testnet-magic 42 \
--filepath transactions/updateprotov1.proposal
Monitor the log files from the node, you should see:
Copy Event: LedgerUpdate (HardForkUpdateInEra Z (WrapLedgerUpdate {unwrapLedgerUpdate = ByronUpdatedProtocolUpdates [ProtocolUpdate {protocolUpdateVersion = 1.0.0, protocolUpdateState = UpdateRegistered (SlotNo )}]}))
Now create the votes for both of your genesis keys:
Copy cardano-cli byron governance create-proposal-vote \
--proposal-filepath transactions/updateprotov1.proposal \
--testnet-magic 42 \
--signing-key bft0/byron.000.key \
--vote-yes \
--output-filepath transactions/updateprotov1.000.vote
Submit the first vote:
Copy cardano-cli byron submit-proposal-vote \
--testnet-magic 42 \
--filepath transactions/updateprotov1.000.vote
You should see UpdateActive
:
Copy ...
Event: LedgerUpdate (HardForkUpdateInEra Z (WrapLedgerUpdate {unwrapLedgerUpdate = ByronUpdatedProtocolUpdates [ProtocolUpdate {protocolUpdateVersion = 1.0.0, protocolUpdateState = UpdateActive (fromList [KeyHash {unKeyHash = }])}]}))
...
Create and submit the second vote:
Copy cardano-cli byron governance create-proposal-vote \
--proposal-filepath transactions/updateprotov1.proposal \
--testnet-magic 42 \
--signing-key bft1/byron.001.key \
--vote-yes \
--output-filepath transactions/updateprotov1.001.vote
Copy cardano-cli byron submit-proposal-vote \
--testnet-magic 42 \
--filepath transactions/updateprotov1.001.vote
This vote completes the vote threshold; the update proposal is confirmed:
Copy ...
Event: LedgerUpdate (HardForkUpdateInEra Z (WrapLedgerUpdate {unwrapLedgerUpdate = ByronUpdatedProtocolUpdates [ProtocolUpdate {protocolUpdateVersion = 1.0.0, protocolUpdateState = UpdateConfirmed (SlotNo )}]}))
...
It's time to endorse the proposal. Update your config file to indicate that you are ready to move to protocol LastKnownBlockVersion-Major
: 1,
Linux macOS
Copy sed -i configuration/config.json \
-e 's/"LastKnownBlockVersion-Major":0/"LastKnownBlockVersion-Major":1/'
Copy gsed -i configuration/config.json \
-e 's/"LastKnownBlockVersion-Major":0/"LastKnownBlockVersion-Major":1/'
IMPORTANT: You need to restart the nodes to pick up the new configuration.
As soon as you restart the second node and produce a block with it, the update proposal will receive the required endorsements. It becomes a candidate, and the epochNo
is set at which the transition will take place if it becomes a stable candidate.
Copy ...
Event: LedgerUpdate (HardForkUpdateInEra Z (WrapLedgerUpdate {unwrapLedgerUpdate = ByronUpdatedProtocolUpdates [ProtocolUpdate {protocolUpdateVersion = 1.0.0, protocolUpdateState = UpdateCandidate (SlotNo ) (EpochNo )}]}))
...
2k slots later, it becomes a stable candidate.
Copy ...
Event: LedgerUpdate (HardForkUpdateInEra Z (WrapLedgerUpdate {unwrapLedgerUpdate = ByronUpdatedProtocolUpdates [ProtocolUpdate {protocolUpdateVersion = 1.0.0, protocolUpdateState = UpdateStableCandidate (EpochNo )}]}))
...
The update proposal is adopted at the epoch transition:
Copy Event: LedgerUpdate (HardForkUpdateInEra Z (WrapLedgerUpdate {unwrapLedgerUpdate = ByronUpdatedProtocolUpdates []}))
The Shelley hard fork
Now you can upgrade to protocol version 2.0, the Shelley era.
First, add the Shelley keys to your BFT nodes starting scripts:
Linux macOS
Copy sed -i '$ s/$/ --shelley-kes-key shelley.000.kes.skey --shelley-vrf-key shelley.000.vrf.skey --shelley-operational-certificate shelley.000.opcert.json/' bft0/startnode.sh
Copy sed -i '$ s/$/ --shelley-kes-key shelley.001.kes.skey --shelley-vrf-key shelley.001.vrf.skey --shelley-operational-certificate shelley.001.opcert.json/' bft1/startnode.sh
Copy gsed -i '$ s/$/ --shelley-kes-key shelley.000.kes.skey --shelley-vrf-key shelley.000.vrf.skey --shelley-operational-certificate shelley.000.opcert.json/' bft0/startnode.sh
Copy gsed -i '$ s/$/ --shelley-kes-key shelley.001.kes.skey --shelley-vrf-key shelley.001.vrf.skey --shelley-operational-certificate shelley.001.opcert.json/' bft1/startnode.sh
Create the update proposal:
Copy cardano-cli byron governance create-update-proposal \
--filepath transactions/updateprotov2.proposal \
--testnet-magic 42 \
--signing-key bft0/byron.000.key \
--protocol-version-major "2" \
--protocol-version-minor "0" \
--protocol-version-alt "0" \
--application-name "cardano-sl" \
--software-version-num "1" \
--system-tag "linux" \
--installer-hash 0
Submit the proposal:
Copy cardano-cli byron submit-update-proposal \
--testnet-magic 42 \
--filepath transactions/updateprotov2.proposal
Create the votes:
Copy cardano-cli byron governance create-proposal-vote \
--proposal-filepath transactions/updateprotov2.proposal \
--testnet-magic 42 \
--signing-key bft0/byron.000.key \
--vote-yes \
--output-filepath transactions/updateprotov2.000.vote
Copy cardano-cli byron governance create-proposal-vote \
--proposal-filepath transactions/updateprotov2.proposal \
--testnet-magic 42 \
--signing-key bft1/byron.001.key \
--vote-yes \
--output-filepath transactions/updateprotov2.001.vote
Submit the votes:
Copy cardano-cli byron submit-proposal-vote \
--testnet-magic 42 \
--filepath transactions/updateprotov2.000.vote
cardano-cli byron submit-proposal-vote \
--testnet-magic 42 \
--filepath transactions/updateprotov2.001.vote
Then, adjust the config file again to go to protocol version 2.0:
Linux macOS
Copy sed -i 's/"LastKnownBlockVersion-Major":1/"LastKnownBlockVersion-Major":2/' configuration/config.json
Copy gsed -i 's/"LastKnownBlockVersion-Major":1/"LastKnownBlockVersion-Major":2/' configuration/config.json
Restart the nodes to pick up the new configuration and endorse the proposal:
Copy Event: LedgerUpdate (HardForkUpdateInEra Z (WrapLedgerUpdate {unwrapLedgerUpdate = ByronUpdatedProtocolUpdates [ProtocolUpdate {protocolUpdateVersion = 2.0.0, protocolUpdateState = UpdateRegistered (SlotNo )}]}))
....
Event: LedgerUpdate (HardForkUpdateInEra Z (WrapLedgerUpdate {unwrapLedgerUpdate = ByronUpdatedProtocolUpdates [ProtocolUpdate {protocolUpdateVersion = 2.0.0, protocolUpdateState = UpdateConfirmed (SlotNo )}]}))
...
Event: LedgerUpdate (HardForkUpdateInEra Z (WrapLedgerUpdate {unwrapLedgerUpdate = ByronUpdatedProtocolUpdates [ProtocolUpdate {protocolUpdateVersion = 2.0.0, protocolUpdateState = UpdateStablyConfirmed (fromList [])}]}))
....
Event: LedgerUpdate (HardForkUpdateInEra Z (WrapLedgerUpdate {unwrapLedgerUpdate = ByronUpdatedProtocolUpdates [ProtocolUpdate {protocolUpdateVersion = 2.0.0, protocolUpdateState = UpdateCandidate (SlotNo ) (EpochNo )}]}))
...
Event: LedgerUpdate (HardForkUpdateInEra Z (WrapLedgerUpdate {unwrapLedgerUpdate = ByronUpdatedProtocolUpdates [ProtocolUpdate {protocolUpdateVersion = 2.0.0, protocolUpdateState = UpdateStableCandidate (EpochNo )}]}))
...
Event: LedgerUpdate (HardForkUpdateTransitionDone <EraIndex Byron> <EraIndex Shelley> (EpochNo ))
IMPORTANT: Take note of the epoch at which the Shelley hard fork takes place. In this case, the Shelley hard fork happened during the transition to epoch 3. The Byron epochs lasted 450 slots (10 times the security parameter k) so it happened at slot 1350. This information will be useful later, so write it down somewhere.
Last updated 10 months ago