Australian cloud for business software — built and run in Sydney since 2002

NetLeverage
NetLeverage

AD replication error 1722 "The RPC server is unavailable": find the layer that is really failing

Technical article
Troubleshooting

About this article: This article is reviewed against the cited sources. This is source research, not lab validation. Check the stated versions and your own requirements before making changes.

Error 1722 does not mean the domain controller's replication engine is broken. It means the destination domain controller could not open a connection to the source domain controller, and the remote procedure call (RPC) layer reported that failure in its own words. Microsoft's article on the error says it plainly: RPC "has no special insight into failures but attempts to map lower-layer protocol failures into an error at the RPC layer" (Microsoft Learn, replication error 1722).

So the work is to find which lower layer failed. Start with name resolution, then the firewall between the two servers, then whether the source server is reachable and healthy at all.

What you see

The same failure appears in several tools:

  • dcdiag reports that the Replications test failed with error 1722, often followed by DsBindWithSpnEx() failed with error 1722.
  • repadmin /showrepl or repadmin /replsum shows 1722 (0x6ba): The RPC server is unavailable against an inbound partner, with a count of consecutive failures and the time of the last success.
  • Replicate now in Active Directory Sites and Services returns "The RPC server is unavailable" and suggests a DNS lookup problem.
  • The Directory Service event log carries events such as 1311, 1865 and 1925 from the Knowledge Consistency Checker, or 1960 from NTDS Replication.
  • Promoting a new domain controller fails because the wizard cannot create its NTDS Settings object on the helper domain controller.

Write down the time of the last success before you change anything. It tells you how long the partner has been out of step, and that matters later (see "What to watch afterwards").

Why it happens

Microsoft lists the common lower-layer causes: link failure, DHCP failure, DNS failure, WINS failure, routing failure "including blocked ports on firewalls", IPsec or network authentication failures, resource limits, and the higher-layer service not running or returning the error itself (Microsoft Learn).

Two of these are the ones to rule out first, because they change whenever servers move or networks are re-segmented:

  1. Name resolution. The destination finds the source by looking up its DNS records. Microsoft states that DNS lookup failures "are the cause of a large number of 1722 RPC errors when it comes to replication". A domain controller pointing at a public resolver, a stale A record left after a server moved address, or a missing _msdcs alias record all produce 1722.
  2. The RPC port pair. Replication starts with a call to the RPC endpoint mapper on TCP 135, which tells the client which dynamically assigned port the replication service is listening on. The client then connects to that second port. On Windows Server 2008 and later the default dynamic range is TCP 49152 to 65535 (Microsoft Learn, firewall for AD domains and trusts). A firewall that allows 135 but not the dynamic range lets the first step succeed and the second fail, which is exactly what 1722 looks like.

This is common after domain controllers are split across sites, put behind a new firewall, moved into a different network segment, or rebuilt with a host firewall profile that changed.

How to prove the cause

Run these from the destination domain controller (the one reporting the error) towards the source. They are read-only checks.

1. Confirm the failing pair and partition.

repadmin /showrepl <destination DC>
repadmin /replsum

Note which source and which directory partition fail. If every partner fails, suspect the destination's own DNS client settings or network. If one source fails from everywhere, suspect that source.

2. Test name resolution.

dcdiag /test:dns /v /e /f:dcdiag-dns.log
nltest /dsgetdc:<domain name>
ping -a <IP address of the source DC>

dcdiag /test:dns checks authentication, basic settings, record registration, dynamic update, delegations and forwarders, and summarises the results per domain controller (Microsoft Learn). nltest /dsgetdc exercises the domain controller locator. ping -a is a quick check that the source's address resolves back to the expected host name. If the name resolves to an old address or to nothing, you have found the cause.

3. Test the two ports. Microsoft's article uses PortQry:

portqry -n <source DC> -e 135
portqry -n <source DC> -r 49152-65535

The 1722 article shows a range of 1024-5000. That range applies to Windows Server 2003 and earlier; for Windows Server 2008 and later use 49152-65535, or the fixed port you have configured if replication RPC was restricted to a single port. Read the results as Microsoft's PortQry page defines them (Microsoft Learn, Using the PortQry command-line tool). NOT LISTENING means the server answered that no process uses that port, which is normal for most ports in the range. FILTERED means "PortQry didn't receive a response from the target port", which is what a blocking firewall looks like. The -e 135 query lists the endpoints registered with the RPC endpoint mapper. Find the Active Directory replication entry in that list and test its port with portqry -n <source DC> -e <port>. If 135 answers but that port shows FILTERED, the firewall is the cause. Scanning the whole range is slow, because PortQry tries each TCP port three times before reporting FILTERED. PortQry is a separate download from Microsoft and is not installed by default.

4. Check the other causes Microsoft lists.

  • Signing mismatch. Microsoft notes that inconsistent SMB signing settings between domain controllers can produce 1722 and recommends setting them consistently in the Default Domain Controllers Policy under Computer Configuration\Windows Settings\Security Settings\Local Policies\Security Options.
  • UDP fragmentation. If LSASRV events 40960 and 40961 appear alongside the error, Kerberos over UDP may be fragmenting on the path. Microsoft points to forcing Kerberos to use TCP.
  • RPC client protocols. The registry key HKLM\Software\Microsoft\Rpc\ClientProtocols should contain ncacn_http, ncacn_ip_tcp, ncacn_np and ncacn_ip_udp, each with the value rpcrt4.dll. If values are missing, Microsoft advises importing the key from a known good server.
  • Network adapter drivers. Microsoft lists faulty network card drivers as a cause; check with the hardware or hypervisor vendor for current drivers.

The fix

Fix the layer you proved, not the one you suspect.

  • DNS. Point each domain controller's DNS client at DNS servers that host the Active Directory zone, never at your internet provider's resolvers. Microsoft warns that if a domain controller points at an ISP's DNS servers, "the Netlogon service on the domain controllers doesn't register the correct records" that other domain controllers need to find it; external names belong in forwarders on the internal DNS servers instead (Microsoft Learn, DNS client settings). Correct or remove the stale record. After changing DNS client settings, Microsoft's procedure is ipconfig /flushdns followed by ipconfig /registerdns. Re-run dcdiag /test:dns until the source passes.
  • Firewall. Between domain controllers, allow TCP 135 and the RPC dynamic range (49152-65535 on Windows Server 2008 and later), together with the other ports Microsoft lists for domain controllers: DNS 53 TCP/UDP, Kerberos 88 TCP/UDP, LDAP 389 TCP/UDP, LDAP GC 3268, SMB 445, Kerberos password change 464, and the time service on UDP 123 where it applies (Microsoft Learn). Add 636 and 3269 only if clients use LDAP over TLS. Microsoft adds that a mixed estate still running domain controllers older than Windows Server 2008 also needs the low range 1025-5000 (Microsoft Learn, service overview and port requirements). If opening a 16,384-port range is not acceptable on your network, Microsoft documents how to hard-code the port used for Active Directory replication ("Restricting Active Directory RPC traffic to a specific port"); open that port instead. Change one thing at a time so you know what fixed it.
  • Signing. Make the four SMB signing policies identical across all domain controllers through the Default Domain Controllers Policy.
  • Source server down or overloaded. If the source is unreachable for a plain reason (powered off, network detached, out of memory), restore the server, not the firewall rules.

How to confirm the fix

repadmin /syncall
repadmin /replsum
repadmin /showrepl <destination DC>
dcdiag /test:replications

repadmin /syncall should complete without a 1722 (0x6ba) callback message. repadmin /replsum should then show zero failures for the pair, and repadmin /showrepl a recent "Last success" for each partition from that source. In Sites and Services, Replicate now on the connection object should complete without an error. Check the Directory Service event log on both domain controllers for fresh 1722-related events over the next replication cycle.

What to watch afterwards

  • How long the outage lasted. If the last success was weeks or months ago, compare that with the forest's tombstone lifetime before you force replication. A partner that has been silent longer than the tombstone lifetime is blocked by Active Directory to protect against lingering objects (event 2042, error 8614), and needs a different recovery.
  • Recurrence after changes. The fault tends to come back after firewall rule changes, new network segments or a rebuilt server whose host firewall profile changed. Keep repadmin /replsum as part of any network change check.
  • Monitoring. Alert on replication failures rather than waiting for a user to report a missing account or a password that works on one server and not another.

Risks and limits

  • Everything above is diagnostic until the fix step. Do not seize operations master roles, run metadata cleanup or restore a domain controller to fix a 1722; those steps are for a domain controller that is permanently gone, not one you cannot reach.
  • Microsoft's 1722 article still carries examples from Windows Server 2003 (netdiag, the 1024-5000 range, DNSLint output). The method holds on current versions; the specific ranges and tools do not.
  • Do not use the general port list in Microsoft's "Service overview and network port requirements" page to configure Windows Firewall itself; Microsoft says so on the firewall article.
  • Not every listed port is needed in every design. Microsoft notes, for example, that file replication ports are not needed where the firewall separates members from domain controllers, and LDAP over TLS ports are not needed if no client uses them.

Sources

Next step

If replication between your domain controllers keeps breaking after network or firewall changes, or you are moving domain controllers into a hosted environment and want the ports, DNS and monitoring set up correctly from the start, NetLeverage has looked after business servers since 2002. Talk to us through managed support and bring your repadmin /replsum output.