Next monthly maintenance May 3rd 7am-11am [Details]
STATUS PAGE Some systems are experiencing issues.

Search Docs by Keyword

scrontab

scrontab can be used to define a number of recurring batch jobs to run on the cluster at a scheduled interval.  Much like its namesake, crontab, the scrontab command maintains entries in a file that are executed at specified times or intervals.  Simply type scrontab from any cluster node and add your job entries in the editor window that appears, one per line.  Then save and exit the editor the same way you would exit vim[1].

Entries use the same format as cron.  For an explanation on crontab entry formats, see the wikipedia page for cron.

This example scrontab entry runs a jobscript in user jharvard’s home directory called runscript.sh at 23:45 (11:45 PM) every Saturday:

45 23 * * 6 /n/home01/jharvard/runscript.sh

Note: Your home directory may be located in a different location.  To find the directory you are in, type pwd at the command line.

For more information on scrontab, type man scrontab on any cluster node to see the scrontab manual page.

[1] For those who prefer a different editor, you can precede the scrontab command with the EDITOR variable.  For example, if you want to use nano, you could invoke scrontab like so:

EDITOR=nano scrontab

Was this article helpful?
0 out Of 5 Stars
5 Stars 0%
4 Stars 0%
3 Stars 0%
2 Stars 0%
1 Stars 0%
How can we improve this article?
Need help?
© The President and Fellows of Harvard College
Except where otherwise noted, this content is licensed under Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International license.