Friday, October 1, 2010

list all cron jobs for all users

quite good post in StackOverflow: http://stackoverflow.com/questions/134906/how-do-i-list-all-cron-jobs-for-all-users



as root:

i modified the original post to show the user's username:

for user in $(cut -f1 -d: /etc/passwd); do echo "crontab for $user:";crontab -u $user -l;  done

dont forget to also:

cat /etc/crontab
 
 
original: 
for user in $(cut -f1 -d: /etc/passwd); do crontab -u $user -l; done

No comments:

Post a Comment

cancel script completely on ctrl-c

I found this question interesting: basically how to cancel completely a script and all child processes : You do this by creating a subro...