Solved

Forward system messages to email address

Posted on 2004-04-26
5
542 Views
Last Modified: 2013-12-27
How do I forward system messages to my email address? I am using Solaris 8.
0
Comment
Question by:jackyleee
5 Comments
 
LVL 6

Expert Comment

by:danths
ID: 10924875
you should be able to do it with /etc/aliases
0
 
LVL 48

Expert Comment

by:Tintin
ID: 10924980
Depends on your definition of "system messages".  

Do you mean mail send to root?

Do you mean syslog messages?

If you just want root mail to be forwarded to you, edit /etc/aliases and add:


root:  your@email.address

Then type 'newaliases'
0
 
LVL 4

Expert Comment

by:Otetelisanu
ID: 10925314
Here are the steps how to change the send mail logs.

1. make a copy from your /etc/syslog.conf

2. edit /etc/syslog.conf and change the following line:
   mail.debug                      ifdef(`LOGHOST', /var/log/syslog, @loghost)
   mail.debug                      ifdef(`LOGHOST', /var/log/maillog, @loghost)

3. touch /var/log/maillog

4. stop syslogd with "/etc/init.d/syslog stop" command

5. start syslogd with "/etc/init.d/syslog start" command
 
send a mail and you should be able to see the log entries in /var/log/maillog file.

0
 

Author Comment

by:jackyleee
ID: 10925836
I mean syslog messages, only error messages. I want the system to log to /var/adm/messages & send an email to me as well.
0
 
LVL 20

Accepted Solution

by:
tfewster earned 125 total points
ID: 10942745
AFAIK, syslog can't send mail messages as one of its actions - But you could install swatch or other add-on security tools to monitor the syslog (and other logs) and mail you.

http://swatch.sourceforge.net/
0

Featured Post

What Should I Do With This Threat Intelligence?

Are you wondering if you actually need threat intelligence? The answer is yes. We explain the basics for creating useful threat intelligence.

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
forget admin password 8 23
prtdiag report hdd failure 10 123
Shell script errors 10 99
Compare if date string is within text file 3 55
Hello fellow BSD lovers, I've created a patch process for patching openjdk6 for BSD (FreeBSD specifically), although I tried to keep all BSD versions in mind when creating my patch. Welcome to OpenJDK6 on BSD First let me start with a little …
Attention: This article will no longer be maintained. If you have any questions, please feel free to mail me. jgh@FreeBSD.org Please see http://www.freebsd.org/doc/en_US.ISO8859-1/articles/freebsd-update-server/ for the updated article. It is avail…
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

24 Experts available now in Live!

Get 1:1 Help Now