Sponsored Content
Top Forums UNIX for Advanced & Expert Users Notify Me when job fail using cron Post 302197623 by unSpawn on Wednesday 21st of May 2008 09:41:09 AM
Old 05-21-2008
If the job fails does it get logged somewhere? If so, wouldn't it be easier to run a logwatcher, add a condition and trigger it to send an e-mail?
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

cron fail to run

Hi, Does anyone know why the cron job fail to run automatically ? We have the problem with some Solaris 2.5.1 Machine ! The cron seemd to fail to submit the jobs defined at the defined time !! Why ? Sometime it runs OK,but sometime it fail . We are very sure the problem is due to... (6 Replies)
Discussion started by: kerwin_hsu
6 Replies

2. UNIX for Dummies Questions & Answers

CRON usage for CRON job

can anybody explain the usage of CRON for adding a cron job. please provide an example also for better understanding !!! Thanks (1 Reply)
Discussion started by: skyineyes
1 Replies

3. Solaris

cron job starts new cron proccess

I run cron in solaris 10 zone. One cron job which syncing files to nfs mounted on container, creates after finishing another cron proccess(/usr/sbin/cron), and after 100 existing cron proccesses next cron job will not start. It's too weird for me, I'm not able to solve this problem. Theoretically... (3 Replies)
Discussion started by: ron76
3 Replies

4. AIX

Help with cron job

Hi guys and gals, I have this script that run perfectly when executed manually. If I place it in a cron to run on a schedule, it fails. Error is: exec(): 0509-036 Cannot load program /usr/local/bin/getlogical because of the following errors: 0509-150 Dependent module... (7 Replies)
Discussion started by: bbbngowc
7 Replies

5. Shell Programming and Scripting

notify-send does not notify real time

Hi, I am having a little trouble getting notify-send to work the way I would like it to. I am using ubuntu - karmic koala 2.6.31-19-generic #56-Ubuntu SMP So here's the problem run the following commands one after the other. notify-send -i info -t 100000 -- "Hi" "world" & notify-send -i... (3 Replies)
Discussion started by: linuxpenguin
3 Replies

6. UNIX for Advanced & Expert Users

cron job

Hello, Can anyone help me how to set any script as cron job. I have gone through all threads but not able to get the details. Appreciate your help. I need to set test.pl to run on every Tuesday by 6am in the morning. I do not the cron file which is defined. Please help me out. ... (3 Replies)
Discussion started by: jam_prasanna
3 Replies

7. Solaris

Cron job running even after cron is removed

Hi , I have removed a cron for particular user , but cron job seems to be running even after the cron entry is removed. The purpose of the cron was to sendmail to user ( it uses mailx utility ) I have restarted cron and sendmail service still user is getting mail alerts from the cron job. And... (4 Replies)
Discussion started by: chidori
4 Replies

8. Shell Programming and Scripting

Commented cron job -- cron monitoring

Hi I have a requirement to write a shell script,that will check the all commented job in cron job.Please help !! (2 Replies)
Discussion started by: netdbaind
2 Replies

9. Shell Programming and Scripting

Cron job - Need to run Cron every quarter at particular time

Hi, 1) If some job supposed to run on 1st of every month at 7 AM In cron job when we have a blackout on the 1st ( i.e when 1st falls on a sunday ) how can we make the job run the next business day? 2) How can we run a job on 25th of every quarter 7 AM(jan,apr,jul,oct) And if 25th... (5 Replies)
Discussion started by: System Admin 77
5 Replies

10. UNIX for Beginners Questions & Answers

Cron using shh keys fail

Hi All, Hoping someone can help with something I'm sure is an easy fix. I'm trying to setup a cron to ssh to a server and check if a process is running. I've got keys setup from the jumpbox which I'm originating the check from (I don't have root privileges), when running the check manually from... (3 Replies)
Discussion started by: mutley2202
3 Replies
faxrunq(1)						       mgetty+sendfax manual							faxrunq(1)

NAME
faxrunq - send fax jobs queued by faxspool(1) SYNOPSIS
faxrunq DESCRIPTION
Run the fax queue set up by faxspool(1), try to send all faxes, record result, remove job and send notify mails. faxrunq looks for all the jobs queued by faxspool(1) to /var/spool/fax/outgoing/*. For each job in the queue, faxrunq tries to send it, using sendfax(8). If the send succeeds, the job is removed from the queue, and a "success" mail is sent to the originator of the spooled job. If the send fails, it's logged, and faxrunq proceeds to the next job. If the job fails five times "fatally", that is, not with a locked or engaged line, but with "NO CARRIER" (no fax machine, or line noise), the job is suspended, and the requestor gets a mail, telling him so. faxrunq can be run from the command line (but make sure the user doing this has write access to the modem device and to the fax queue, that is, usually this should be done by "uucp" or "root"). In a production environment, it's more useful to start faxrunq from cron(8) in regu- lar intervals, like "run it every 5 minutes". See the cron(8) and/or crontab(1) man pages for this (which man page exists depends on your system). OPTIONS
-q Tells faxrunq to be quiet, that is, suppress all status messages. Error messages will still be printed. FILES
/var/spool/fax/outgoing/stop if this file exists, faxrunq (and faxrunqd) will do nothing. You can use this to stop queue processing while testing something, or if you know that the modem(s) are unavailable and do not want to run into oany error messages, etc. /var/spool/fax/outgoing/faxqueue_done Every time faxrunq (or faxrunqd) run the fax queue, a time stamp is written into that file. It is used by faxspool to display a warning if the queue hasn't been run recently (so faxes may get stuck). CONFIGURATION FILE
Some aspects of the behaviour of faxrunq can be controlled by a configuration file, /etc/mgetty/faxrunq.config. In this file, you can use the following options: success-send-mail [y/n] A boolean parameter that controls whether a mail will be sent after successful completition of the fax job. failure-send-mail [y/n] A boolean parameter that controls whether a mail will be sent after the fax job has failed more than the maximum number of times. success-call-program <name> Here, you can specify a program that will be run when the fax has been successfully sent. It will be passed two command line parame- ters. The first is the full path to the fax JOB file (see faxq(5)), the second is the last exit code from sendfax (for success-call- program, this is always "0"). failure-call-program <name> Similar to the "success-call-program", this program will be run when the fax has been failed too often and faxrunq gives up. This script could, for example, print out the fax on a printer so that it can be sent manually on a paper fax machine. maxfail-costly <n> This specifies the number of times that a fax may fail "fatally", that is, causing telephone costs (explained above). The default value is 5. maxfail-total <m> This is the absolute maximum number of times that faxrunq will try to send any given fax. The default value is 10. (Right now, it's not yet implemented). delete-sent-jobs [y/n] Determines whether faxrunq should delete jobs after sending, or leave them in the fax queue (while moving the "JOB" file to "JOB.done") so that they can be seen at by "faxq -o". The default value is "do not delete sent faxes". acct-log <path> Specifies where faxrunq should protocol success and failure of each try to send a fax job. The default location is /var/spool/fax/outgoing/acct.log. There are some other options that are allowed, but ignored. These are: max-modems, and faxrunqd-log. They are used by faxrunqd(8) (which reads the same config file, but has more options). BUGS
faxrunq doesn't handle proper time scheduling yet Don't use faxrunq if you have malevolent users with access to the fax spool. It doesn't handle all cases of file movement tricks cor- rectly. Use faxrunqd(8) instead, which does it correctly (this point is mostly moot if the fax queue is set up correctly - that is, owned by 'uucp', mode 755, and faxrunq(1) is also run as user 'uucp'). SEE ALSO
faxspool(1), sendfax(8), faxq(1), faxqueue(5), faxrunqd(8) AUTHOR
faxrunq is Copyright (C) 1993-2002 by Gert Doering, <gert@greenie.muc.de>. greenie 23 Nov 02 faxrunq(1)
All times are GMT -4. The time now is 06:01 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy