Pages

Wednesday, 18 June 2014

Preparing Schema for Exchange 2013 Error: There was an error while running 'ldifde.exe' to import the schema file (Setup.exe /PrepareSchema)

You are attempting to prepare an environment for the installation of an Exchange 2013 SP1 deployment, the first stage is to run the following command.



setup.exe /PrepareSchema /IAcceptExchangeServerLicenseTerms

The setup.exe resides on the Exchange 2013 media. The following error is displayed from the Exchange setup.exe,
 
You open the LDIFDE log file from the default location  C:\Users\username\AppData\Local\Temp\ldif.log and it states error 0x21a2 The FSMO role ownership could not be verified because its directory partition has not replicated...
 
This error relates to stale or non-existing domain controllers, luckily this is only my lab environment and it so happens I know there was an old DC removed forcibly. The next stage is to find the old computer object of the DC in Active Directory and remove it, tick the box Delete this Domain Controller anyway. It is permanently offline and can no longer be removed using the removal wizard. and click Delete.



 
You should also remove any old DNS records associated with this DC, I also deleted it from Active Directory Sites and Services to complete the removal. Now if you run the command again, it will complete successfully.

 
In a production environment it is highly likely you will have tenth of domain controllers, probably in multiple AD sites. Therefore it maybe a large discovery exercise to resolve this issue if you are experiencing the issue in production.
Tools such as DCDIAG.exe and Replmon.exe can prove useful when looking at these issues.