Duplicate SPN check on Windows Server 2012 R2-based domain controller causes restore, domain join and migration failures

This article describes some issues that occur on a Windows Server 2012 R2-based domain controller. A hotfix is available to resolve these issues. The hotfix has a prerequisite.
Symptoms
Assume that you have a domain controller that is running Windows Server 2012 R2, you may encounter one of the following issues.

Issue 1: Domain join

You have a new computer, and you want to join it to a domain of the forest. The same computer host name is already used in another domain. In this situation, the domain join operation reports success. After you click OK, you will see the following dialog box. The erased strings are the old and the new primary suffix of the computer:

This is the screenshot of Computer Name/Domain Changes

The error message resembles the following:

While processing a change to the DNS Host Name for an object, the Service Principal Name values could not be kept in sync.

After restart, the computer will report itself as a domain member, but interactive logon with a domain account will fail, and you will receive the following error message:

The security database on the server does not have a computer account for this workstation trust relationship.

You will also receive the following error message in the Netsetup.log file:

0: 000021C7: DSID-03200BA6, problem 1005 (CONSTRAINT_ATT_TYPE), data 0, Att 90303 (servicePrincipalName)
NetpModifyComputerObjectInDs: ldap_modify_s failed: 0x13 0x57

Issue 2: Intra-forest migration

If you perform an intra-forest user migration that has service principal name (SPN) or user principal name (UPN) defined or intra-forest computer migration, the migration fails because the account still exists in the global catalog as the object is introduced in the target domain that has these attributes populated. If the object was saved in the new domain, a duplicate SPN would be created.

Note The tools to drive the migrations might be Active Directory Migration Tool (ADMT), external migration tools or the Move-ADObject cmdlet by using Active Directory PowerShell.

Issue 3: SPN conflicts with SPN on restored object

You had an account with SPNs in use on an account that is deleted now. You add an SPN to the object that used to have another user or computer account in the forest. When you now try to restore the deleted account, the action fails because of the duplicate SPN. 

Note In all three issues, event ID 2974 that resembles the following is logged in the Directory Service log of the domain controller: 


Log Name: Directory Service
Source: Microsoft-Windows-ActiveDirectory_DomainService
Event ID: 2974
Task Category: Global Catalog
Level: Error
Keywords: Classic
Description: The attribute value provided is not unique in the forest or partition. Attribute: servicePrincipalName Value=HOST/server1.contoso.com
CN=Server1,OU=Member Servers,DC=contoso,DC=com Winerror: 8647

The error number 8647 translates to symbolic name is ERROR_DS_SPN_VALUE_NOT_UNIQUE_IN_FOREST. For deplicate UPN, the error would be number 8648 and ERROR_DS_UPN_VALUE_NOT_UNIQUE_IN_FOREST.
Cause
Windows Server 2012 R2 introduced restrictive checking for UPN and SPN uniqueness. It successfully prevents duplicate SPN and UPN when they are driven through administrative tools without requiring the tool to perform a uniqueness check itself.

In the issues that were described in this article, it prevents administrative tasks where the effect is not obvious.
Resolution
In some cases, you can delete the objects that block your action so that the action is successful. For intra-forest migrations and restores, you can also delete the SPNs and/or UPN that would be duplicate, and potentially add them back on the account.

Such a preparation change might not be possible in all cases. Therefore, Microsoft has developed an update that enables controlling the domain controller behavior. This update applies to Windows Server 2012 R2-based domain controllers. You can also install this update on member servers that are candidate for promotion to a domain controller in the future.

With this update, Microsoft provides a forest level switch to turn off or turn on uniqueness check through the dSHeuristics attribute.

The following are the supported dSHeuristics values:
  1. dSHeuristic = 1: AD DS allows adding duplicate user principal names (UPNs)
  2. dSHeuristic = 2: AD DS allows adding duplicate service principal names (SPNs)
  3. dSHeuristic = 3: AD DS allows adding duplicate SPNs and UPNs
  4. dSHeuristic = Any other value: AD DS enforces uniqueness check for both SPNs and UPNs
Examples:
  1. For disabling UPN uniqueness check, set the 21st character of dSHeuristics to "1" (000000000100000000021)
  2. For disabling SPN uniqueness check, set the 21st character of dSHeuristics to "2" (000000000100000000022)
  3. For disabling UPN and SPN uniqueness checks, set the 21st character of dSHeuristics to "3" (000000000100000000023)
For detailed information about how to modify dSHeuristic, see 6.1.1.2.4.1.2 dSHeuristics.

We recommend that you set the value back to 0 when you know problematic changes are not occurring any longer. This can be the case especially for intra-forest migrations.

Hotfix information

Important If you install a language pack after you install this hotfix, you must reinstall this hotfix. Therefore, we recommend that you install any language packs that you need before you install this hotfix. For more information, see Add language packs to Windows.

A supported hotfix is available from Microsoft. However, this hotfix is intended to correct only the problem that is described in this article. Apply this hotfix only to systems that are experiencing this specific problem.

If the hotfix is available for download, there is a "Hotfix Download Available" section at the top of this Knowledge Base article. If this section does not appear, submit a request to Microsoft Customer Service and Support to obtain the hotfix.

Note If additional issues occur or if any troubleshooting is required, you might have to create a separate service request. The usual support costs will apply to additional support questions and issues that do not qualify for this specific hotfix. For a complete list of Microsoft Customer Service and Support telephone numbers or to create a separate service request, visit the following Microsoft website: Note The "Hotfix Download Available" form displays the languages for which the hotfix is available. If you do not see your language, it is because a hotfix is not available for that language.

Prerequisites

To apply this hotfix, you must have April 2014 update rollup for Windows RT 8.1, Windows 8.1, and Windows Server 2012 R2 (2919355) installed in Windows 8.1 or Windows Server 2012 R2.

Registry information

To use the hotfix in this package, you do not have to make any changes to the registry.

Restart requirement

You may have to restart the computer after you apply this hotfix.

Hotfix replacement information

This hotfix does not replace a previously released hotfix.

File information

The global version of this hotfix installs files that have the attributes that are listed in the following tables. The dates and the times for these files are listed in Coordinated Universal Time (UTC). The dates and the times for these files on your local computer are displayed in your local time together with your current daylight saving time (DST) bias. Additionally, the dates and the times may change when you perform certain operations on the files.

Windows 8.1 and Windows Server 2012 R2 file information and notes

Important Windows 8.1 hotfixes and Windows Server 2012 R2 hotfixes are included in the same packages. However, hotfixes on the Hotfix Request page are listed under both operating systems. To request the hotfix package that applies to one or both operating systems, select the hotfix that is listed under "Windows 8.1/Windows Server 2012 R2" on the page. Always refer to the "Applies To" section in articles to determine the actual operating system that each hotfix applies to.
  • The files that apply to a specific product, milestone (RTM, SPn), and service branch (LDR, GDR) can be identified by examining the file version numbers as shown in the following table:
    VersionProductMilestoneService branch
    6.3.960 0.17xxxWindows 8.1 and Windows Server 2012 R2RTMGDR
  • The MANIFEST files (.manifest) and the MUM files (.mum) that are installed for each environment are listed separately in the "Additional file information" section. MUM, MANIFEST, and the associated security catalog (.cat) files, are very important to maintain the state of the updated components. The security catalog files, for which the attributes are not listed, are signed with a Microsoft digital signature.
For all supported x86-based versions of Windows 8.1
File nameFile versionFile sizeDateTimePlatform
Ntdsa.mofNot applicable227,76518-Jun-201312:21Not applicable
Ntdsai.dll6.3.9600.179012,576,89609-Jun-201520:43x86
For all supported x64-based versions of Windows 8.1 and of Windows Server 2012 R2
File nameFile versionFile sizeDateTimePlatform
Ntdsa.mofNot applicable227,76518-Jun-201314:45Not applicable
Ntdsai.dll6.3.9600.179013,684,86409-Jun-201520:49x64

Additional file information

Additional file information for Windows 8.1 and for Windows Server 2012 R2
Additional files for all supported x86-based versions of Windows 8.1
File propertyValue
File nameX86_4c2f5adc88a0d6ac17ccdccf2255c6b7_31bf3856ad364e35_6.3.9600.17901_none_ba36e2d18bbebef8.manifest
File versionNot applicable
File size712
Date (UTC)10-Jun-2015
Time (UTC)12:46
PlatformNot applicable
File nameX86_microsoft-windows-d..toryservices-ntdsai_31bf3856ad364e35_6.3.9600.17901_none_85b97991d47e36db.manifest
File versionNot applicable
File size3,352
Date (UTC)09-Jun-2015
Time (UTC)23:14
PlatformNot applicable
Additional files for all supported x64-based versions of Windows 8.1 and of Windows Server 2012 R2
File propertyValue
File nameAmd64_94aab516433aef4e5f0c8db414ae7999_31bf3856ad364e35_6.3.9600.17901_none_34c8efb13ae81094.manifest
File versionNot applicable
File size716
Date (UTC)10-Jun-2015
Time (UTC)12:46
PlatformNot applicable
File nameAmd64_microsoft-windows-d..toryservices-ntdsai_31bf3856ad364e35_6.3.9600.17901_none_e1d815158cdba811.manifest
File versionNot applicable
File size3,356
Date (UTC)09-Jun-2015
Time (UTC)23:49
PlatformNot applicable
Status
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.
More information
See detailed information about SPN and UPN uniqueness feature in Windows Server 2012 R2.

You may also see Event ID 11 — Service Principal Name Configuration for more information.

Ask Premiere Field Engineer (PFE) Platforms blog: Third-party Active Directory Migration Tools and KB 3070083.
References
See the terminology that Microsoft uses to describe software updates.
Свойства

ИД на статията: 3070083 – Последен преглед: 09/06/2015 09:09:00 – Редакция: 5.0

Windows Server 2012 R2 Datacenter, Windows Server 2012 R2 Standard, Windows Server 2012 R2 Essentials, Windows Server 2012 R2 Foundation, Windows 8.1 Enterprise, Windows 8.1 Pro, Windows 8.1

  • kbqfe kbsurveynew kbfix kbhotfixserver kbautohotfix kbexpertiseinter KB3070083
Обратна връзка