Comment on How to auto-reboot if CPU load too high?

BestBouclettes@jlai.lu ⁨2⁩ ⁨months⁩ ago

Just so you know, the load avg is not actually the CPU. It’s an index of a bunch of metrics crammed together (network load, disk I/o, CPU avg, etc.). A good rule of thumb is to have your load avg value under the number of cores your CPU has. If your load avg is twice the number of your CPU cores it means that your machine is overloaded by 100%.

To answer your question, you can probably run a script that fetches your 5 min load avg and triggers a reboot if it’s higher than a certain value. You can run it on a regular basis with a systemd timer or a cron job.

source
Sort:hotnewtop