how to prevent multiple email notifications from monitoring script


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting how to prevent multiple email notifications from monitoring script
Prev   Next
# 1  
Old 06-07-2007
how to prevent multiple email notifications from monitoring script

Hi everyone,

I am in the process of trying to decide the correct way to solve a particular scripting/email issue I have and would appreciate any advice.

We have a cronjob running every 10 mins to check disk size on the server and if this exceeds a certain percentage then it will email a notification warning out to relevant people.

However once the first email has been sent I would like it to refrain from sending a fresh email every 10 mins until the disk size have been resolved - maybe then just send a reminder every hour or two.

The only way I can think of (with my limited scripting knowledge) would be to create a separate file which would be used as a 'checking' file to see when the last email was sent. So if the checking file indicates that an email was sent in the last hour then no emails will be sent etc.

Hope this makes sense as did not want to write a long expanse of details. Also this is to run on Solaris 9.

Any suggestions gratefully received.

Thanks

Si
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

Email notifications when new directory is created.

Hi Team, Can you please help me on this, I want to receive an email notification whenever new directory is created under the path /home/data. Am using bash shell. We are not sure about the directory name. When ever any new directory is created, scrip should monitor for new directory and... (1 Reply)
Discussion started by: Dhivyaprabha
1 Replies

2. HP-UX

Email notifications of PAX backups

I have just switched my production server from using the br_backup script that uses fbackup to the fs_backup script that uses PAX. Things seem to work fine and test restores are successful, but I'm not getting a daily e-mail with the backup results that I used to get from the br_backup script. ... (2 Replies)
Discussion started by: jduehmig
2 Replies

3. Shell Programming and Scripting

Email Notifications on Cron Bash Error Only cp mv rsync

Wondering if anyone can point me to an example of how to setup a bash script that executes cp mv and rsync commands and only sends an email if there were errors with any of those commands and what the errors are. In addition it should email if the cron event to execute the script fails, or in... (1 Reply)
Discussion started by: consultant
1 Replies

4. What is on Your Mind?

Script to alert with email after a job got successful in monitoring tool

Hi guyz, Please send me a script which is to be sending an automatic email to particular mail id's when a job get complete with status successful. Please send me your script to my mail id : rehan.csjmu@gmail.com Thanks in Advance. ---------- Post updated at 11:33 AM ----------... (1 Reply)
Discussion started by: Rehan Ahmad
1 Replies

5. Windows & DOS: Issues & Discussions

Fail2ban: email notifications and banning ssh IP logins

Hi all. I am using Cygwin in Windows 7 and am trying to setup fail2ban so that I can ban foreign IP addresses under SSH, also getting email notifications. I downloaded fail2ban and installed it. I then created jail.local copy from jail.conf and changed some values in jail.local. Now when I try to... (2 Replies)
Discussion started by: synthesis
2 Replies

6. Shell Programming and Scripting

Prevent wrong user from using shell script for multiple remote servers

Hi, I am running a shell script from a central server to multiple remote servers using the following code: application_check() { # Linux/UNIX box with ssh key based login SERVERS=`cat /tmp/server-details` # SSH User name USR="user" # create new file > /tmp/abc.log # connect... (2 Replies)
Discussion started by: mystition
2 Replies

7. Solaris

OPS Center Email Notifications

Hi, Does any one know how to configure email notifications (to exchange) in Oracle Enterprise Manager 11g OPS Center? I have gone through the documentation and have done everything it asked, but still no notifications via email. I get the following error: At the OS level i tried sending email... (20 Replies)
Discussion started by: Mack1982
20 Replies

8. AIX

Crontab - Email notifications by alternate user

Hi, I have a crontab which sents email to a group in a certain interval. The email contains my user id in 'from' field of email - because my user crontab. I don't have root access for that AIX 5.3 host - and should have to change 'from' field to either 'root' or any other common names. ... (4 Replies)
Discussion started by: vasukv
4 Replies

9. Post Here to Contact Site Administrators and Moderators

Servers, email notifications

Hi. On 09-05-2007 Neo posted that new servers were on their way. 1) It would be nice to hear of occasional progress. As far as I can tell, there has not been much of a change. The notice that is posted every now and then talks about a new server "this week". (In fact as I was previewing... (1 Reply)
Discussion started by: drl
1 Replies

10. Post Here to Contact Site Administrators and Moderators

trying to turn email notifications off

I'm trying to disable the email notifications; despite going into my control panel and selecting NO next to Use 'Email Notification' by default? I keep getting email notifications anyway! And I know I've never selected the checkbox next to Email Notification: emails sent to you whenever someone... (2 Replies)
Discussion started by: oombera
2 Replies
Login or Register to Ask a Question
htnotify(1)						      General Commands Manual						       htnotify(1)

NAME
htnotify - sends email notifications about out-dated web pages discovered by htmerge SYNOPSIS
htnotify [options] DESCRIPTION
Htnotify scans the document database created by htmerge and sends an email message for every page that is out of date. Please have a look at the ht://Dig notification manual for instructions on how to set up this service. OPTIONS
-b database Specifies an alternative database than what is specified in the configuration file. -c configfile Use the specified configfile instead of the default. -v Verbose mode. This increases the verbosity of the program. Used once will display a log of what email messages were sent. Used more than once will display information about each document that has email notification set. FILES
/etc/htdig/htdig.conf The default configuration file. SEE ALSO
Please refer to the HTML pages (in the htdig-doc package) /usr/share/doc/htdig-doc/html/index.html and the manual pages htdig(1) and htmerge(1) for a detailed description of ht://Dig and its commands. AUTHOR
This manual page was written by Christian Schwarz, modified by Stijn de Bekker, based on the HTML documentation of ht://Dig. 21 July 1997 htnotify(1)