Cosmovisor is a new process manager for cosmos blockchains. It can make low-downtime upgrades smoother, as validators don't have to manually upgrade binaries during the upgrade, and instead can pre-install new binaries, and Cosmovisor will automatically update them based on on-chain SoftwareUpgrade proposals.
After making the proper configurations to your new node, launch it using sudo systemctl start cosmovisor. You should now see blocks executing in the logs (journalctl -fu cosmovisor).
Migrate A Running v1.2 Node
# Make the necessary directory structure for v1.2
mkdir -p ~/.secretd/cosmovisor/genesis/bin
# Disable the old secret-node systemd service
sudo systemctl stop secret-node
sudo systemctl disable secret-node
# Move v1.2 binaries to Cosmovisor's directory
sudo mv /usr/local/bin/secretd /usr/lib/{libgo_cosmwasm.so,librust_cosmwasm_enclave.signed.so} ~/.secretd/cosmovisor/genesis/bin
# For a query node also move the query enclave
sudo mv /usr/lib/librust_cosmwasm_query_enclave.signed.so ~/.secretd/cosmovisor/genesis/bin
# Launch the Cosmovisor service
sudo systemctl start cosmovisor
Now the Cosmovisor directory structure should look like this:
To relaunch your node, use sudo systemctl start cosmovisor. You should now see blocks executing in the logs (journalctl -fu cosmovisor).
Prepare A v1.3 Node Upgrade (Shockwave Alpha)
The "Shockwave Alpha" upgrade is anticipated to be on Wednesday April 27th, 2022 at 2:00PM UTC. Below are instructions to prepare Cosmovisor for automatically upgrading your node to v1.3.
# Make the necessary directory structure for v1.3
mkdir -p ~/.secretd/cosmovisor/upgrades/v1.3/bin
# Get & verify v1.3 binaries
# Uncomment goleveldb or rocksdb:
# wget -P /tmp/ "https://github.com/scrtlabs/SecretNetwork/releases/download/v1.3.0/secretnetwork_1.3.0_mainnet_goleveldb_amd64.deb"
# echo "b5a4387fd3af477f1d7d0c8ab13debc9b9ad9abccb59c82b1a35cc8a90db902b /tmp/secretnetwork_1.3.0_mainnet_goleveldb_amd64.deb" | sha256sum --check
# or rocksdb
#wget -P /tmp/ "https://github.com/scrtlabs/SecretNetwork/releases/download/v1.3.0/secretnetwork_1.3.0_mainnet_rocksdb_amd64.deb"
#echo "a1fc48003b3b563aae216901fc5821bb11164746c61b86507bc813cb49bd85cb /tmp/secretnetwork_1.3.0_mainnet_rocksdb_amd64.deb" | sha256sum --check
# Extract v1.3 from archive
dpkg-deb -R /tmp/secretnetwork_1.3.0_mainnet_*_amd64.deb /tmp/secretnetwork_1.3.0_mainnet_amd64.deb.extracted
# Move v1.3 binaries to Cosmovisor's directory
mv /tmp/secretnetwork_1.3.0_mainnet_amd64.deb.extracted/usr/{local/bin/secretd,lib/librust_cosmwasm_enclave.signed.so,librust_cosmwasm_query_enclave.signed.so,lib/libgo_cosmwasm.so} ~/.secretd/cosmovisor/upgrades/v1.3/bin
Now the Cosmovisor directory structure should look like this: