[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Google
  Web www.spinics.net

Summary: Sendmail relay problem



Dear linuxmanagers,

Thank you Mr Bishop for your answer.

I must tell A.mydomain.com to treat mails to B.mydomain.com as local by 
adding B.mydomain.com in /etc/mail/sendmail.cw ( in 8.8.7 ).

So I did this.

 1. Added B.mydomain.com in /etc/mail/sendmail.cw of machine A.
 2. Restarted sendmail.

regards

Sudheesh

---------------------
Hi Sudheesh,

Do this:

	grep ^Fw /etc/sendmail.cf

That should tel us where your local-host-names file is, if you're using 
that:
> [root@flotsam root]# grep ^Fw /etc/sendmail.cf
> Fw/etc/mail/local-host-names

Now tell me the contents of that file.

Ideally, it should have the name a.mydomain.com in there, all by itself 
on a line.  ('service sendmail restart' should incorporate a change if 
you add it)

If that still does not work, it may be a fault of your hand-added bits 
to the MC file.  Maybe you should look into a Smart Host setup, instead 
of this bit that it looks like you've added.  A 'smart host' config is, 
to the best of my memory, a common setup to deal with just your machine 
config:  a machine (like your A) that handles local mail locally, but 
all other mail is passed off to B for processing.  In this case, B is 
your Smart Host.

  - bish

Sudheesh Krishnankutty wrote:
> Dear linuxmanagers,
> 
>   I have one problem with my mail server relay configuration.
> 
>   I have a machine A.mydomain.com that relays all the mails to B.mydomain.com
>   (where B.mydomain.com is the central Hub). It works perfectly for incoming
>   and outgoing mails.  
> 
>   But the problem happens when I do the following in machine A (relay
>   host).
> 
>   $mail root  
> 
>   Here what happens is root gets converted to root@A.mydomain.com and it
>   sends it to B.mydomain.com.  B.mydomain.com again sends it back to
>   A.mydomain.com.  This goes into an a loop till maximum hop counts is
>   reached ( which is set to 25).
> 
>   But If I say
>   $mail root@mydomain.com then it works perfectly.
> 
>   My sendmail.mc file which I used for generating sendmail.cf file in
>   A.mydomain.com (relay) contains the following 
>   
>   define(`MAIL_HUB', `B')
>   FEATURE(relay_entire_domain)
>   FEATURE(masquerade_entire_domain)
>   FEATURE(masquerade_envelope)
>   FEATURE(allmasquerade)
> 
>   MASQUERADE_AS(mydomain.com)
>   MASQUERADE_DOMAIN(mydomain.com)
>   RELAY_DOMAIN(mydomain.com)
> 
>   MAILER(local)
>   MAILER(smtp)
>   LOCAL_RULE_0
> 
>   # Send internal mail to hub.
>   R$+ < @ $* $=M . >      $# relay $@ $H $: $1 < @ $2$3 . >
> 
> 
>   LOCAL_RULESETS
> 
>   # Change bare (unqualified) hostname to our domain name in
>   # both sender and recipient addresses.
> 
>   S1
>   R$+ < @ $- > $*         $: $1 < @ $M . > $3
> 
>   S2
>   R$+ < @ $- > $*         $: $1 < @ $M . > $3
>   
> 

-- 
	"Trust me on this.  I'm supposed to be sort of a p$*&k.
	 That's why I got hired."  -- Joe Rogan, Fear Factor
					20030204-:0:10:00
-- 
Sudheesh K
Software Engineer EDA
Softjin Infotech Pvt. Ltd.
No 227/70/A Sigma Arcade 1
Marathahalli
Airport Road,
Bangalore - 560037
Phone: 91-080-5234641/2 ext 206
Fax: 91-080-5234643
--------------------------------------------------------------------------------
This e-mail message and any files transmitted with it are intended solely for  
the use of the individual or entity to which they are addressed. It may contain
confidential, proprietary or legally privileged information. If you are not the
intended  recipient please be advised that  you have  received this message in 
error and any use is strictly prohibited. Please immediately delete it and all 
copies of it from your system, destroy any hard copies of it and notify the 
sender by return mail. You must not, directly or indirectly, use, disclose, 
distribute, print, or copy any part of this message if you are not the intended 
recipient.
------------------------------------------------------------------------------
_______________________________________________
LinuxManagers mailing list - http://www.linuxmanagers.org
submissions: LinuxManagers@linuxmanagers.org
subscribe/unsubscribe: http://www.linuxmanagers.org/mailman/listinfo/linuxmanagers

[Home]     [Kernel List]     [Linux SCSI]     [Video 4 Linux]     [Linux Admin]     [Yosemite News]     [Motherboards]

Powered by Linux