Five Reasons Why Cosmos Validators Want to Participate in the Stargate Simulated Upgrade

Zaki Manian
Interchain Ecosystem Blog
5 min readNov 9, 2020

--

Note: The Cosmos ecosystem is constantly growing and expanding. This article's content is now outdated. For the latest content, see https://cosmos.network/.

Now that the Cosmos Stargate Release Candidate is at the RC-3, the next step will be to launch a Cosmos Stargate simulated upgrade of the Cosmos Hub with current ATOM validators participating. If you’re a Cosmos Hub validator, there are five key reasons why this simulated upgrade is one that you won’t want to miss. Afterwards, as soon as a final commit hash is available from the dev team, we’ll submit a proposal to upgrade the Hub .

Timeline

We aim to have this network live by Nov 11th . We are not restricting the genesis time so once we have quorum the network will go live.

If we fail to reach quorum by Nov 12 midnight UTC, we will publish an updated genesis file with additional public key rotations.

Sidenote: Public key rotation for network recovery is now built into gaia.

Update Nov 12, 2020

We have updated the genesis file after receiving new consensus public keys from some validators. We are hoping that we will have adequate participation with these genesis files.

What does a Cosmoshub-3 validator who missed the opportunity to submit a testnet consensus key do?

Well, it is time to run the simulated upgrade on production infrastructure!

TMKMS has an alpha release supporting softsign and yubihsm backends.

Polychain Labs has support for Stargate in their threshold signer.

Zondax is working on the ledger backend for TMKMS right now.

Hub Proposal

The Cosmos Hub Stargate testnet is the next stage in the testnet process. As we learned from the cosmoshub-2 to cosmoshub-3 process, the migration process of state from one blockchain to another carries it’s own risks that the validator community should evaluate.

We are doing some new things in this upgrade.

  • The migration code is all built into gaia.
  • We are starting the new chain from height +1 of the previous chain.
  • We are conducting the fund recovery operation from prop29 in this migration process. This is implemented in gaia as well.

We aim to create a decentralized testnet version of the Cosmos Hub. As part of our initial proposal to the Hub for the Stargate upgrade, we promised this step as necessary to simulate the required upgrade to the Cosmos Stargate version. Successful completion of this step will be a precursor to our completion of the first Cosmos Stargate proposal.

IBC simulation

Cosmos’ flagship, the Inter-Blockchain Communication (IBC) protocol, will be deployed with the Stargate update. IBC on Cosmos Stargate will enable other Cosmos blockchains to exchange the value of digital assets (tokens) and data with one another and the Cosmos Hub, whether they’re public or private blockchains. Simulating IBC deployment and completing a demonstration IBC will be critical to demonstrating to validators that IBC is ready for the Cosmos Hub. The IBC simulation will include the creation and sending of Cosmos Hub assets using IBC features.

Exchange partners that are seeking to confirm minimum IBC readiness with Cosmos Stargate will want to participate in the simulated migration to confirm that they are able to understand how their nodes will be able to accept non-ATOM assets from the Cosmos Hub. Exchanges have already made IBC readiness an important part of their upgrade to Cosmos Stargate. More of their readiness descriptions can be found in our Cosmos IBC Skills Matrix designed in coordination with the leading cryptocurrency exchanges that trade ATOM.

Governance Proposals

The simulation will also build experience around the governance process with Cosmos Stargate. We will shorten voting periods and quorum requirements because we don’t expect anyone other than command line users to be able to participate.

We will test activating ICS-20 transfers via a parameter change proposal and then the creation of new assets on the Hub after the proposal. We will also make a software upgrade proposal to give participants more experience with cosmovisor.

Cosmovisor Demo

Cosmos upgrade manager, now named Cosmovisor, will be deployed for testing on the Cosmos Hub Stargate testnet. Deploying Cosmovisor will demonstrate the new capability for non-halt chain upgrades on the Cosmos Hub mainnet. Cosmovisor is the upgrade module that allows for smooth and configurable management of upgrading binaries as a live chain is upgraded, and can be used to simplify validator devops while doing upgrades or to make syncing a full node for genesis simple. Cosmovisor will increase validator confidence in upgrading their nodes safely. If you’re not familiar with Cosmovisor, you can read about it here. Cosmovisor comes with a series of features that allows validator administrators to enjoy lower devops administration overhead of their servers. A video demonstration of Cosmovisor is also available here.

Draft Cosmos Hub Upgrade proposal

We have a draft Cosmos Hub governance proposal for the main hub upgrade in Github. Validators should use this testnet as a tool for evaluating the governance proposal.

The case we are making to the Cosmos Hub validators is that the cosmoshub-test-stargate release of Gaia is substantially similar to the final gaia v3.0Stargate release.

The remaining changes are related to an internal audit of IBC 1.0 conducted by the Informal and Interchain Berlin teams that have previously surfaced some things worth fixing before we take Stargate live.

How to participate

Validators can start participation today with the following three steps:

  1. Download and build the cosmoshub-test-stargate tag on Gaia 3.0.
  2. Setup a Cosmos Stargate node with the genesis file located here.
  3. Setup your private keys that were used to generate your replacement keys.
  4. Install the binaries and genesis file onto your Cosmos Hub Stargate Testnet node server.
  5. Start your node with gaiad start which conducts an extensive audit of genesis file consistency and soundness that takes about an hour. Alternatively use gaiad start --x-crisis-invariants which skips the audit and takes about 10 min to start up.
  6. We are running a seed node at c5e186e29d322788b8154723d04e1de018d38475@34.66.219.254:26656

Auditing the Migration

We have a snapshot of a gaiad cosmoshub-3 state. This needs to be unzipped into .gaiad/config/data

Using gaia v2.0.*, gaiad export > 3924406.cosmoshub-3.json

The migration command with gaia v3.0 is:

gaiad migrate ~/3924406.cosmoshub-3.json --chain-id=cosmoshub-test-stargate-a --initial-height=3924407 --replacement-cons-keys ~/iqlusion_work/stargate/validator_replacement.json > exported_genesis.json

Then pretty printed with jq . exported_genesis.json > genesis.json

The replacements key are from https://github.com/cosmosdevs/stargate/blob/master/validator_replacement.json

The quorum and voting period parameters were hand edited for the testnet.

Sha256sum of the genesis is 759413052c854ca75f3bfeec579e3cea00f283646b0ea0d30b6b15e4d13f814b

Conclusion

The Cosmos Hub Stargate testnet simulation is the final step before we propose an upgrade to the Cosmos Hub. The simulation will allow for testing of new features that include Cosmovisor for non-halt upgrades, Statesync for fast chain sync and IBC for asset creation and transmission on the Cosmos Hub. We will be deploying a gaia release based on SDK v0.40.0-rc3. Validators should check https://github.com/cosmos/gaia/tree/cosmoshub-test-stargate for the release. We will reach out to validators as well or you may open an issue on github here or contact us in the Cosmos Stargate discord channel.

--

--

Executive Director of the Trusted IoT Alliance and Board member of Restore the 4th.