Unrecognized configuration section system.serviceModel after installing Visual Studio 2008 - by Lars Thomas Bredland

Status : 

  Not Reproducible<br /><br />
		The product team could not reproduce this item with the description and steps provided.<br /><br />
		A more detailed explanation for the resolution of this particular item may have been provided in the comments section.

Sign in
to vote
ID 323659 Comments
Status Closed Workarounds
Type Bug Repros 0
Opened 1/23/2008 2:41:51 AM
Access Restriction Public


When trying to run "any" program after installing Visual Studio 2008 I get the following excpetion: "Configuration system failed to initialize"
Inner Exception: 
"Unrecognized configuration section system.serviceModel. (C:\\Windows\\Microsoft.NET\\Framework\\v2.0.50727\\Config\\machine.config line 137)"
Stack Trace:
   at System.Configuration.ClientConfigurationSystem.EnsureInit(String configKey)
   at System.Configuration.ClientConfigurationSystem.System.Configuration.Internal.IInternalConfigSystem.GetSection(String sectionName)
   at System.Configuration.ConfigurationManager.GetSection(String sectionName)
   at System.Configuration.PrivilegedConfigurationManager.GetSection(String sectionName)
   at System.Net.Configuration.SettingsSectionInternal.get_Section()
   at System.Net.Sockets.Socket.InitializeSockets()
   at System.Net.IPAddress.InternalParse(String ipString, Boolean tryParse)
   at System.Net.IPAddress.Parse(String ipString)
   at ConsoleApplication1.Program.Main(String[] args) in C:\Users\user\Documents\Visual Studio 2008\Projects\ConsoleApplication1\ConsoleApplication1\Program.cs:line 12
   at System.AppDomain._nExecuteAssembly(Assembly assembly, String[] args)
   at System.AppDomain.ExecuteAssembly(String assemblyFile, Evidence assemblySecurity, String[] args)
   at Microsoft.VisualStudio.HostingProcess.HostProc.RunUsersAssembly()
   at System.Threading.ThreadHelper.ThreadStart_Context(Object state)
   at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.ThreadHelper.ThreadStart()

Removing the service model section from machine config removes the issue.
Sign in to post a comment.
Posted by Lars Thomas Bredland on 1/31/2008 at 3:33 AM
Hi, and thanks a lot!

The suggested repairs seems to have fixed the issue.

The first repair (wcf) fails in the step after installing http handlers (see clip below). I don't know if this is important(?).
<-- clip -->
Repairing: WMI Classes

Failure executing "I:\Windows\system32\wbem\mofcomp.exe" with parameters ""I:\Windows\Microsoft.NET\Framework\v3.0\Windows Communication Foundation\ServiceModel.mof"": System.ApplicationException: Unexpected result 1 executing I:\Windows\system32\wbem\mofcomp.exe with "I:\Windows\Microsoft.NET\Framework\v3.0\Windows Communication Foundation\ServiceModel.mof"
at System.ServiceModel.Install.InstallHelper.ExecuteWait(String program, String parameters, Int32[] allowedExitCodes)
at System.ServiceModel.Install.WmiInstallComponent.OnInstall(OutputLevel outputLevel)
<--- clip end -->

After running /ResetSkipPkgs and /ResetAddin everything seems to be in order in Visual Studio as well.

I have included the vslogs.cab file to the case if you need them .

Lars Thomas
Posted by Microsoft on 1/30/2008 at 3:40 PM
To figure out the cause we'd need your VS 2008 setup install logs. You can gather these using the Collect tool: http://blogs.msdn.com/astebner/archive/2007/08/01/4172276.aspx

In the meantime, you should be able repair your install by running:
"%windir%\Microsoft.NET\Framework\v3.0\Windows Communication Foundation\ServiceModelReg.exe" /r /x
%windir%\Microsoft.NET\Framework\v3.5\WFServicesReg.exe /c

Hope that helps,
Dan Glick
Software Development Engineer, WCF
Posted by Microsoft on 1/24/2008 at 2:18 AM
Thanks for your feedback.

We are escalating this issue to the appropriate group within the Visual Studio Product Team for triage and resolution.
These specialized experts will follow-up with your issue.

Thank you,
Visual Studio Product Team
Posted by Microsoft on 1/23/2008 at 9:21 PM
Thank you for your feedback. We are currently investigating. The investigation process normally takes 7-14 days. If this issue is urgent, please contact support directly (see http://support.microsoft.com).

If at any time your issue is closed unsatisfactorily, you may edit your issue via Connect and change the status to “Active.”

Thank you,
Visual Studio Product Team