Operating System - HP-UX
1752815 Members
6199 Online
108789 Solutions
New Discussion

download message in mailx in bulk

 
moneric
Occasional Contributor

download message in mailx in bulk

Greeting.

We are on HP-UX centstdb B.11.31 U ia64 3294693583 unlimited-user license

We monitor our system using some customed scripts and run it as cron-jobs

The cronjob will send the job status message as root.

We will then logon to our server and check those messages.

Is there a way we can bulk download the messages

What we have in mind, is to bulk download, and then set up a search script for error

and then send a daily report to us instead of us have to logon to the server and check manually for any failed cronjobs.

Thanks for all the help.

 

1 REPLY 1
Steven Schweda
Honored Contributor

Re: download message in mailx in bulk

> What we have in mind, is to bulk download, and then set up a search
> script for error [...]

   What I have in mind is not to store these e-mail messages or
bulk-download them, but to deliver them directly to a program (or
script) for analysis.

   I haven't done anything with e-mail on a UNIX system for many years,
so I know nothing, but it might make some sense to have these e-mail
messages sent to a program (or script) instead of to a real user.  That
is, create an e-mail alias with a "|" character.  For example:

      cronuser: "|/usr/local/bin/cronscan.sh"

   This way, the program can scan each message for signs of failure, and
do something useful if it finds any.  (It could even send an e-mail
message to a real user.)

   As usual, many things are possible.  A fancy system might even send a
daily summary message, just to prove that it's still alive.  (One daily
guaranteed-to-fail cron job could be scheduled, for example.)

   For more details, you might try a Web search for keywords like, say:

      hp-ux e-mail alias pipeline

There should be many examples out there somewhere.  (Probably more if
you omit "hp-ux".)