Upgrade your Desmos full node
These instructions are for full nodes that are running on previous versions of Desmos and need to update to the latest version of the Desmos software.
Manual upgrade
The following instructions explain how to manually upgrade the node:
Stop your node:
bash sudo systemctl stop desmosd
Backup your validator files:
cp ~/.desmos/config/priv_validator_key.json ~/priv_validator_key.json
cp ~/.desmos/config/node_key.json ~/node_key.json
cp ~/.desmos/data/priv_validator_state.json ~/priv_validator_state.jsonGo into the directory in which you have installed
desmos
. If you have followed the installation instructions and didn't change the path, it should be~/desmos
:```bash
cd <installation-path>
# e.g.
# cd ~/desmos
```Now, update the
desmos
software:git fetch --tags
git checkout tags/$(git describe --tags `git rev-list --tags --max-count=1`)
make build && make install
The above commands checks out the latest release that has been tagged on our repository. If you wish to check out a specific version instead, use the following commands:
- List all the tags
git tags --list
- Checkout the tag you want
git checkout tags/<tag>
# Example: git checkout tags/v4.1.0
If you have issues at this step, please check that you have the latest stable version of Go installed.
Cosmovisor
If your node is using cosmovisor, and you've followed the above procedure to manually upgrade, don't forget to move the upgraded binary inside the cosmovisor folder by typing the following command:
cp build/desmos ~/.desmos/cosmovisor/current/bin/desmos
Then check if the version of cosmovisor matches with the latest desmos version by running:
cosmovisor version
Automatic upgrade (with Cosmovisor)
Here below it is explained how to prepare your node to be able to automatically upgrade itself.
1.Cosmovisor handles the automatic upgrades that happens after the upgrade governance proposal passes. If during an upgrade your node doesn't have enough space left or if the cosmovisor backup it is taking too much time, you can do the following:
- Open your
desmosd
editor:sudo systemctl edit desmosd --full
- Add the following line after the last
Environment
line:Environment="UNSAFE_SKIP_BACKUP=true"