Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 12-14-2012, 12:13 PM   #1
LQ Newbie
Registered: Dec 2012
Location: Bangalore
Posts: 1

Rep: Reputation: Disabled
I m new to Linux ,need help to send mail with attachment via mail command Rhel 5.3

I m new to Linux ,need help to send a mail with attachment via mail command linux,Version is RHEL 4 & 5.3.
Old 12-14-2012, 12:56 PM   #2
Senior Member
Registered: Jul 2012
Location: Grenoble, Fr.
Distribution: Sun Solaris, RHEL, Ubuntu, Debian 6.0
Posts: 1,800
Blog Entries: 4

Rep: Reputation: 286Reputation: 286Reputation: 286
Are there any mail services running on your system? It should be running in order to send an email. Meanwhile, if it's running then you can send attachment as follow:
uuencode /path/to/file/ /path/to/file/ | mailx -s "<subject>" <recipient_mail_id>
For instance, if you want to send a file named /home/jack/sample.txt as an attachment to, use:
uuencode /home/jack/sample.txt /home/jack/sample.txt | mailx -s "Sample Test"

Last edited by shivaa; 12-14-2012 at 12:59 PM.


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Send attachment with mail from command line shivaa Linux - Newbie 8 12-07-2012 11:42 AM
can mail command be used to send mail onto global mail servers like yahoo etc dale_chip Linux - Newbie 4 08-12-2008 08:33 AM
Cannot send mail with mail() command in PHP 4.3.4, Apache 2.0.48, Mandrake Linux 10 arcanum Linux - General 3 06-27-2004 06:06 PM
mail -a would not work to send e-mail attachment saavik Linux - Networking 3 12-18-2003 09:33 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 07:57 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration