• Post Reply Bookmark Topic Watch Topic
  • New Topic

Not able to send mail with attachement from AIX unix shell script  RSS feed

 
Madhu kommi
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Please help me to solve the issue regarding the sending a mail with attachement from unix.

I tried the following command it send mail but without attachement

uuencode <here rootpath>/file.txt file.txt | mailx -r test1@development.com -s " Test Mail" test2@development.com < abc.txt

We tried the command 'Mutt' also but no use.

mutt -s "Subject of Mail" -a file.csv test2@development.com

Plese help us to solve this issue we are struggling from past two days.

Thanks


 
fred rosenberger
lowercase baba
Bartender
Posts: 12563
49
Chrome Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This seems to work for me:

uuencode original_file attachment_name | mail -s "subject in here" email@address.here
 
Madhu kommi
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Following worked for me.


mailx -r abc@tech.com -s "TEST MAIL" def@tech.com <<MAIL_ATT
`cat body.txt`
`uuencode file.zip < file.zip `
MAIL_ATT

Thanks

For your references.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!