[CentOS] Sendmail problem

Tue Apr 11 18:05:04 UTC 2006
Alexander Dalloz <ad+lists at uni-x.org>

Am Di, den 11.04.2006 schrieb Thomas E Dukes um 19:34:

> Hello Alexander,
> 
> As far as I know, I have my FQDN set.  It may not be done so correctly in
> sendmail.

hostname

/usr/lib/sendmail -bt -d0.6 < /dev/null

> Here's a portion of my sendmail.mc file:
> 
> LOCAL_DOMAIN(`localhost.localdomain')dnl  <---- do I need to change this to
> my FDQN?

No. From /usr/share/doc/sendmail/README.cf:

+-----------------------------------+
| ACCEPTING MAIL FOR MULTIPLE NAMES |
+-----------------------------------+
                                                                                                                                                                                                                   
If your host is known by several different names, you need to augment
class {w}.  This is a list of names by which your host is known, and
anything sent to an address using a host name in this list will be
treated as local mail.  You can do this in two ways:  either create the
file /etc/mail/local-host-names containing a list of your aliases (one
per
line), and use ``FEATURE(`use_cw_file')'' in the .mc file, or add
``LOCAL_DOMAIN(`alias.host.name')''.  Be sure you use the
fully-qualified
name of the host, rather than a short name.
                                                                                                                                                                                                                   
If you want to have different address in different domains, take
a look at the virtusertable feature, which is also explained at
http://www.sendmail.org/virtual-hosting.html

> dnl #
> dnl # The following example makes mail from this host and any additional
> dnl # specified domains appear to be sent from mydomain.com
> dnl #
> dnl # masquerade not just the headers, but the envelope as well
> dnl #
> dnl FEATURE(masquerade_envelope)dnl
> dnl #
> dnl # masquerade not just @mydomainalias.com, but @*.mydomainalias.com as
> well
> dnl #
> dnl FEATURE(masquerade_entire_domain)dnl
> dnl #
> dnl MASQUERADE_DOMAIN(localhost)dnl
> dnl MASQUERADE_DOMAIN(localhost.localdomain)dnl  <------  How about this?
> dnl # MASQUERADE_DOMAIN(mydomainalias.com)dnl
> dnl # MASQUERADE_DOMAIN(mydomain.lan)dnl
> MAILER(smtp)dnl
> MAILER(`procmail')
> 
> What masquerade feature do I need to setup so that mail sent from domain1,
> domain2, domain3, etc., is sent from the respective domains?

If you have multiple domains to host you probably don't want to use the
masquerade feature as that causes Sendmail to always rewrite to just a
single domain name (MASQUERADE_AS).

From DSN report we see that it was your Apache to send the mail out.
Typically it is submitting, so you could use "sendmail -f
realuser at domain.tld" to change the sender. If you run PHP you should
have a close look at http://phpmailer.sourceforge.net/ instead of using
the mail() function.

Alexander


-- 
Alexander Dalloz | Enger, Germany | GPG http://pgp.mit.edu 0xB366A773
legal statement: http://www.uni-x.org/legal.html
Fedora Core 2 GNU/Linux on Athlon with kernel 2.6.11-1.35_FC2smp 
Serendipity 19:54:05 up 28 days, 20:41, load average: 1.10, 0.99, 0.70 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: Dies ist ein digital signierter Nachrichtenteil
URL: <http://lists.centos.org/pipermail/centos/attachments/20060411/919a755c/attachment-0005.sig>