Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 13 May 2001 01:07:57 +1000
From:      "Doug Young" <dougy@brizzie.org>
To:        "G. Jason Middleton" <gmiddl1@gl.umbc.edu>, <freebsd-questions@FreeBSD.ORG>
Subject:   Re: how to email logs files
Message-ID:  <00ba01c0daf5$55512d80$0300a8c0@oracle>
References:  <Pine.LNX.4.31L.02.0105121020100.26113-100000@linux2.gl.umbc.edu>

next in thread | previous in thread | raw e-mail | index | archive | help
> what is the easiest to have a log file such as /var/log/maillog
emailed to
> a specific email address daily?  I know cron can do this but how
would i
> go about it in the crontab?  hows about a script file that emails
the log
> to me and have cron run the script daily.  Would this work?  What
kinda
> syntax would be necessary for this?
>
The following is an extract from my notes about how I email ppp.log
files


Crontab

 To get a daily email of ppp.log, insert the following line in
"/etc/crontab"

 30  1  *  *  * root cat /var/log/ppp.log | mail -s "nightly"
user@your_isp.com

 To get a weekly email etc etc

 30  *  1  *  *  root cat /var/


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?00ba01c0daf5$55512d80$0300a8c0>