What?

When a BOSH VM is healthy, it is listed with the status “running”. Let’s use Monit to trigger a state change.

How?

  1. Run watch bosh vms. (If you don’t have watch installed, run brew install watch)
  2. In another buffer or tab, bosh ssh into one of your Diego cells
  3. Run sudo -i to run as root
  4. Run monit summary (need root access to do this)
  5. Run monit stop all
  6. Observe the state of the bosh VM in question.
  7. Run monit start all

Expected Result

The Diego job for the cell you SSHed to should be listed as failing as soon as you stop the Monit jobs. When you run monit start all it should return to the running state.

Resources

Docs: BOSH CLI health commands Docs: BOSH Job Lifecycle Docs: Monit