I again bring to you another error that may occur during the deployment of SharePoint 2013. I was configuring a farm recently with SharePoint 2013 SP1 on a farm of Server 2012 R2 servers that had been updated to the latest available patches via the onsite Windows Update server. The servers did not have internet access and thus required the prerequisites to be downloaded beforehand. After gathering the prerequisites and having a (mostly) successful prerequisite install run, I was ready to install the SharePoint bits.
I checked the prereq installer one more time to ensure the first server I would install SharePoint on was ready to go. The checks came back clear so I started running the installer. Failure! I was greeted with an error message with something to the equivalent of:
Setup is unable to proceed due to the following error(s): This product requires Microsoft .Net Framework 4.5
I restarted the installer, hoping it was just a fluke. No dice. Same error. I rebooted the machine. No dice. I ran the prerequisite installer in offline mode again with all the switches for all the prerequisites, let it force reboot, and reran the installer. No dice.
I tried to install .NET Framework 4.5 from the prereq executable to no avail. Windows Server 2012 R2 informed me that it was unnecessary since it was a feature that came default with the OS. Learning this, I scoped the added roles and features of the server, and boom, there it was. .NET Framework 4.5 was listed as an installed feature…so I removed it, rebooted, and then reinstalled it from Server Manager and PowerShell (yes, that’s right; twice).
At this point, I’m having a “Seriously…WTF” moment, especially when I looked at the clock again and realized I had been working on this same issue for over four hours. Luckily one of my coworkers has some super Google-foo and was able to locate an article on the deep parts of the web about how the latest patches for .NET framework changed the version from 4.5.x to 4.6.x and this was causing issues with the SharePoint installer for others as well. I investigated on one of my servers by navigating (in PowerShell) to the .NET framework registry portion under HKLM:
Set-Location 'HKLM:\SOFTWARE\Microsoft\NET Framework Setup\NDP\v4\Client'
Get-ItemProperty -Path . | Select-Object Version
Lo and behold, it returned a 4.6.x version of the .NET framework! My coworker who found the article also found that the fix was to remove the KB that installed the newest version. He suggested we do that the next day (we had already gone home for the day). When I reviewed the site though, I found that one person had commented that although they uninstalled the Windows Updates that upgraded the framework, when they rechecked the versions, they were still on a 4.6.x version. This worried me so I tested a hack method in case uninstalling the framework didn’t work or pushed it back to a previous 4.6.x version. My coworker and I both tried our different implementations the next day, both of which were successful. He proceeded to uninstall the KB update that upgraded the .NET framework. I proceeded to actually change the DWORD value in the registry to a previous but legitimate version of the .NET framework. Both methods worked.
The KB to uninstall is KB3045563
To uninstall the KB:
- Go to the Start menu
- Type in “View installed updates”
- Find and click on KB3045563 in the list
- Click uninstall
- Reboot the machine
- Check the versions to ensure it is back down to 4.5
Microsoft has released an official patch and workaround for this. Please follow the instructions here in order to fix this issue. This requires that you no longer uninstall anything but rather it fixes the installation of SharePoint itself.
The steps can be summed up in the following:
- Extract your installation media somewhere to a writable space.
- Download a ZIP provided by MS with a patched DLL.
- Copy the DLL into the updates folder of the extracted location
- Run SharePoint setup from the extracted location rather than your media source.
After that you should be smooth sailing for installing SharePoint 2013 with no complaints about the .NET framework version.