LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   Sendmail 2 servers one domain name (https://www.linuxquestions.org/questions/linux-server-73/sendmail-2-servers-one-domain-name-767031/)

tester2k2002 11-05-2009 05:23 AM

Sendmail 2 servers one domain name
 
Dear all,

Hope to have your input as I am new to sendmail

MX to mailforwarder
mailforwarder will forward emails to serverA and if user not found will forward the mail to ServerB

ServerB will receive the email for user that was not in ServerA and store it locally.

Domain for server A and B is domain.com

so both users in A and B will have an email address of A@domain.com and B.domain.com

The server A configuration behave as it should be. It will forward email to Server B if the user is not in Server A

Problem:
How do I configure sendmail in Server B to

1. Any email received from serverA to be stored locally in B and any outgoing email from users in ServerB relay to mailforwarder

2. If users in Server B sending email to another user that resides in Server A, relay the email to mailforwarder

3. If users in server B sending email to another user that resides in the same Server B, it will locally save it to the sent user mailbox.

Some examples of the configuration and files needed to do this would be appreciated.

EdHeron 11-20-2009 01:20 PM

What you are describing is interesting, but I haven't tried to do that.

I have multiple servers serving a single domain. I solve the issue by making the primary e-mail address an alias to a subdomain address.

For example, user1's email address is user1 @ domain.com. user1's mailbox is on server a. On both server a and server b, we add an alias
Code:

user1@domain.com user1@a.domain.com
user2's address is user2 @ domain.com and the mailbox is on server b, so add an alias
Code:

user2@domain.com user2@b.domain.com
I think that what you'd end up with is functionally similar to what you desire. The downside is when you add or move a user, you'd need to add/change the alias.


All times are GMT -5. The time now is 08:39 PM.