[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: automate maildelivery



proftpd in message automate maildelivery (Wed, 10/31 14:31):

> Hi,
> 
> I would like to have my linuxbox sending me the /var/log/messages file on a
> regular bases.
> 
> Creating the syslog correct is not the problem, neither to run cron.
> But how do i produce the mail including the attachment?
> 
> Many thanks
> 
> markus

I'm no expert, but you should be able to do it as root:

crontab -e

(add this line:)

* 0 * * * mail -s "your messages file" your@email.addr < /var/log/messages

# this should email your entire /var/log/messages to your@email.addr 
# every night at midnight.

-David Rose



Reply to: