Visit Our UNIX and Linux User Community


How do I send a file as an attachment (gzip file) on a Unix system


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers How do I send a file as an attachment (gzip file) on a Unix system
# 1  
Old 07-03-2002
How do I send a file as an attachment (gzip file) on a Unix system

Hi,

How do I send a file as an attachment (gzip file) on a Unix system ? Using sendmail.

Please help me.

Smilie
# 2  
Old 07-03-2002
If you do a search on this site for mail AND attachment, you should get your answer. If that doesn't help, then post back with specific problems.

Please also read the FAQ's and the rules (#5). Thanks.
# 3  
Old 07-03-2002
I'm trying to send a mail from unix with a attach gzip file with the follow parameters:

Content-Type: application/x-gzip; name="xpto.txt.gz"
Content-Transfer-Encoding: x-gzip
Content-Disposition: inline;filename="xpto.txt.gz"
MIME-Version: 1.0

When I receive the mail in outlook and I try to decompress the file with winzip, give an error telling the file is corrupt.

What is wrong with these parameters ?

Best regards.
# 4  
Old 07-03-2002
It is probably a version problem between gzip and winzip.

I first sent a gzipped file to NT and tried to open it. I used gzip version 1.2.4 (very old Aug 93) and WinZip 7.0. WinZip didn't want to look at the file - gave me an option to use WinZip classic which did open the gzipped file.

I then used the commands found in the different questions answered in the past about mailing attachments. I mailed the gz file which showed up as an attachment in Outlook. I saved it to disk, opened up WinZip (used classic) and it worked fine.

Command used:
uuencode messages.0.gz newmess.txt |mailx -s"test" myself@mydomain.com
 

Previous Thread | Next Thread
Test Your Knowledge in Computers #18
Difficulty: Easy
Facebook purchased the popular video teleconferencing software 'Skype' from Microsoft.
True or False?

10 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

MIME type for sending gzip file as attachment in email

Hello, I am trying to send a gzip file on email using below command but the zipped file received on email is corrupt. mailsend -smtp $smtpip -content-type 'application/x-gzip' -mime-type "application/x-gzip" -t $receiver -f $sender -sub "$subject" -M "$MSG" -attach $file file name is ... (1 Reply)
Discussion started by: tushar.modgil
1 Replies

2. UNIX for Dummies Questions & Answers

Send email attachment using Operating System Script(UNIX) in Oracle Alerts

Good Day Kindly assist: I am creating an Alert that will notify supervisors of staff members who are due for probation report. I am using Operating System Script(Unix) as source.I have already developed the script. Now the challenge is if there are 3 employee records then the alert... (2 Replies)
Discussion started by: nosi27
2 Replies

3. Shell Programming and Scripting

Mailx command to send attachment file

Hi, I need to send a attachment which has space in the file name as: "ABC Data Extract.txt" which is present in the location /home/projects/txt i am using /home/projects/scripts mailx -s "Sub" email_id "/home/projects/txt/ABC Data Extract.txt" but i am not getting the attachment. (7 Replies)
Discussion started by: ATWC
7 Replies

4. Shell Programming and Scripting

want to send .csv file as an attachment using mailx command.

want to send .csv file as an attachment using mailx command. Please help!!! (1 Reply)
Discussion started by: gagandeep
1 Replies

5. Shell Programming and Scripting

Send a file through email using cron as an attachment

Hi All, I want to send a file as an attachment through cron job.Is this possible using cronjob nd if it i, can you please let me know how to do this? Thanks (2 Replies)
Discussion started by: NARESH1302
2 Replies

6. UNIX for Advanced & Expert Users

how to send file as attachment using mail or mailx

I have a need to send a file from the unix command line to be sent as an attachment. Is this possible? That is when I open my outlook email I need to file to appear as an attachment. Also, is there a way to use the mail binary (not mailx) to modify the "reply address". mailx -r works but I need... (1 Reply)
Discussion started by: kieranfoley
1 Replies

7. Shell Programming and Scripting

Reading Delimited file and send mail with attachment

Hi All, My requirement is: 1. To read a file that contains log file location and server name. The format of the file is something like this : server_name1:logfilename1 server_name2:logfilename2 2. Now I wants to grep "error" string from the logfilename and put it into another file for... (3 Replies)
Discussion started by: acheiver
3 Replies

8. UNIX for Advanced & Expert Users

how to send file as attachment with mail ?

hello , i m new to linux/unix , well in my college their is linux server to which we all (i and my frnds) login , we can send mail to each other through command "mail" . but any one can tell me how can i attached a binary file with mail. we are using red hat , "pine ", "mailx" , all... (2 Replies)
Discussion started by: alert_every1
2 Replies

9. Shell Programming and Scripting

HELP!!! how to send PDF file as an attachment using mailx

Hi, iam using the following command: uuencode file1.pdf file1.pdf|mailx - s "waz up?" xyz@domain.com Iam recieving an encoding error when i try to open the attachment. Pls help..very urgent!!! (1 Reply)
Discussion started by: Brat
1 Replies

10. UNIX for Dummies Questions & Answers

Send a *.pdf file as a attachment

Hi there, i am very new in the unix sector. (i work on HP UX, an Sun Solaris) i can write some simple scripts,..... but now i will wirte a script with "mail". i would like to send a pdf file to a mail recipient. But if i try it with "mail -s "email@adress" < "filename(with path)" it... (3 Replies)
Discussion started by: scotty
3 Replies

Featured Tech Videos