Re: sendmail/mail/Mail



John Summerfield wrote:
tony.chamberlain@xxxxxxxxx wrote:
note: for the following I am using made up names for anonymity of the actual names.


We have a customer, Acme, running Cent Os 4.5 with our software on it. When we encounter a problem we want to send mail to notify people. I am not asking how to do this because
we already know how. The problem is mail.

The host name is myhost (I am making up names again remember). When I try to send mail from
it I eventually get returned mail, "the domain myhost.localdomain" does not exist (or something like
that). I realize I have to change the hostname to myhost.Acme.COM but I cant' change the hostname
via neat or in the files because it has other implications (mysql and some other software would be
affected).

I tried, without a high expectation, doing something like this:

HOSTNAME=myhost.Acme.COM
Mail tonychamberlain@xxxxxxxxx
<etc>

but the mail still came back because that just changed the HOSTNAME variable in my env, not actually the
host name. Is there some way I can actually change hostname just for my environment to get mail sent,
without having to change it for the whole system?



the mail command just calls sendmail, it has no means of setting from.
I think mutt can be coerced, but I've never tried.

If sendmail's idea of the host name is the same as you can see from the Internet, then there shouldn't be a problem: Ffor examile

fff.example.com resolves to your client's IP address
sendmail (or other MTA) thinks it's called fff.example.com
then all will be well.

In practice, it doesn't matter what the name is so long as it resolves, but it would be a bit rude to pinch IBM's.

In sendmail (and probably other MTA) you can also use address rewriting (masquerading). See DM in sendmail.cf

You probably don't want to touch sendmail.cf (or even try to read it...). Instead, be sure you have the sendmail-cf package installed, edit /etc/mail/sendmail.mc, and change
dnl MASQUERADE_AS(`mydomain.com')dnl
removing the leading dnl and replacing mydomain.com with something that is internet-legal. If your software runs as root when it sends mail, you'll also need to add a leading dnl to the line:
EXPOSED_USER(`root')dnl
to comment it out. Then restart sendmail.

--
Les Mikesell
lesmikesell@xxxxxxxxx



--
fedora-list mailing list
fedora-list@xxxxxxxxxx
To unsubscribe: https://www.redhat.com/mailman/listinfo/fedora-list



Relevant Pages

  • Re: mail confusion
    ... On Sun, 2005-10-30 at 12:06 -0500, Derek Martin wrote: ... > - change the hostname of your machine to something in a real domain ... This host has a dynamic IP. ... Evolution is configured to use sendmail on this ...
    (Fedora)
  • Sendmail Config. question
    ... is about a month behind on patch levels (sendmail patch up-to-date). ... a problem removing the hostname from the 'FROM:' header of any email sent from ... Since I don't have DNS resolving this host (internal host, ...
    (SunManagers)
  • Re: How I "turn-on" e-mail?
    ... port 25 is now open on my box. ... How do I relay e-mail to my host? ... > then sendmail would react to the generated files. ... dnl # 127.0.0.1 and not on any other network devices. ...
    (Fedora)
  • Re: sendmail/mail/Mail
    ... The host name is myhost. ... I realize I have to change the hostname to myhost.Acme.COM but I cant' change the hostname ... the mail command just calls sendmail, it has no means of setting from. ... In sendmail (and probably other MTA) you can also use address rewriting. ...
    (Fedora)
  • RE: sendmail domain name
    ... the hostname is being masqueraded as ... Assuming that your SMTP is sendmail, you need to masquerade your ... dnl # The following example makes mail from this host and any additional ...
    (RedHat)