#1
  1. Me likey breadsticks...
    Devshed Beginner (1000 - 1499 posts)

    Join Date
    Jan 2003
    Location
    Los Angeles
    Posts
    1,189
    Rep Power
    18

    List All Cron Jobs?


    I'm more a programmer than a sys admin, but I've been having to do a little admin stuff lately and I was just wondering if there was a way as root to list all the cron jobs set for each user. I am trying to consolidate the cron jobs of all of my predecessors (and my own) into 1 account to make it easier to manage everything down the road.
    PostgreSQL, it's what's for dinner...
  2. #2
  3. Banned ;)
    Devshed Supreme Being (6500+ posts)

    Join Date
    Nov 2001
    Location
    Woodland Hills, Los Angeles County, California, USA
    Posts
    9,638
    Rep Power
    4247
    Go to /var/spool/cron and check the files there. Each file should correspond to the login accounts of each user.
  4. #3
  5. Me likey breadsticks...
    Devshed Beginner (1000 - 1499 posts)

    Join Date
    Jan 2003
    Location
    Los Angeles
    Posts
    1,189
    Rep Power
    18
    Thx for the info! Would that be the only place I need to check? Right now it seems there's only 1 file in there and it only has 1 line in it, but I know that there are more automated tasks being run every night (I get emailed the results from each run). Is there another place I would need to check? Thanks,

    -b
    PostgreSQL, it's what's for dinner...
  6. #4
  7. Banned ;)
    Devshed Supreme Being (6500+ posts)

    Join Date
    Nov 2001
    Location
    Woodland Hills, Los Angeles County, California, USA
    Posts
    9,638
    Rep Power
    4247
    The other place would be /etc/crontab.
  8. #5
  9. No Profile Picture
    Contributing User
    Devshed God 1st Plane (5500 - 5999 posts)

    Join Date
    Oct 2000
    Location
    Back in the real world.
    Posts
    5,966
    Rep Power
    190
    for SuSE eg. i know they have an entry in /etc/crontab that checks /etc/cron.daily/*, /etc/cron.monthly/* and so on. you need to check the scripts that are run by cron if they are calling other scripts too...
  10. #6
  11. No Profile Picture
    Huge Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    May 2002
    Posts
    141
    Rep Power
    13
    crontab -l <user>

    the superuser may specify a different username than their own. if you want to see the contents of /etc/cron* in one pretty printout, i think you'll have to write your own shell script.
  12. #7
  13. Me likey breadsticks...
    Devshed Beginner (1000 - 1499 posts)

    Join Date
    Jan 2003
    Location
    Los Angeles
    Posts
    1,189
    Rep Power
    18
    Thanks all! I think I found everything in /etc/crontab but I'll check out all the other suggested places as well to make sure.

    Thanks again.

    -b
    PostgreSQL, it's what's for dinner...

IMN logo majestic logo threadwatch logo seochat tools logo