[SunHELP] syslog send a mail
Cloud L. Lee
siyeclover at online.ie
Wed Jan 26 12:36:28 CST 2005
I have some application run on a v880, I seldom login in the v880.
So I wish the syslog can send error messages to me by mail when some
My email client always runs.
I try to use
tail -f /var/adm/messages |grep "error" |mail root
but it doesn't work.
It can't send a new mail to root when new error occur.
>Logwatch is configurable, but I don't know how short you can make the
>I think you are headed toward disaster. Just for kicks do this..
>tail -f /var/log/somelog|Grep "string" and watch the fun begin. Make it
>worse by using egrep -v and adding multiple match strings.
>You are going to topple your mail reader with a flood of crap. A ton of
>stuff is written to the logfiles. With a 24 hour interval with logwatch
>at least its all delivered in one email - sorted and in a digest style.
>Unless the system in question is bored (not doing much) you are looking
>at too much information to have every "match" entry mailed. And if you
>want to see *everything* in syslog you might actually overrun your
>mailserver and mail reader.
>If your goal is to just see whats going on, do it "live" with tail -f.
Cloud L. Lee
More information about the SunHELP