Normally one of my
systemd services will take about 0...5% cpu Usage. In some cases it can reach up to 100% but only for some seconds. If the Service "crashes" it takes up to 100% continuously.
So I want to supervise the service and restart the service, when it has more than 90% cpu usage over a time of 60sec. How can I do this?
I'm looking for something similar to
prlimit --cpu. But as I understand it will limit the total cpu time.