Networking Forums

Networking Forums > Computer Networking > Linux Networking > Simple "mail" thinks I'm at localhost.localdomain

Reply
Thread Tools Display Modes

Simple "mail" thinks I'm at localhost.localdomain

 
 
Ed Skinner
Guest
Posts: n/a

 
      09-02-2004, 05:39 PM
Using simple "mail" in a script, it says I am
"(E-Mail Removed)" (and the relaying system is rejecting the
message) even though all other facets of the networking software appear to
be properly configured. I wrote a couple of quickies and verified that
gethostname(2) and so forth are all returning the configured values, not
"localhost.localdomain".
One final clue: I can use "nail" (not "mail") with a "-r
(E-Mail Removed)" (using the correct values) and get the relay system to
accept and forward the message.
Anyone know where "mail" gets the host's name and domain? ("nail"
will do the same if I omit the "-r (E-Mail Removed)" option.)
Thanks!
 
Reply With Quote
 
 
 
 
ynotssor
Guest
Posts: n/a

 
      09-02-2004, 08:30 PM
"Ed Skinner" <(E-Mail Removed)> wrote in message
news(E-Mail Removed) t5.net

> Using simple "mail" in a script, it says I am
> "(E-Mail Removed)" (and the relaying system is rejecting
> the message) even though all other facets of the networking software
> appear to be properly configured. I wrote a couple of quickies and
> verified that gethostname(2) and so forth are all returning the
> configured values, not "localhost.localdomain".
> One final clue: I can use "nail" (not "mail") with a "-r
> (E-Mail Removed)" (using the correct values) and get the relay system to
> accept and forward the message.
> Anyone know where "mail" gets the host's name and domain? ("nail"
> will do the same if I omit the "-r (E-Mail Removed)" option.)


You need to configure sendmail properly. In your sendmail.mc file, somewhere
_above_ the MAILER() definitions:

MASQUERADE_AS(`host.com')dnl
FEATURE(`masquerade_envelope')dnl
FEATURE(`allmasquerade')dnl

Rebuild the sendmail.cf file and restart sendmail. Please see
http://www.sendmail.org/m4/masquerading.html for further information, as
well as reading the cf/README in your distribution.


tony

--
use hotmail for email replies

 
Reply With Quote
 
Michael Heiming
Guest
Posts: n/a

 
      09-02-2004, 08:45 PM
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
NotDashEscaped: You need GnuPG to verify this message

In comp.os.linux.networking Ed Skinner <(E-Mail Removed)> suggested:
> Using simple "mail" in a script, it says I am
> "(E-Mail Removed)" (and the relaying system is rejecting the
> message) even though all other facets of the networking software appear to
> be properly configured. I wrote a couple of quickies and verified that
> gethostname(2) and so forth are all returning the configured values, not
> "localhost.localdomain".
> One final clue: I can use "nail" (not "mail") with a "-r
> (E-Mail Removed)" (using the correct values) and get the relay system to
> accept and forward the message.
> Anyone know where "mail" gets the host's name and domain? ("nail"
> will do the same if I omit the "-r (E-Mail Removed)" option.)


Mail doesn't know anything about it, sounds like your MTA for any
further help, you need to tell us which one you run or even
better repost with full information to the proper ng
comp.mail.sendmail, if you are running sendmail.

--
Michael Heiming (GPG-Key ID: 0xEDD27B94)
mail: echo (E-Mail Removed) | perl -pe 'y/a-z/n-za-m/'
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)

iD8DBQFBN4ZsAkPEju3Se5QRAlp5AKCqjZDnxI18O+deEKBzJZ 0IM0Z+oQCg1aP2
SgxJLKgInHJMIb05vEUjvUs=
=e7mA
-----END PGP SIGNATURE-----
 
Reply With Quote
 
Ed Skinner
Guest
Posts: n/a

 
      09-02-2004, 11:43 PM
On Thu, 02 Sep 2004 13:30:48 -0700, ynotssor wrote:

> "Ed Skinner" <(E-Mail Removed)> wrote in message
> news(E-Mail Removed) t5.net
>
>> Using simple "mail" in a script, it says I am
>> "(E-Mail Removed)" (and the relaying system is rejecting the
>> message) even though all other facets of the networking software appear
>> to be properly configured. I wrote a couple of quickies and verified
>> that gethostname(2) and so forth are all returning the configured
>> values, not "localhost.localdomain".
>> One final clue: I can use "nail" (not "mail") with a "-r
>> (E-Mail Removed)" (using the correct values) and get the relay system to
>> accept and forward the message.
>> Anyone know where "mail" gets the host's name and domain? ("nail"
>> will do the same if I omit the "-r (E-Mail Removed)" option.)

>
> You need to configure sendmail properly. In your sendmail.mc file,
> somewhere _above_ the MAILER() definitions:
>
> MASQUERADE_AS(`host.com')dnl
> FEATURE(`masquerade_envelope')dnl
> FEATURE(`allmasquerade')dnl
>
> Rebuild the sendmail.cf file and restart sendmail. Please see
> http://www.sendmail.org/m4/masquerading.html for further information, as
> well as reading the cf/README in your distribution.
>
>
> tony


Thanks Tony, that did it. I was not aware that "mail" is *supposed* to say
the message is coming from "(E-Mail Removed)" and that the
MTA (such as sendmail) is going to be doing the rewriting (as a
masqueraded host) so my "blame" of "mail" for the problem was wrong. Lucky
for me you understood my problem and gave the correct solution.
Thanks again for your right-on answer!

 
Reply With Quote
 
 
 
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Firefox 3 thinks Iam "offline" -- nothing could be further from the truth Ignoramus25581 Linux Networking 2 03-13-2008 06:44 PM
Simple mail "server" program needed - advice needed please Andrew Sayers Home Networking 12 08-24-2006 04:03 PM
Re: SPEWS SLIMES "WindsorFox", "Kevin-!:?)", "Spin Dryer" get the cold shoulder at broadband ng! SneakyP Broadband 0 11-29-2005 10:46 PM
Attention Plus.net Re: SPEWS DOLTS "WindsorFox", "Kevin-!:?)", "SpinDryer" SPAM broadband newsgroup !:?) Broadband 0 11-28-2005 04:28 AM
Attention Plus.Net Re: SPEWS DOLTS "WindsorFox", "Kevin-!:?)", "SpinDryer" SPAM braodband newsgroup !:?) Broadband 0 11-28-2005 03:03 AM



1 2 3 4 5 6 7 8 9 10 11