[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [cobalt-users] MX record question / Raq4i



Phil Beynon wrote:
> 
> Hi all,
> Quick MX question:-
> 
> If I want a site to get email as
> xyz@xxxxxxxxxxx
> xyz@xxxxxxx
> xyz@xxxxxxxxxxxx
> 
> I know that I set up aliases for the mailserver www.123.com for
> the other two in site setup but do I also need to create a DNS
> MX record for each one? Should I ever have more than one MX
> record per virtual site? The User Guide is not really clear
> on this and it's an area that's really weak in my personal
> knowledge right now!

By default/internally, the RaQ "accepts" email for
user@xxxxxxxxxxxxxxxx  By adding mail server aliases (domain.com,
mail.domain.com, etc), you are also telling it to accept email for
user@xxxxxxxxxx, user@xxxxxxxxxxxxxxx, etc).  In the virtusertable file,
entries are made like:

@mail.foo.com   %1@xxxxxxxxxxx

Which "rewrites" incoming mail addresses for user@xxxxxxxxxxxx to be
user@xxxxxxxxxxxx  Then, there are "direct" mappings of
user@xxxxxxxxxxxxxx to the RaQ usernames:

user@xxxxxxxxxxx	login_name

The only other thing you need to do is have DNS "A" records defined for
each of those other aliases (domain.com, mail.domain.com, etc) which
point to the IP address for host.domain.com.

Example:

I own www.foo.com as my domain, and it's on my RaQ as IP 12.34.56.78,
and I want to get email for user@xxxxxxx or user@xxxxxxxxxxxxx  I would
need the following DNS records set up (on whatever DNS server is
authoritative for foo.com):

A record: www.foo.com -> 12.34.56.78
A record: foo.com -> 12.34.56.78
A record: mail.foo.com -> 12.34.56.78
MX record (high priority): foo.com -> mail.foo.com

Then, in the RaQ4 Site Settings screen, you would need to add the
following in the Email Server Alias field:

foo.com, mail.foo.com

(The advantage to saying all mail should be handled by mail.foo.com is
that if you ever need to migrate your mail handling to a separate
server, all you need to do is modify the "A" record for mail.foo.com to
point to a new server, and you're all set.)

So, in the above case, if I have user bob on www.foo.com, mail addressed
to bob@xxxxxxx gets handled like this:

first, mail to bob@xxxxxxx gets "rewritten" to bob@xxxxxxxxxxxx  Then
bob@xxxxxxxxxxx is "rewritten" to bob, and is delivered to the mail
spool for bob (/home/spool/mail/bob).


You would only set up multiple MX records for a domain if you have
backup mail servers that could accept mail for your domain if the main
mail server can't (offline, etc).  That's where the priority setting
comes into play on the MX record generation screen.  So, if you have an
arrangement with your ISP that they will collect mail for your domain if
you can't, you would set up a 2nd MX record for foo.com like this:

MX record (lower priority): foo.com -> mail.your_isp.com

If mail _is_ sent your ISP, you would then need to have them forward it
onto your mail server once it's operating again, or else have all your
email recipients point their email software at mail.your_isp.com to pick
it up directly.

-- 
Bruce Timberlake
Technology Engineer
Sun Cobalt Server Appliances
Sun Microsystems, Inc.

E: bruce.timberlake@xxxxxxx
U: http://www.sun.com/cobalt/