Share your knowledge at the LQ Wiki.
Go Back > Forums > Non-*NIX Forums > Programming
User Name
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.


  Search this Thread
Old 09-11-2004, 05:33 PM   #1
Registered: Sep 2003
Distribution: RedHat9
Posts: 114

Rep: Reputation: 15
One More ? Regarding at

ive looked through man and the net. can the at command be used to schedule a job more then once? or is it a one time only? what if i want to schedule a job to run every hour for the next 24 hours? i couldnt see how to use at for this, but at seems like it should be the way to go.
Old 09-11-2004, 05:38 PM   #2
Senior Member
Registered: Dec 2002
Location: England
Distribution: Used to use Mandrake/Mandriva
Posts: 2,794

Rep: Reputation: 116Reputation: 116
Have you checked cron?
Old 09-11-2004, 05:38 PM   #3
Senior Member
Registered: Jul 2004
Distribution: Slackware
Posts: 2,140

Rep: Reputation: 243Reputation: 243Reputation: 243
A little knowledge of vi may help...

crontab -e
<press a to go to edit mode>
0 * * * * /path/to/your/program
<type [ESC],[:wq]>

Then your program will run every hour

man 5 crontab for more infos
Old 09-11-2004, 11:35 PM   #4
Registered: Sep 2003
Distribution: RedHat9
Posts: 114

Original Poster
Rep: Reputation: 15
cron will be what i use next, but im trying to understand all that the at command can do.
Old 09-12-2004, 04:36 AM   #5
Registered: Feb 2004
Location: Outside Paris
Distribution: Solaris 11.3, Oracle Linux, Mint, Tribblix
Posts: 9,746

Rep: Reputation: 456Reputation: 456Reputation: 456Reputation: 456Reputation: 456
As proud and cedrik already suggested, cron is better suited for repetitive tasks.

If you anyway insist using at, nothing forbids to reschedule the next execution from within you at job.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 07:00 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration