It’s increasingly common to manage the emails of a company with cloud hosting services like Office 365 or Gmail and it’s natural to do so as it reduces the costs of maintaining the server and guarantees a stability to the service that might not exist when using proprietary or shared hosting.

Changing the email management service requires you to update the DNS records so emails are forward to the new server. Most of the times you just need to update MX record and the TXT spv record but when it comes down to SRV records it might not be that simple.

A few days ago I was tasked to update the DNS records of a given set of domains so they were managed through Office 365. The company that configured Office 365 sent me the DNS records for each domain and I’ve started to update the records. Most of them were simple changes like updating MX record and configuring TXT and CNAME records. Microsoft has a guide available that can help you set up the DNS records in GoDaddy but you can use it to configure on most registrars.

When I got to set up the SRV records and things got tricky because the platform provided by the registrar (I was setting this on the Portuguese didn’t allow me to set up the options individually so I couldn’t set up the Protocol, Port, Priority, Weight or Service. When I selected a record of the type SRV the layout was the same as any other record type:

Manually set up DNS SRV record for Office 365 images/23-definir-manualmente-registo-dns-srv-para-office-365/

A quick look to the infomation stated the Value of the record should be

Value    Weight    Priority    PortNumber    Target

So I took the information the company sent me and created the record as displayed below.

Description Value
Service _sip
Protocol _tls
Port 443
Weight 1
Priority 100
TTL 3600
Name @ (or the domain name)

One side note to the Name of the record entry that needs to include the description of the service and the protocol.

Manually set up DNS SRV record for Office 365 images/23-definir-manualmente-registo-dns-srv-para-office-365/configuracao-errada-registo-srv-manual.png

A few hours later the company reached out and said the DNS record was incorrect and needed fixing. After a few searches and further investigation it turns out the description was incorrect and the Priority needs to go before the Weight.

So the correct manual settings for a SRV record, either for Office 365 or any other must be:

_sip._tls.domain.tld    3600    SRV    1 100 443

For Office 365 you just need to change the to your domain on the record entry name

Article image provided by Designed by Freepik