# Live Upgrade Tutorial
This document demonstrates how a live upgrade can be performed on-chain through a governance process.
Start the network and trigger upgrade
Performing an upgrade
Assuming the proposal passes the chain will stop at given upgrade height.
You can stop and start the original binary all you want, but it will refuse to run after the upgrade height.
We need a new binary with the upgrade handler installed. The logs should look something like:
Note that the process will hang indefinitely (doesn't exit to avoid restart loops). So, you must manually kill the process and replace it with a new binary. Do so now with
upgrade.Keeperis initialized and set in the app, set the corresponding upgrade
Handlerwith the correct
Note that we panic on any error - this would cause the upgrade to fail if the migration could not be run, and no node would advance - allowing a manual recovery. If we ignored the errors, then we would proceed with an incomplete upgrade and have a very difficult time every recovering the proper state.
Now, compile the new binary and run the upgraded code to complete the upgrade: