Sometimes I'm experiencing that an AWS instance is using 100% of the CPU resources - because of a conflict between the hardware and software virtualization. More exact it is the process called "System interrupts" which consumes all CPU resources. This is simply solved by stopping the instance, wait a while and then start the instance again (hereby it will startup on other hardware - just a restart would not work).
My question is now: What is the easiest way to stop the AWS instance and after 1 min start the instance up again automatically when the system is none-responsive? Can this somehow be done within AWS ecosystem itself?
The not so easy way would be to get another system to ping the server and if it doesn't respond - then I could execute a custom script with the needed actions. But I'm hoping an easier solution exists?