• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 551
  • Last Modified:

Forward system messages to email address

How do I forward system messages to my email address? I am using Solaris 8.
0
jackyleee
Asked:
jackyleee
1 Solution
 
danthsCommented:
you should be able to do it with /etc/aliases
0
 
TintinCommented:
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
 
OtetelisanuCommented:
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
 
jackyleeeAuthor Commented:
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
 
tfewsterCommented:
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

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Tackle projects and never again get stuck behind a technical roadblock.
Join Now