sending mail from a script

Hi

I want to send a mail (to my id like abc@xyz.com) from a shell script running on HP Ux.
Would like to include text from a file or include the file as attachment, either ways.

Thanks
Sidhu

cat yourfile.log | mail -s "This is a subject" abc@xyz.com

Take a look at the mailx command. I use it to send logfiles to my workstation from the servers every day.

Search the forums.

mailx and mutt work great...lots-o-info in archives.

can anyone give a example for this commands. say i have a file called mail_body.txt i want to send a subject stating "service is up" and the content should be taken from mail_body.txt to a recipient named krish.v@gmail.com

Please give an example with the above scenario..because i tried with the above scenario but am not getting it properly. please help.

mailx -s "server is up" abc@site.com <mail_body.txt