Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a system that runs a lot of cronjobs. It seems that one of these crons is consuming excessive amounts of CPU and memory on occasion.

Is there an easy way to audit CPU and memory usage of cron jobs?

share|improve this question

Have you looked at sar/sadc?

share|improve this answer

No, not specifically, but that should not be necessary. Just use any of the common monitoring tools; most allow breaking down resource usage by process.

The simplest solution would be a script that regularly runs vmstat and top and appends results to a file (use top's "b" option). Or use a more sophisticated monitoring software, such as Nagios or ZenOSS (might be overkill for this problem, but they are generally useful). See e.g.

share|improve this answer

This is a good idea for a new tool : ) some cron wrapper that does accounting

share|improve this answer

Have you considered launching the commands manually to audit them?

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.