Regarding mailing of logs

Hi Folks,

I have an application which logs get continuously refreshed and made after every 1 second , I want that those logs get mailed to me at my email id sara@somewhere.com

The location is

cd /var/log/abc/log

Please advise the command so that I can mail abc.log at my mailid inbox sara@somewhere.com

use mailx

mailx -s "my logs" -a abc.log  sara@somewhere.com < emailbody

OR

( cat emailbody ; uuencode abc.log abc.log  ) | mailx -s "my logs" sara@somewhere.com 
1 Like

or:

cat /var/log/abc/log | mail -s "logs from server" sara@somewhere.com