Skip to Content

Solved: How to fix the Exchange Server installation error in RecoverServer mode

Key Takeaways

  • This blog article that explains how to fix the Exchange Server installation error in RecoverServer mode, which occurs when the CU version of the recovery media is different from the CU version of the lost server.
  • The article provides two methods to restore the SerialNumber property in Active Directory, which is the cause of the error, using PowerShell or ADSI Edit. It also gives the SerialNumber values for each CU version.

Problem

Sometimes Exchange Server can fail or become corrupted due to various reasons, such as hardware failure, malware infection, power outage, or human error. When this happens, you may need to recover the lost server by installing Exchange Server in RecoverServer mode.

RecoverServer mode is a special installation option that allows you to restore the Exchange Server configuration from Active Directory and rebuild the server with the same name, IP address, and roles as the original one. This way, you can minimize the impact of the server loss and resume normal operations as soon as possible.

However, installing Exchange Server in RecoverServer mode is not always straightforward. You may encounter some errors or challenges along the way, such as version mismatch, database corruption, or missing prerequisites. In this article, we will show you how to fix the Exchange Server installation error in RecoverServer mode and successfully recover your lost server.

Common error and cause the Exchange Server Installation Error in RecoverServer Mode

One of the most common errors that you may face when installing Exchange Server in RecoverServer mode is the version error. This error occurs when the Exchange Server cumulative update (CU) version of the recovery media is different from the CU version that was installed on the lost server. For example, if the lost server had Exchange Server 2019 CU12 installed, but you try to recover it with Exchange Server 2019 CU11 media, you will get the following error message:

Exchange Server version 15.2 (Build 31118.007) or later must be used to perform a recovery of this server.

Solved: How to fix the Exchange Server installation error in RecoverServer mode

The reason for this error is that the January 2021 security update (SU) for Exchange Server changed the SerialNumber property in Active Directory for the lost server. The SerialNumber property should contain the CU version, but the SU updated it to the SU version instead. Therefore, the prerequisite check fails because it expects the recovery media to have the same or higher version as the SerialNumber property.

To fix the Exchange Server installation error in RecoverServer mode, you need to restore the SerialNumber property to the correct CU version. There are two methods to do this: using PowerShell or using ADSI Edit. We will explain both methods below.

Solution 1: Using PowerShell to restore SerialNumber property to the correct CU version

This method involves using PowerShell commands to update the SerialNumber property in Active Directory. To do this, follow these steps:

Step 1: Open PowerShell as an administrator on a domain controller or a computer that has the Active Directory module installed.

Step 2: Run the following command to import the Active Directory module:Import-Module ActiveDirectory

Step 3: Run the following command to find the distinguished name (DN) of the Exchange Server installation on the lost server. Replace <ServerName> with the name of the lost server.Get-ADObject -Filter {Name -eq "<ServerName>"} -Properties * | Select DistinguishedName

Step 4: Copy the DN value from the output. It should look something like this:CN=EX01,CN=Servers,CN=Exchange Administrative Group (FYDIBOHF23SPDLT),CN=Administrative Groups,CN=Contoso,CN=Microsoft Exchange,CN=Services,CN=Configuration,DC=contoso,DC=com

Step 5: Run the following command to update the SerialNumber property with the correct CU version. Replace <DN> with the DN value you copied in the previous step, and replace <SerialNumber> with the CU version that matches the lost server. You can use the following table to find the SerialNumber value for each CU.Set-ADObject -Identity "<DN>" -Replace @{serialnumber="<SerialNumber>"}

Cumulative Update SerialNumber
Exchange Server 2019 CU12 Version 15.2 (Build 31118.007)
Exchange Server 2019 CU11 Version 15.2 (Build 30986.005)
Exchange Server 2016 CU23 Version 15.1 (Build 32507.006)
Exchange Server 2016 CU22 Version 15.1 (Build 32375.007)

For example, if the lost server had Exchange Server 2019 CU12 installed, you would run the following command:

`Set-ADObject -Identity "CN=EX01,CN=Servers,CN=Exchange Administrative Group (FYDIBOHF23SPDLT),CN=Administrative Groups,CN=Contoso,CN=Microsoft Exchange,CN=Services,CN=Configuration,DC=contoso,DC=com" -Replace @{serialnumber="Version 15.2 (Build 31118.007)"}`

Step 6: Verify that the SerialNumber property has been updated by running the following command:Get-ADObject -Identity "<DN>" -Properties serialnumber | Select serialnumber

You should see the CU version that you specified in the output.

Step 7: Retry the Exchange Server install in RecoverServer mode. Use a recovery media that has the same or higher CU version as the lost server. For example, if the lost server had Exchange Server 2019 CU12 installed, you can use Exchange Server 2019 CU12 or CU13 media to recover it.

Step 8: Install the latest Exchange Server SU after the recovery is complete.

Solution 2: Using ADSI Edit to restore SerialNumber property to the correct CU version

This method involves using ADSI Edit, a graphical tool that allows you to edit Active Directory objects and attributes. To do this, follow these steps:

Step 1: Open ADSI Edit on a domain controller or a computer that has the Remote Server Administration Tools (RSAT) installed.

Step 2: Connect to the Configuration naming context by right-clicking ADSI Edit and selecting Connect to. In the Connection Settings dialog box, select Configuration from the Select a well known Naming Context drop-down list, and click OK.

Step 3: Expand the Configuration container, and navigate to the following path:CN=Configuration,DC=<domain>,DC=<com> -> CN=Services -> CN=Microsoft Exchange -> CN=<organization> -> CN=Administrative Groups -> CN=Exchange Administrative Group (FYDIBOHF23SPDLT) -> CN=Servers -> CN=<ServerName>

Replace <domain> and <com> with your domain name components, <organization> with your Exchange organization name, and <ServerName> with the name of the lost server.

Step 4: Right-click the server object, and select Properties.

Step 5: In the Properties dialog box, scroll down to the serialnumber attribute, and double-click it.

Step 6: In the Edit Attribute dialog box, enter the correct CU version in the Value field. You can use the same table as in Method 1 to find the SerialNumber value for each CU. Click OK to save the changes.

Step 7: Click OK to close the Properties dialog box.

Step 8: Retry the Exchange Server install in RecoverServer mode. Use a recovery media that has the same or higher CU version as the lost server. For example, if the lost server had Exchange Server 2019 CU12 installed, you can use Exchange Server 2019 CU12 or CU13 media to recover it.

Step 9: Install the latest Exchange Server SU after the recovery is complete.

Frequently Asked Questions (FAQs)

Here are some frequently asked questions about the Exchange Server installation error in RecoverServer mode.

Question: What is the difference between RecoverServer mode and /m:RecoverServer switch?

Answer: RecoverServer mode is a general term that refers to the process of recovering a lost Exchange Server by installing Exchange Server with the same name, IP address, and roles as the original one. The /m:RecoverServer switch is a specific parameter that you need to use when running the Exchange Server setup.exe file to perform the recovery. For example, to recover an Exchange Server 2019 server, you would run the following command:

`Setup.exe /IAcceptExchangeServerLicenseTerms /m:RecoverServer`

Question: How can I find out the CU version of the lost Exchange Server?

Answer: If you don’t know the CU version of the lost Exchange Server, you can try the following methods to find it out:

  • Check the Exchange Server setup log files on the lost server, if they are still accessible. The log files are located in the C:\ExchangeSetupLogs folder by default, and they contain information about the Exchange Server version and build number that was installed or updated. You can use the Exchange Server build numbers and release dates article to map the build number to the CU version.
  • Check the Exchange Server setup media that was used to install or update the lost server, if you still have it. The setup media should have the CU version in the file name or folder name. For example, ExchangeServer2019-x64-CU12.iso indicates that the media contains Exchange Server 2019 CU12.
  • Check the SerialNumber property of the lost server in Active Directory, if it has not been modified by the SU. You can use the same PowerShell or ADSI Edit methods as in the solution section to view the SerialNumber property, and compare it with the CU versions in the table. However, if the SerialNumber property has been updated by the SU, it will not reflect the CU version accurately.

Summary

In this article, we have explained how to fix the Exchange Server installation error in RecoverServer mode. We have discussed the causes and solutions for this common issue, and provided two methods to restore the SerialNumber property in Active Directory. We have also answered some frequently asked questions about the RecoverServer mode and how to avoid the error in the future.

We hope that this article has helped you to recover your lost Exchange Server successfully. If you have any questions or feedback, please feel free to leave a comment below.

Disclaimer: This article is for informational purposes only and does not constitute professional advice. We are not affiliated with Microsoft or any of the products or services mentioned in this article. We do not guarantee the accuracy, completeness, or reliability of the information provided in this article. You should always consult a qualified IT professional before making any changes to your Exchange Server environment. We are not responsible for any damages or losses that may result from following the instructions in this article. Use the information in this article at your own risk.