Yeah, there is a better that I believe will do what you want.
Change that to:
check device opt with path /opt
if space usage > 99% then unmonitor
And then add this to your mysql check:
depends on opt
That should do it. Because mysql now depends on opt, if opt becomes unmonitored, mysql should be stopped. You will have to manually tell monit to start watching the filesystem again when you have clean up things.
You might even be about to do this:
check device opt with path /opt
if space usage > 99% then stop else start
If I am correct, this will cause the depenent service to stop when file system is over 99% full and start it when the usage drops.