[hobbit] Monitoring Backups

Joshua Johnson joshua at stenhouseconsulting.com
Wed Feb 27 06:48:08 CET 2008


Phil,

I think we have a misunderstanding? We have many remote sites, each with a server running Retrospect to perform backups. BBWin is not running on the servers at these remote sites. Retrospect simply sends emails when the backups complete. Retrospect does have the ability to call a script when a backup completes but, that would require installing BBWin on all the remote servers and creating/configuring the Retrospect script, etc. To avoid doing that we want to trigger hobbit alerts based on the emails we are already receiving from Retrospect on the remote servers.

Josh

From: Phil Wild [mailto:philwild at gmail.com]
Sent: Tuesday, February 26, 2008 10:25 PM
To: hobbit at hswn.dk
Subject: Re: [hobbit] Monitoring Backups

Sorry, I wasn't clear... I was talking about the server.

Can the server run a script att he completion of every backup job?

Cheers

Phil


On 27/02/2008, Joshua Johnson <joshua at stenhouseconsulting.com<mailto:joshua at stenhouseconsulting.com>> wrote:

Phil,



We are using Retrospect and yes it does provide the functionality you are talking about however, we don't want to install the BBWin client on all of these systems. That is why we are going the email route, it doesn't require any changes to the clients.



Josh



From: Phil Wild [mailto:philwild at gmail.com<mailto:philwild at gmail.com>]
Sent: Tuesday, February 26, 2008 7:16 PM

To: hobbit at hswn.dk<mailto:hobbit at hswn.dk>
Subject: Re: [hobbit] Monitoring Backups



Can I ask what backup software you are using?



Rather than processing the email, you may be able to get into the source of the email. If on backup completion you can run a script and you have access to the backup status and error message as variables, you would probably be better off writing a script here that calls bb to send a message up.



Phil



On 27/02/2008, Joshua Johnson <joshua at stenhouseconsulting.com<mailto:joshua at stenhouseconsulting.com>> wrote:

Ralph,

See I knew there was a reason I sent that message. Your 2 cents is way better than what I had!! Why didn't I think of this? It is so much simpler. To make it easier I will have the Exchange server just forward to Sendmail so I don't have to change the current setup and then we still get the backup notification emails. Thank you!

Joshua Johnson
Consultant



-----Original Message-----
From: Ralph Mitchell [mailto:ralphmitchell at gmail.com<mailto:ralphmitchell at gmail.com>]
Sent: Tuesday, February 26, 2008 5:27 PM
To: hobbit at hswn.dk<mailto:hobbit at hswn.dk>
Subject: Re: [hobbit] Monitoring Backups

On Tue, Feb 26, 2008 at 3:45 PM, Joshua Johnson
<joshua at stenhouseconsulting.com<mailto:joshua at stenhouseconsulting.com>> wrote:
>
>
> 2)      Have the Exchange server script send files (ftp or SMB) to the
> Hobbit server. These files will then be processed by a server side script
> which could use bbhostgrep to check the files and send the alerts into
> Hobbit.

My $0.02 - is there a compelling reason not to just send email to your
Hobbit server??  I've  done it that way when it wasn't possible to
deliver reports via hobbit/bb protocol over port 1984.

The way it works is, my (old, decrepit, Redhat 7.2) Hobbit server is
running sendmail.  In /etc/aliases I have:

    msgman:   "| /usr/local/sbin/msgman"

which allows me to send email to msgman at hobbit.myserver.com<mailto:msgman at hobbit.myserver.com>.  Any
incoming email for that address is piped through the msgman script,
which could be written in bash, perl, C, python, &c.  What comes
through the pipe via stdin is a bunch of headers, including From, To,
Date & Subject, then a blank line, then the body of the message.
Here's one way to break out the message into useful bits:

    #!/bin/ksh

    # First line is "From sender date"
    read junk sender date

    while read token string
    do
       # Detect a blank line
      if [ "X$token$string" == "X" ]; then
        break;
      fi

      # extract the Subject line
      if [ "X$token" == "XSubject:" ]; then
        subject=$string
      fi
    done

    # pick up first line in body
    read text

    while read line
    do
      # pick up any other body lines
      text="$text\n$line"
    done

    # Do "stuff" to discover the system name, the test name, the
color and some message
    # ...

    LINE="status $SYSTEM.$TEST $COLOR `date`
    $MESSAGE"

    /home/hobbit/server/bin/bb 0.0.0.0<http://0.0.0.0/> "$LINE"

I don't think you'd need to load the hobbit environment (I've got this
running in an old BB hierarchy) just to deliver the report.

It's not exactly rocket science, but I then I already had email
working and didn't want to have to maintain ftp/scp/smb across the
company network.  I imagine there's a way for Postfix (and other
MTA's) to deliver to a pipe, but maybe not - I simply haven't tried
because it ain't broke...  :)

Ralph Mitchell

To unsubscribe from the hobbit list, send an e-mail to
hobbit-unsubscribe at hswn.dk<mailto:hobbit-unsubscribe at hswn.dk>



This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the system manager. This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail.

To unsubscribe from the hobbit list, send an e-mail to
hobbit-unsubscribe at hswn.dk<mailto:hobbit-unsubscribe at hswn.dk>



--
Tel: 0400 466 952
Fax: 0433 123 226
email: philwild at gmail.com<mailto:philwild at gmail.com>

________________________________
This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the system manager. This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail.



--
Tel: 0400 466 952
Fax: 0433 123 226
email: philwild at gmail.com<mailto:philwild at gmail.com>

________________________________
This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please notify the system manager. This message contains confidential information and is intended only for the individual named. If you are not the named addressee you should not disseminate, distribute or copy this e-mail.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.xymon.com/pipermail/xymon/attachments/20080227/5bc5ef4c/attachment.html>


More information about the Xymon mailing list