[plug] SendMail

Anthony J. Breeds-Taurima tony at cantech.net.au
Fri Oct 5 10:35:23 WST 2001


On Fri, 5 Oct 2001, Andrew  Barbara wrote:

> We have several Linux servers that send mail to us, the cron deamon particulary always says that its from "root at localhost"  What's the best way to make it say the proper address ie "root at real_domain.com"?

RedHat6.0+ (with all .rpm updates)

Add:
MASQUERADE_AS(real_domain.com)
MASQUERADE_DOMAIN(real_domain.com)
FEATURE(`masquerade_envelope')
dnl EXPOSED_USER(`root')dnl

to your /etc/mail/sendmail.mc file
Then convert the m4 to a .cf with
m4 /etc/mail/sendmail.mc > /etc/sendmail.cf

(This assumes you have the sendmail-cf package installed)

Then reatart sendmail : service sendmail restart

debian (sid but should also work on woody, not sure about potato)
Add:
MASQUERADE_AS(real_domain.com)
MASQUERADE_DOMAIN(real_domain.com)
FEATURE(`masquerade_envelope')
dnl EXPOSED_USER(`root')dnl

to your /etc/mail/sendmail.mc
Then convert the m4 to a .cf with
sendmailconfig
Answer yess to all the questions
This will also restart sendmail.

HTH

Yours Tony.

/*
 * "The significant problems we face cannot be solved at the
 * same level of thinking we were at when we created them."
 * --Albert Einstein
 */




More information about the plug mailing list