-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathtask_schedule.cfg
77 lines (67 loc) · 3.57 KB
/
task_schedule.cfg
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
# Configuration file for task_schedule.pl to run ARC jobs
subject ARC3 tasks # subject of email
timeout 300 # Default tool timeout
heartbeat_timeout 300 # Maximum age of heartbeat file (seconds)
print_error 1 # Print out all errors to email message
# Data files and directories. The *_dir vars can have $ENV{} vars which
# get interpolated. (Note lack of task name after TST_DATA because this is just for test).
data_dir $ENV{SKA_DATA}/arc3 # Data file directory
log_dir $ENV{SKA_DATA}/arc3/Logs # Log file directory
bin_dir $ENV{SKA_BIN} # Bin dir (optional, see task def'n)
master_log arc_master.log # Composite master log (created in log_dir)
# Email addresses that receive an alert if there was a severe error in
# running jobs (i.e. couldn't start jobs or couldn't open log file).
# Processing errors *within* the jobs are caught with watch_cron_logs
alert [email protected]
# Define task parameters
# cron: Job repetition specification ala crontab
# exec: Name of executable. Can have $ENV{} vars which get interpolated.
# If bin_dir is defined then bin_dir is prepended to non-absolute exec names.
# log: Name of log. Can have $ENV{} vars which get interpolated.
# If log is set to '' then no log file will be created
# If log is not defined it is set to <task_name>.log.
# If log_dir is defined then log_dir is prepended to non-absolute log names.
# timeout: Maximum time (seconds) for job before timing out
# This has multiple jobs which get run in specified order
# Note the syntax 'exec <number> : cmd', which means that the given command is
# executed only once for each <number> of times the task is executed. In the
# example below, the commands are done once each 1, 2, and 4 minutes, respectively.
<task arc>
cron * * * * *
check_cron 00 06 * * *
exec 10 : $ENV{SKA_SHARE}/arc3/get_iFOT_events.pl
exec 5 : $ENV{SKA_SHARE}/arc3/get_web_content.pl
exec 5 : $ENV{SKA_SHARE}/arc3/get_goes_x.py --h5=$ENV{SKA_DATA}/arc3/GOES_X.h5
exec 5 : $ENV{SKA_SHARE}/arc3/plot_goes_x.py --h5=$ENV{SKA_DATA}/arc3/GOES_X.h5 --out=$ENV{SKA}/www/ASPECT/arc3/goes_x.png
exec 5 : $ENV{SKA_SHARE}/arc3/get_ace.py --h5=$ENV{SKA_DATA}/arc3/ACE.h5
exec 5 : $ENV{SKA_SHARE}/arc3/get_hrc.py --h5=$ENV{SKA_DATA}/arc3/hrc_shield.h5 --data-dir=$ENV{SKA_DATA}/arc3
exec 5 : $ENV{SKA_SHARE}/arc3/plot_hrc.py --h5=$ENV{SKA_DATA}/arc3/hrc_shield.h5 --out=$ENV{SKA}/www/ASPECT/arc3/hrc_shield.png
exec 5 : $ENV{SKA_SHARE}/arc3/make_timeline.py --data-dir=$ENV{SKA_DATA}/arc3
exec 2 : $ENV{SKA_SHARE}/arc3/arc.pl
exec 2 : $ENV{SKA_SHARE}/arc3/arc.pl -config arc3:arc_ops
exec 10 : $ENV{SKA_SHARE}/arc3/arc_time_machine.pl
context 1
<check>
<error>
# File Expression
# ---------- ---------------------------
arc.log uninitialized value
arc.log (?<!Program caused arithmetic )error
#
# Look for warnings, but not from web problems that looks like
# Warning: 403 ...
arc.log warning(?!:\s+\d+\s)
arc.log fatal
arc.log undefined value
arc.log failed
</error>
</check>
</task>
# Remove disable_alerts file if there to enable alerts. If there
# is a recurring error in task processing them an email will go out
# once a day.
<task enable_alerts>
cron 30 09 * * *
exec /bin/rm -f $ENV{SKA_DATA}/arc3/task_sched_disable_alerts
context 1
</task>