Networker

Re: [Networker] savegroup completion notices separate success and fail?

2006-10-12 18:44:54
Subject: Re: [Networker] savegroup completion notices separate success and fail?
From: Tim Mooney <Tim.Mooney AT NDSU DOT EDU>
To: NETWORKER AT LISTSERV.TEMPLE DOT EDU
Date: Thu, 12 Oct 2006 17:39:45 -0500
In regard to: [Networker] savegroup completion notices separate success and...:

hello

Using 7.1 on Solaris.

Our savegroup completion notification is an email to admins.  We would
like to refine the way this works if possible.

The notification will report for example "Default completed, total 5 client(s), 0 Hostname(s) Unresolved, 0 Failed, 5 Succeeded."

If there is a failure for that group then the message will change to for eg "...2 Failed, 3 Succeeded."

I don't know what your mail environment is like, but if you're familiar
with using a filtering package like "procmail" or "forward", it should
be very easy to accomplish this *on the receiving end*.  It sounds like
you're looking at tackling this on the sending end, which is fine too.

If you go the procmail route, you could do something like

- set up either an account (like "backup" or "savegrp") on either your
  Solaris backup server or another Linux/UNIX server

  or

- set up an alias like "savegrp" on the backup server or some other
  server.

- send all of the savegroup email to that account or alias.

- have the account or alias set to use procmail, and

  - save a copy of all mail

  and

  - if the message has "Unresolved, 0 Failed" in the subject, send to
    addressA
  - if the message has "Unresolved, [^0] Failed" in the subject, send
    to addressB
  - if the message has "bootstrap" in it, send it to some off-site email
    address (like a personal gmail address for a couple of your admins,
    etc).

Tim
--
Tim Mooney                                           Tim.Mooney AT ndsu DOT edu
Information Technology Services                      (701) 231-1076 (Voice)
Room 242-J6, IACC Building                           (701) 231-8541 (Fax)
North Dakota State University, Fargo, ND 58105-5164

To sign off this list, send email to listserv AT listserv.temple DOT edu and type 
"signoff networker" in the
body of the email. Please write to networker-request AT listserv.temple DOT edu 
if you have any problems
wit this list. You can access the archives at 
http://listserv.temple.edu/archives/networker.html or
via RSS at http://listserv.temple.edu/cgi-bin/wa?RSS&L=NETWORKER