[Pkg-exim4-users] mailname for outgoing mail

Marc Haber mh+pkg-exim4-users at zugschlus.de
Mon Jun 26 12:12:10 UTC 2006

On Sat, May 20, 2006 at 02:15:43PM -0700, Ross Boylan wrote:
> I have a system with FQDN of corn.betterworld.us.
> I want mail (also news posts and anything else heading to the internet
> at large) from there to appear to be from betterworld.us.
> I set /etc/mailname to betterworld.us.
> Is that OK?  I guess that's a 2 part question: will it work?  is it
> advisable?

It will work if your applications generate unqualified addreses.

I use configuration on application basis to have e-mail generated on
torres.zugschlus.de to appear from zugschlus.de

The discussion in #315128 might help. or not.

> The README.Debian discussion is a bit unclear to me:
>    Your ``mail name'' is the hostname portion of the address to be shown
>    outgoing news and mail messages (following the username and @ sign).
>    What you enter here will end up in /etc/mailname, which is a file that
>    might be used by other programs as well.
> (exim4-config 4.61-1).
> The "to be shown on outgoing" indicates betterworld.us is what I
> want.


> However, the documentation also refers to header rewriting
> (actually, the very next paragraph says you may be able to hide this
> name)--why would I want to hide it if it's the one I want to show?

Using both "hide local mail name in outgoing mail" in conjunction with
a mailname set by the user does not seem to make sense in all
situations. It is, however, possible that there are situations in
which this might be desireable, which is the reason why the debconf
scripts are not checking for this situation.

> I'm also unsure whether "hostname" in the previous discussion refers
> to "corn" (which is what the command hostname returns) or to my FQDN.

As a rule, exim only handles fully qualified host names. There might
be exceptions.

> Basically the same ambiguity occurs if I consult my current testing
> man page for mailname:
>   The file /etc/mailname is a plain ASCII configuration file, which on a
>   Debian system contains the visible mail name of the system.  It is
>   used by many different programs, usually programs that wish to send or
>   relay mail, and need to know the name of the system.
>   The file contains only one line describing the fully qualified
>   domain name that the program wishing to get the mail name should use
>   (that is, everything after the @).
> I want the visible name to be "betterworld.us", but the FQDN of the
> system is "corn.betterworld.us."

So you want "betterworld.us" in there, I think. What happens when you
do this?

> P.S.  "The domain in a mail address need not correspond to a
> hostname."  p. 24 of Hazel's Exim (3) book.  This suggests to me that
> the use of "hostname" in the discussion of mailname may not be
> entirely apt.


>I also have a dim recollection that in some contexts,
> in the edress user at a.b.com a is the "host" and "b.com" is the
> "domain."

>From a DNS point of view, a.b.com is a domain name as well. The
definitions of these things vary among authors.


Marc Haber         | "I don't trust Computers. They | Mailadresse im Header
Mannheim, Germany  |  lose things."    Winona Ryder | Fon: *49 621 72739834
Nordisch by Nature |  How to make an American Quilt | Fax: *49 621 72739835

More information about the Pkg-exim4-users mailing list