Subdomain records for microsoft exchange online

My primary email points to gmail and it works great. However I’ve had to setup an exchange account for another project, and it would seem the best way to do it is with a subdomain to reroute.

Created a subdomain and started adding records for Microsoft:

MX -/- subdomain -/- -/- Works CNAME -/- autodiscover.subdomain -/- -/- Doesn’t work CNAME -/- msoid.subdomain -/- -/- Doesn’t work CNAME -/- enterpriseenrollment.subdomain -/- -/- Doesn’t work CNAME -/- enterpriseregistration.subdomain -/- -/- Doesn’t work CNAME -/- sip.subdomain -/- -/- Doesn’t work CNAME -/- lyncdiscover.subdomain -/- -/- Doesn’t work TXT -/- v=spf1 -all -/- Doesn’t work SRV -/- _sip._tls -/- -/- Works SRV -/- sipfederationtls.tcp -/- -/- Works

CNAME and TXT records work with main domain, not sure what I’m doing wrong with the sub? Is this not possible? Google makes me think so.

Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.


One issue that I spotted right off was the fact that you’re not defining the actual sub-domain anywhere in your DNS Zone.

An MX entry does not function as a zone entry for a sub-domain in terms of defining it as a usable point of entry. This entry simply tells the mail server where to point, but it doesn’t function as the base level for an actual sub-domain. You’d need to add either a CNAME for the sub-domain or an A entry (if using an IP).

If your DNS Zone is identical to what you’ve setup above, since subdomain doesn’t have a base entry from which to work from, calls to x.subdomain would not function since the base subdomain doesn’t actually exist in the zone file.

Ideally, you would want to setup the MX CNAME as mail or similar, simply for clarity. That’s how I’d set it up if I were doing the same. For example, I’d take the DNS Zone you provided above and modify it to:

MX		mail		
CNAME	subdomain											location.wherethesubdomainpoints.ext
CNAME	autodiscover.subdomain
CNAME	msoid.subdomain
CNAME	enterpriseenrollment.subdomain
CNAME	enterpriseregistration.subdomain
CNAME	sip.subdomain
CNAME	lyncdiscover.subdomain
TXT		v=spf1 -all
SIP		sip.tls		
SRV		sipfederationtls.tcp

The defining change is line #2 where the subdomain is actually defined.