Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

From the man pages it appears both do basically the same thing, why have both running on the system at the same time? From the wording in the man pages it looks like cron will repeatedly run programs at scheduled times while atd may run them only once, is this why?

share|improve this question

1 Answer 1

The look like they are the same but there are some things at is a lot better at. Some differences:

cron

  • can be scheduled for repeated jobs (minute,hour,month,dayofmonth,dayofweek);
  • can be edited;
  • you set these in crontab or /etc/crontab

at

  • starts one time. To repeat it you need to start it again;
  • cannot be edited, after it started;
  • you can start this from commandline.
  • the most important ability of at command is the ability to operate in relative time terms.

Have a look at these examples and imagine how you'd do these with cron:

at 2pm + 1 week
at 2pm next week
at 0815am Jan 24
at 8 :15amjan24
at now "+ 1day"
at 5 pm FRIday
at '17 utc+30minutes'
share|improve this answer

Your Answer

 
discard

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.