- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Changing the "From" address when emailing non-text...
Operating System - HP-UX
1823124
Members
3220
Online
109646
Solutions
Forums
Categories
Company
Local Language
юдл
back
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
юдл
back
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
Blogs
Information
Community
Resources
Community Language
Language
Forums
Blogs
Go to solution
Topic Options
- 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
тАО01-09-2002 05:24 PM
тАО01-09-2002 05:24 PM
I've read through the numerous threads on sendmail, mailx, mpack and elm but haven't found a suitable answer yet.
Our developers have been using uuencode and sendmail with the -f flag to send attachments and also specify a different "From" address for the email.
When they tried sending these attachments to Exchange mail servers this didn't work. I suggested using elm as this is MIME compatible, which works for the attachments but doesn't seem to allow you to change the "From" address at command line. You can specify a "From" address in the elmheaders file but all these users share the same .elm home directory and there can be multiple email instances with various "From" addresses running at the same time.
You can also specify a "From" address in elm interactive mode but these emails are generated by programs so it needs to be a command line option.
I've also tried mailx and mpack. Again non-text MIME attachments work with these but I can't find how to change the "From" addresses.
Any suggestions as to:
either
1) how can I email non-text MIME attachments from sendmail so that I can used with the -f flag to change the "From" address,
or
2) how can I change the "From" address on the command line for mailx, elm or mpack?
or
3) other alternatives
TIA
Stuart.
Our developers have been using uuencode and sendmail with the -f flag to send attachments and also specify a different "From" address for the email.
When they tried sending these attachments to Exchange mail servers this didn't work. I suggested using elm as this is MIME compatible, which works for the attachments but doesn't seem to allow you to change the "From" address at command line. You can specify a "From" address in the elmheaders file but all these users share the same .elm home directory and there can be multiple email instances with various "From" addresses running at the same time.
You can also specify a "From" address in elm interactive mode but these emails are generated by programs so it needs to be a command line option.
I've also tried mailx and mpack. Again non-text MIME attachments work with these but I can't find how to change the "From" addresses.
Any suggestions as to:
either
1) how can I email non-text MIME attachments from sendmail so that I can used with the -f flag to change the "From" address,
or
2) how can I change the "From" address on the command line for mailx, elm or mpack?
or
3) other alternatives
TIA
Stuart.
Solved! Go to Solution.
3 REPLIES 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-09-2002 06:18 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-09-2002 06:25 PM
тАО01-09-2002 06:25 PM
Re: Changing the "From" address when emailing non-text MIME attachments from command line.
Hi,
To send an email from a specific From: address ($SENDER_ADDRESS) of a MIME type (in this example, I use text/html to send html-embedded emails), you can make use of SMTP commands over an SMTP connection.
$MAIL_SERVER, $SENDER_ADDRESS, $RECEIPIENT_ADDRESSES, $EMAIL_TEXT are variables you should substitute accordingly.
Here is a template example:
# telnet $MAIL_SERVER 25
mail from: $SENDER_ADDRESS
Sender ok
rcpt to: $RECEIPIENT_ADDRESSES
Recipient ok
data
From: $SENDER_ADDRESS
To: $RECEIPIENT_ADDRESSES
Subject: XXX YYY ZZZ
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit
MIME-Version: 1.0
$EMAIL_TEXT
.
Hope this helps. Regards.
Steven Sim Kok Leong
Brainbench MVP for Unix Admin
http://www.brainbench.com
To send an email from a specific From: address ($SENDER_ADDRESS) of a MIME type (in this example, I use text/html to send html-embedded emails), you can make use of SMTP commands over an SMTP connection.
$MAIL_SERVER, $SENDER_ADDRESS, $RECEIPIENT_ADDRESSES, $EMAIL_TEXT are variables you should substitute accordingly.
Here is a template example:
# telnet $MAIL_SERVER 25
mail from: $SENDER_ADDRESS
Sender ok
rcpt to: $RECEIPIENT_ADDRESSES
Recipient ok
data
From: $SENDER_ADDRESS
To: $RECEIPIENT_ADDRESSES
Subject: XXX YYY ZZZ
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit
MIME-Version: 1.0
$EMAIL_TEXT
.
Hope this helps. Regards.
Steven Sim Kok Leong
Brainbench MVP for Unix Admin
http://www.brainbench.com
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-10-2002 08:38 AM
тАО01-10-2002 08:38 AM
Re: Changing the "From" address when emailing non-text MIME attachments from command line.
Hi,
this is a way that worked for me:
( echo Subject: Hello
echo From: nobody@nowhere
echo This is a nice Mail with attachment !
uuencode /tmp/hosts /tmp/hosts ) | sendmail volker.borowski@whereever.com
Forums ref and special thanks to Robin Wakefield
http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x62f2c6af36b7d5118ff10090279cd0f9,00.html
Volker
this is a way that worked for me:
( echo Subject: Hello
echo From: nobody@nowhere
echo This is a nice Mail with attachment !
uuencode /tmp/hosts /tmp/hosts ) | sendmail volker.borowski@whereever.com
Forums ref and special thanks to Robin Wakefield
http://forums.itrc.hp.com/cm/QuestionAnswer/1,,0x62f2c6af36b7d5118ff10090279cd0f9,00.html
Volker
The opinions expressed above are the personal opinions of the authors, not of Hewlett Packard Enterprise. By using this site, you accept the Terms of Use and Rules of Participation.
Company
Learn About
News and Events
Support
© Copyright 2025 Hewlett Packard Enterprise Development LP