Results 1 to 6 of 6

Thread: Where is crontab stored?

  1. #1
    Join Date
    Jul 2009
    Beans
    16
    Distro
    Ubuntu 9.10 Karmic Koala

    Where is crontab stored?

    Hi all

    Just had to replace by boot disk which is on a USB stick. Fortunately I had a backup that isn't too far out of date. I have recently created some root cron tasks by running crontab -e.

    I can still read the corrubt usb stick - but where do I fund the cron entries?

  2. #2
    Join Date
    Apr 2009
    Location
    Midwest, U.S.A.
    Beans
    1,209
    Distro
    Ubuntu 10.04 Lucid Lynx

    Re: Where is crontab stored?

    They should be in the directories:
    • /etc/cron.d/
    • /etc/cron.daily/
    • /etc/cron.hourly/
    • /etc/cron.monthly/
    • /etc/cron.weekly/
    Laptop: Dell Inspiron 8200 - Fedora 13 - Goddard
    Desktop: Self-Built - [Ku, Lu, Xu, U]buntu - Lucid 10.04.3 (LTS)
    Linux User: 498249 / Ubuntu User: 29241

  3. #3
    Join Date
    Nov 2007
    Location
    Wisconsin
    Beans
    1,139

    Re: Where is crontab stored?

    Root-level crontab should be in /etc/crontab.
    Root-level anacron and periodics should be in /etc/cron*

    User-level crontabs should be in /var/spool/cron/crontabs
    Note that even though they are user level, sudo access is required to view them there. Users should view(copy) their crontab using 'crontab -l'. Also, copying a fresh crontab into /var/spool/cron/crontabs is a very bad idea. Users should use 'crontab -e' and paste their old crontab contents in.

    For users, the 'crontab' command does a couple handy things: It checks syntax, and it also tells cron to reload the crontab once written. So the whole system is set up to really force users to use the command instead of copying and pasting and wondering why things broke.

  4. #4
    Join Date
    Jul 2009
    Beans
    16
    Distro
    Ubuntu 9.10 Karmic Koala

    Re: Where is crontab stored?

    Ta - that's what I was after. Quite happy to use crontab -e to set it up. I just want to make sure I haven't missed anything that is in there, and have all the correct params.

    Will check it out tonight.

  5. #5
    Join Date
    Dec 2010
    Location
    France, Paris
    Beans
    47
    Distro
    Ubuntu 12.04 Precise Pangolin

    Re: Where is crontab stored?

    Quote Originally Posted by seangee View Post
    Ta - that's what I was after. Quite happy to use crontab -e to set it up. I just want to make sure I haven't missed anything that is in there, and have all the correct params.

    Will check it out tonight.
    Just make sure u use 'export DISPLAY=:0' if u want to start a gui application.
    Meet me at the pier at midnight. We will stare out at the ocean one last time..

  6. #6
    Join Date
    Jul 2009
    Beans
    16
    Distro
    Ubuntu 9.10 Karmic Koala

    Re: Where is crontab stored?

    All sorted

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •