SRV record
SRVAn SRV record publishes where a particular service runs — including its port, which no other record type carries.
What an SRV record carries
An SRV record, defined in RFC 2782, names the host and port for a specific service. It is the only common record type that includes a port number, which is why protocols that do not use a fixed port rely on it.
The record name encodes the service and protocol as underscore-prefixed labels: _sip._tcp.example.com. The underscores prevent collisions with real hostnames.
What an SRV record looks like
The value carries four fields in a fixed order — priority, weight, port, target: _sip._tcp.example.com. 3600 IN SRV 10 60 5060 sipserver.example.com.
Here the client should try sipserver.example.com on port 5060, at priority 10 and weight 60. The target is a hostname needing its own address record, and a single dot in that position means the service is explicitly not offered.
Because the name itself is part of the lookup, an SRV query for a wrongly assembled name fails quietly rather than loudly. The answer is an ordinary empty one, indistinguishable from a service that was simply never published.
Priority and weight
Each record carries a priority and a weight. Priority works like MX: lower numbers are tried first. Weight distributes traffic among records that share a priority, in proportion to the weight values.
A client is expected to honour both. This gives finer control than MX records, which have priority but no weight.
Where you will meet it
SRV records are used by SIP, XMPP, Minecraft servers, Microsoft Active Directory and various autoconfiguration mechanisms.
Email does not use SRV for delivery — that is what MX is for. Some mail clients do use SRV records to discover submission and IMAP settings automatically, which is a different job.
