Validators & Full-Nodes
Using Cosmovisor to stage dYdX Chain binary upgrade

Using Cosmovisor to stage dYdX Chain binary upgrade


  1. Linux (Ubuntu Server 22.04.3 recommended)
  2. 8-cpu (ARM or x86_64), 64 GB RAM, 500 GB SSD NVME Storage
  3. Already installed dYdXChain full node


  1. Install Go from (opens in a new tab) (Version tested is 1.22.1)
  2. Install Cosmovisor, with the following command:
  • go install
  1. Copy cosmovisor from $HOME/go/bin/ to a directory in your $PATH
  2. Add two environment variables to $HOME/.profile. The data directory is typically $HOME/.dydx-mainnet-1
  • export DAEMON_NAME=dydxprotocold
  • export DAEMON_HOME=<your data directory>
  1. Log out and log back in.
  2. Initialize Cosmovisor with the following command. The is the the full path to dydxprotocold
  • cosmovisor init <path to executable>
  1. Cosmovisor is now ready for use.

Running dydxprotocold under Cosmovisor

You have to change the way you currently run dydxprotocold to run under Cosmovisor. This is done simply by specifying “cosmovisor run” in place of the “dydxprotocold” command you used previously. Therefore, if you previously used “dydxprotocold start --p2p.seeds="ade4d8…”, you would change that to “cosmovisor run start --p2p.seeds="ade4d8…”

Staging upgrade

  1. The Cosmovisor directory structure looks like this:


  1. To stage an upgrade, you would create a directory inside the upgrades/ directory. For example, as of 4/1/2024, the current version is v3.0.0 and the next upgrade version is v4.0.0. Therefore you would create a directory called “v4.0.0” and then a bin directory inside it.


  1. Now, download the upgraded binary and put it inside the bin directory created previously. It must be named dydxprotocold

  2. Restart dydxprotocold with Cosmovisor. Now, Cosmovisor will automatically halt the current binary at the block activation height and start the upgrade binary.