Getting "unable to load one or more of the requested types" when starting semantic logging out-of-process service

Topics: Semantic Logging Application Block
Jun 10, 2014 at 8:09 PM
I have a new 64-bit Windows Server 2012 install and downloaded version 1.1.1403.0 of the semantic logging application block. I followed the instructions to get the rest of the dependencies. I then installed the service and tried to run it but got the following exception:

System.Reflection.ReflectionTypeLoadException: Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.
at System.Reflection.RuntimeModule.GetTypes(RuntimeModule module)
at System.Reflection.RuntimeModule.GetTypes()
at System.Reflection.Assembly.GetTypes()
at Microsoft.Practices.EnterpriseLibrary.SemanticLogging.Etw.Configuration.ExtensionsInspector.ProbeExtensions(String[] files)
at Microsoft.Practices.EnterpriseLibrary.SemanticLogging.Etw.Configuration.ExtensionsInspector.ProbeExtensions(String[] files)
at Microsoft.Practices.EnterpriseLibrary.SemanticLogging.Etw.Configuration.ExtensionsInspector.CreateInstance(IEnumerable`1 filesToInspect)
at Microsoft.Practices.EnterpriseLibrary.SemanticLogging.Etw.Configuration.ExtensionsLoader.Initialize(String probingPath)
at Microsoft.Practices.EnterpriseLibrary.SemanticLogging.Etw.Configuration.ExtensionsLoader.GetOrCreateInstance(String probingPath)
at Microsoft.Practices.EnterpriseLibrary.SemanticLogging.Etw.Configuration.ConfigurationReader..ctor(String file)
at Microsoft.Practices.EnterpriseLibrary.SemanticLogging.Etw.Configuration.TraceEventServiceConfiguration.Load(String fileName, Boolean monitorChanges, Boolean createSinks)
at Microsoft.Practices.EnterpriseLibrary.SemanticLogging.Etw.Service.TraceEventServiceHost.OnStart(String[] args)

The server only has the .Net 4.5.1 framework installed.

Can anyone give me a hand as to how to resolve this issue?

Jun 11, 2014 at 1:19 AM
I assume you are using the Semantic Logging Application Block - Out-of-process Service. It looks like an error is occurring trying to load assemblies that contain sinks or formatters. Unfortunately, the error message does not give a lot of detail.

Can you try with the latest version 1.1.1403.2 (you may have it already since the assembly version is 1.1.1403.0)? You can get it from NuGet.

Then go to the packages\EnterpriseLibrary.SemanticLogging.Service.1.1.1403.2\tools directory and open a command prompt and run:

c:\>powershell -f install-packages.ps1

Hit Y and press enter to install all assemblies.

You should see the following assemblies:


Next run as a console application:

c:\>SemanticLogging-svc.exe -c

It should start.
You should be able to run the service with only the following present:


If you follow the above do you still experience the issue?

Randy Levy
Enterprise Library support engineer
Support How-to
Jun 11, 2014 at 3:29 PM
Thank you Randy for your help!

I ran through your instructions and was able to start the service using the -c flag. I then installed the service and tried to run it only to get the same error. I figured out that the service was trying to run under a user that did not have administrator privleges. I changed it to use the local system account and now it is running perfectly.

Thanks Again!
Marked as answer by smchristensen on 6/11/2014 at 8:29 AM
Jun 16, 2014 at 5:03 AM
Edited Jun 16, 2014 at 5:04 AM
Glad to hear that you resolved the issue. FYI: there is change published to the source repository but not yet released/packaged to allow user accounts to be specified when installing the service.

Randy Levy
Enterprise Library support engineer
Support How-to