- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- How to send a file as attachment from Unix to Outl...
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-16-2005 09:31 AM
тАО09-16-2005 09:31 AM
Hi,
How to send a file as an attachment from Unix to Outlook.
I use the command mailx , but it is not comming as an attachement, rather the whole file is comming as body of the mail.
How to send a file as attachment from Unix to Outlook. Please help for this.
Thanks
Ezhil
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-16-2005 09:36 AM
тАО09-16-2005 09:36 AM
Re: How to send a file as attachment from Unix to Outlook ?
(echo "Subject: Whatever you want" ; uuencode /dir/filename /dir/filename) | /usr/sbin/sendmail someone@somewhere.com
Note the the /dir/filename in the uuencode part of the command is the exact same /dir/filename twice. That is intentional.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-16-2005 09:53 AM
тАО09-16-2005 09:53 AM
SolutionSince good old Windows insists on lf/cr line terminators instead of newlines, I strip the carriage-returns out of the file and then send it like this:
# ux2dos /etc/hosts > /tmp/hosts.txt
# uuencode /tmp/hosts.txt /tmp/hosts.txt | mailx -m -s "Here it is!" whoever@whereever.com
Regards!
...JRF...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-16-2005 10:29 AM
тАО09-16-2005 10:29 AM
Re: How to send a file as attachment from Unix to Outlook ?
Attached is a host of options using mailx.
Best of luck.
Regards,
dl
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-16-2005 10:38 AM
тАО09-16-2005 10:38 AM
Re: How to send a file as attachment from Unix to Outlook ?
To send an attachment from unix to your Outlook mail id do as following:
File Name= file1.txt
# uuencode file1.txt file1.txt | mailx -s "Directly sending from unix host" yourmailid@domain.com
Enjoy,
Cheers,
Raj.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-16-2005 12:17 PM
тАО09-16-2005 12:17 PM
Re: How to send a file as attachment from Unix to Outlook ?
# tar cvf
# uuencode
regards!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-16-2005 03:56 PM
тАО09-16-2005 03:56 PM
Re: How to send a file as attachment from Unix to Outlook ?
refer to this KB:
http://www1.itrc.hp.com/service/cki/docDisplay.do?docLocale=en_US&docId=200000079993924
regards.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-16-2005 04:04 PM
тАО09-16-2005 04:04 PM
Re: How to send a file as attachment from Unix to Outlook ?
i use:
/usr/bin/uuencode $youfile "TryThis.lis"|mailx -m -s "`hostname`- Try This ok - `date`" $emailadd
where
$emailadd is your email address
$yourfile is the file you want to send
hope this helps too!
regards
yogeeraj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-16-2005 05:33 PM
тАО09-16-2005 05:33 PM
Re: How to send a file as attachment from Unix to Outlook ?
uuencode myfile myfile | mailx -m -s "Attached file name=myfile" user@domain.com
was working for me up until few weeks ago. When I tried it last wednesday night to send a depot file to myself at my gmail.com address, all I got was the uuencoded text. As if it did not take the -m (suppress mime headers) switch.
Does anyone have any idea what might have changed ?
UNIX because I majored in cryptology...
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-18-2005 05:56 PM
тАО09-18-2005 05:56 PM
Re: How to send a file as attachment from Unix to Outlook ?
I am using the email client mutt for this
http://hpux.connect.org.uk/hppd/hpux/Networking/Mail/mutt-1.5.9/
This is a script to send mail with mutt
DESTIN=your.email@company.com
SUBJECT="mail from unix server"
ATTACH1="/etc/passwd"
ATTACH2="/etc/hosts"
TEXTFILE=/etc/inittab
/usr/local/bin/mutt -a "$ATTACH1" -a "$ATTACH2" -i "$TEXFILE" -s
"$SUBJECT" $DESTIN << EOF >/dev/null 2>&1
EOF
You don't need to work with uuencode and uudecode
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-18-2005 06:02 PM
тАО09-18-2005 06:02 PM
Re: How to send a file as attachment from Unix to Outlook ?
We use pine as our mail client and its very good in its own features and security. It is avaialable from http://h20293.www2.hp.com/portal/swdepot/displayProductInfo.do?productNumber=HPUXIEXP1111
and FAQ for attachments,
http://www.washington.edu/pine/faq/attachments.html#top
-Arun
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-19-2005 02:38 AM
тАО09-19-2005 02:38 AM
Re: How to send a file as attachment from Unix to Outlook ?
Also see:
http://home.clara.net/dwotton/unix/mail_files.htm
Fred
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО09-19-2005 05:37 AM
тАО09-19-2005 05:37 AM
Re: How to send a file as attachment from Unix to Outlook ?
works like a charm:
echo "this is the attachment" > attachment.file
echo "this is the body" > body.file
/usr/local/bin/mutt -a attachment.file -b blindcopy@hotmail.com -s "this is the subject" email@address.com < body.file
If you do not have a body message/text, substitute with "/dev/null"
try it, you'll like it.
http://hpux.connect.org.uk/hppd/hpux/Networking/Mail/mutt-1.5.9/