Architecting, installing and maintaining your SAS environment

Alert or notification for scheduled jobs

Reply
Frequent Contributor
Posts: 118

Alert or notification for scheduled jobs

Hi,

 

I'm working with scheduling jobs in SMC. I want to send a mail or receive an alert for the failed job and was wondering if there is such feutures for scheduled jobs(in SMC)? Or should I write a separate sas program for scheduled jobs to send a mail?

 

I read some information that there is such alert for SAS work directory and server log file.

Occasional Contributor
Posts: 9

Re: Alert or notification for scheduled jobs

On SMC you can scheduler you SAS Jobs, but you have no resource for controlling the jobs behavior.

 

You'll to use a SAS program to send e-mails depending the job's state

Occasional Contributor
Posts: 8

Re: Alert or notification for scheduled jobs

Hi Riana - 

 

Have you considered scheduling on the OS and integrating the organization's smtp server for notifications? You can do this easily on Linux OS by editing your contab entry (using the sas install account). 

 

su to SAS account:

~ sudo su -l sas

 

open in VI:

~ crontab -e

 

edit file:

SHELL=/bin/bash
PATH=/sbin:/bin:/usr/sbin:/usr/bin
MAILTO=sas
# For details see man 4 crontabs

# Example of job definition:
# .---------------- minute (0 - 59)
# | .------------- hour (0 - 23)
# | | .---------- day of month (1 - 31)
# | | | .------- month (1 - 12) OR jan,feb,mar,apr ...
# | | | | .---- day of week (0 - 6) (Sunday=0 or 7) OR sun,mon,tue,wed,thu,fri,sat
# | | | | |

 

 

Then create an alias in etc/aliases for the distro list:

sasadmins:  email1@address.com,email2@address.com, etc...

 

Then run newaliases to update the database.

 

Hope this helps

 

Super User
Posts: 3,304

Re: Alert or notification for scheduled jobs

What scheduling server are you using in SMC? If it is Platform Process Manager then you can set this up in the scheduled job properties.

Ask a Question
Discussion stats
  • 3 replies
  • 175 views
  • 0 likes
  • 4 in conversation