Cosmovisor is a process manager for Cosmos SDK applications, providing a mechanism for automatic node upgrades. It monitors the governance process for signals indicating that a software upgrade is required and automatically downloads and applies the necessary updates. This tool helps to facilitate smoother and more efficient network upgrades, thereby ensuring a high level of continuity and reliability of blockchain services.
Ensure add go bin /usr/local/go/bin and your GOPATH to PATH environment variable. You will also want to add below path into $HOME/.profile to persistent.
# add go binary
export PATH=$PATH:/usr/local/go/bin
# add go package binary
export PATH=$PATH:$(go env GOPATH)/bin
Verify your setup with command (ensure version is same as your titand)
cosmovisor run version --long
Update service file /etc/systemd/system/titand.service to use cosmovisor
Replace <cosmovisor_absoule_path> by output of command which cosmovisor.
Replace <home_directory> by your home directory that contain folder .titand . Or other directory if you chose your own folder for titan node.
By default, Cosmovisor will back up the current data before upgrading the chain process (this means your disk space should always have more than 40% free). If your node is configured to keep only a small amount of historical state, the backup process may be fast. However, if your node is a full node that stores a large amount of historical data, you may want to set UNSAFE_SKIP_BACKUP=true to help speed up the upgrade process and avoid consuming disk space.