Skip to content

Commit

Permalink
docs: provide genesis-start for testnet 71
Browse files Browse the repository at this point in the history
Refs #4087.
  • Loading branch information
conorsch committed Mar 28, 2024
1 parent b0c8cc4 commit 524d089
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
10 changes: 7 additions & 3 deletions docs/guide/src/pd/chain-upgrade.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ After the node is restarted on the new version, it should be able to talk to the
Once enough validators with sufficient stake weight have upgraded, the network
will resume generating blocks.


## Genesis time

In order for the chain to start again after the upgrade, all nodes must be using the same genesis information,
Expand All @@ -39,6 +38,11 @@ until the `--genesis-start` time is reached, at which point it will resume proce
the community of validators can coordinate resumption of chain activity, even when operators perform migrate their ndoes
at slightly different times.

### Testnet 70 -> 71

For the first chain upgrade performed on a Penumbra testnet, use this value for genesis time: `{{ #include ../upgrade_genesis_time_70_71.md }}`.
See an example below for how to supply this value when performing the migration.

## Performing a chain upgrade

The following steps assume that `pd` is using the default home directory of `~/.penumbra/testnet_data/node0/pd`.
Expand All @@ -58,8 +62,8 @@ An example log message emitted by `pd migrate` without providing `--genesis-star
The value after `now=` is what should be copied. In practice, for testnets, Penumbra Labs will advise on a genesis time
and provide that value in the documentation. Or should we just pick a genesis start ahead of time, and use that for all?
-->
5. Apply the migration: `pd migrate --genesis-start "GENESIS_TIME" --target-directory ~/.penumbra/testnet_net/node0/pd-exported-state/ --migrate-archive ~/.penumbra/testnet_data/node0/pd-migrated-state-{{ #include ../penumbra_version.md }}.tar.gz`.
Replace `GENESIS_TIME` with the exact string: `XXXXX`.
5. Apply the migration: `pd migrate --genesis-start "{{ #include ../upgrade_genesis_time_70_71.md }}" --target-directory ~/.penumbra/testnet_net/node0/pd-exported-state/ --migrate-archive ~/.penumbra/testnet_data/node0/pd-migrated-state-{{ #include ../penumbra_version.md }}.tar.gz`.
You must use that precise genesis time, otherwise your node will not be able to reach consensus with the rest of the network.
6. Move the migrated state into place: `mkdir ~/.penumbra/testnet_data/node0/pd && mv ~/.penumbra/testnet_data/node0/pd-exported-state/rocksdb ~/.penumbra/testnet_data/node0/pd/`
7. Move the upgrade cometbft state into place: `cp ~/.penumbra/testnet_data/node0/pd-exported-state/genesis.json ~/.penumbra/testnet_data/node0/cometbft/config/genesis.json
&& cp ~/.penumbra/testnet_data/pd-exported-state/priv_validator_state.json ~/.penumbra/testnet_data/node0/cometbft/data/priv_validator_state.json`
Expand Down
1 change: 1 addition & 0 deletions docs/guide/src/upgrade_genesis_time_70_71.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
2023-12-09T00:08:24.225277473Z

0 comments on commit 524d089

Please sign in to comment.