Udostępnij za pośrednictwem


Stale machine.config entries referencing ‘2.0.0.0’ versions of .NET Framework 3.0 assemblies blocks installation of the .NET Framework 3.0 package

Craig McLuckie just compiled documentation that details work around instructions for common .NET Framework 3.0 setup issues. You can find the full document on the WCF Forums titled Common WCF RC1 Installation Issues. The following is a WCF specific issue captured as a separate blog post here for ease of search.

Problem: Stale machine.config entries referencing ‘2.0.0.0’ versions of .NET Framework 3.0 assemblies blocks installation of the .NET Framework 3.0 package

Source of Issue:

Some preview (CTP and Beta) versions of the .NET Framework 3.0 did not remove all machine.config entries on uninstall. These entries that reference the 2.0.0.0 version of ‘System.ServiceModel.dll’ in the machine.config file blocks the correct installation of the .NET Framework 3.0.

Symptoms:

1. .NET Framework 3.0 installation fails with this error:

“ERROR_INSTALL_FAILURE 1603 Fatal error during installation”

2. An error event appears in the application event log that references problems running ServiceModelReg.exe.

3. The setup log file titled ‘dd_wcf_retCA*’ in the users %temp% directory location contains an entry indicating problems running ServiceModelReg.exe.

Either the event log entry, or the setup log entry may contain an exception that looks like the following (timestamp will vary):

ServiceModelReg [16:21:10:656]: Error: System.IO.FileLoadException: Could not load file or assembly 'System.ServiceModel, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089' or one of its dependencies. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)

Resolution:

Remove the stale machine.config entries by hand

a. From a command window run “notepad %windir%\microsoft.net\framework\v2.0.50727\config\machine.config”

b. Remove any xml nodes and child nodes that reference System.ServiceModel.dll

c. If you are running a 64 bit machine, you will also need to edit “%windir%\Microsoft.NET\Framework64\v2.0.50727\config\machine.config” if it exists and perform the same action.

Note: This issue only occurs if you have installed an early preview version of the .NET Framework 3.0 on your system before installing the RC1 version.

Mark Gabarra

This posting is provided "AS IS" with no warranties, and confers no rights. Use of included script samples are subject to the terms specified at https://www.microsoft.com/info/cpyright.htm