-1

This is a problem about maintaining an all-email VPS server.
First, I have two VPS hosts right now, both running CentOS 6.5, 32bit system. one for web hosting and other for email only.

The reason for that is, since I have many sites, I want the web hosting environment to be completely isolated from the email.

So, I added A record for my domains in this order.

198.551.224.10     www.my-site.tld        # Pointing to my web host IP
198.551.224.10     my-site.tld            # Pointing to my web host IP
198.551.224.11     mail.my-site.tld       # Pointing to my mail host IP

The problem with this approach is that, every email created now will have a prefix of mail before it, like [email protected] so, I was thinking of changing the above configuration to this:

   198.551.224.10     www.my-site.tld        # Pointing to my web host IP
   198.551.224.10     my-site.tld            # Pointing to my web host IP
   198.551.224.10     mail.my-site.tld       # Pointing to my mail host

This way, all addresses are pointing to the same IP, and then somehow tell nginx to redirect any information coming from server mail.my-site.tld to IP 198.551.224.11 (the EMAIL server)

The problem is telling Nginx to redirect the request, yet if anyone has any better information about how to keep an separate email server while retaining that standard email format ex: [email protected]

2 Answers 2

0

The A record will not impact your emails as long as you setup the correct MX record. If you want to receive emails for @example.com, you can setup your zone this way:

mail 3600 IN A 198.551.224.11
@ 3600 IN MX mail.example.com.
8
  • Thanks for the response but I don't have as much filed to type in the that setting. Here is a snap show of my config field i2.minus.com/j9O2eErEu4Qn3.jpg and thanks for clarifying about the MX field.
    – iOi
    Apr 18, 2014 at 13:14
  • @iOi For the MX record, you leave the zone empty and you put the name to your mail server in the value field.
    – Spack
    Apr 18, 2014 at 13:18
  • Ok, I left zone empty, and added mail for the value field (first blank field). I am a little embarrassed to say though, what happens now? I am assuming this will redirect request to my mail server, and [email protected] will be able to read/accept emails?
    – iOi
    Apr 18, 2014 at 13:23
  • When a mail server is sending a message, it looks for the MX record. In your case the reply will send them to ``mail.domain.tld` which what you want to achieve.
    – Spack
    Apr 18, 2014 at 13:26
  • Thanks. I am assuming I have a lot of work to do from here, but I will try. Thunderbird does not seem to detect any account I created using the mail.domain.tld maybe it takes time for this record to propogate
    – iOi
    Apr 18, 2014 at 13:35
0

Aside from the MX settings, you may also need to configure your mail server to use your my-site.tld as its default domain. If using Postfix then look at the mydomain setting and the ones around it. CentOS comments the file good for that stuff.

2
  • Thanks @GeneBean, I that may be my current problem. I have mentioned it here I can't upvote your question since I am low rep, and got suspended after asking that question weird enough. I will try to ask more detailed question with my old account if possible and ping you in
    – iOi
    Apr 18, 2014 at 14:31
  • can you take a look at this question serverfault.com/questions/589953/…
    – iOi
    Apr 18, 2014 at 14:41

Not the answer you're looking for? Browse other questions tagged .