0
Answered

EventBroker failed to start with the below error (possibly due to .Net compability):

Huu Tran 1 year ago • updated by Adam van Vliet (Chief Information Security Officer) 1 year ago 5

Application: Unify.Service.Event.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.IO.FileNotFoundException
   at System.ModuleHandle.ResolveType(System.Reflection.RuntimeModule, Int32, IntPtr*, Int32, IntPtr*, Int32, System.Runtime.CompilerServices.ObjectHandleOnStack)
   at System.ModuleHandle.ResolveTypeHandleInternal(System.Reflection.RuntimeModule, Int32, System.RuntimeTypeHandle[], System.RuntimeTypeHandle[])
   at System.Reflection.RuntimeModule.ResolveType(Int32, System.Type[], System.Type[])
   at System.Reflection.CustomAttribute.FilterCustomAttributeRecord(System.Reflection.CustomAttributeRecord, System.Reflection.MetadataImport, System.Reflection.Assembly ByRef, System.Reflection.RuntimeModule, System.Reflection.MetadataToken, System.RuntimeType, Boolean, System.Object[], System.Collections.IList, System.RuntimeType ByRef, System.IRuntimeMethodInfo ByRef, Boolean ByRef, Boolean ByRef)
   at System.Reflection.CustomAttribute.GetCustomAttributes(System.Reflection.RuntimeModule, Int32, Int32, System.RuntimeType, Boolean, System.Collections.IList, Boolean)
   at System.Reflection.CustomAttribute.GetCustomAttributes(System.Reflection.RuntimeAssembly, System.RuntimeType)
   at System.Attribute.GetCustomAttributes(System.Reflection.Assembly, System.Type, Boolean)
   at System.AppDomain.GetTargetFrameworkName()



Strange enough, .Net version in the machine is 4.6.1. When running command line debugging, the error is:


D:\Program Files\UNIFY Solutions\Event Broker\Services>Unify.Service.Event.Debug
.exe

Unhandled Exception: System.IO.FileNotFoundException: Could not load file or ass
embly 'Unify.Framework, Version=5.1.0.0, Culture=neutral, PublicKeyToken=84b9288
cb2633de4' or one of its dependencies. The system cannot find the file specified
.
   at System.ModuleHandle.ResolveType(RuntimeModule module, Int32 typeToken, Int
Ptr* typeInstArgs, Int32 typeInstCount, IntPtr* methodInstArgs, Int32 methodInst
Count, ObjectHandleOnStack type)
   at System.ModuleHandle.ResolveTypeHandleInternal(RuntimeModule module, Int32
typeToken, RuntimeTypeHandle[] typeInstantiationContext, RuntimeTypeHandle[] met
hodInstantiationContext)
   at System.Reflection.RuntimeModule.ResolveType(Int32 metadataToken, Type[] ge
nericTypeArguments, Type[] genericMethodArguments)
   at System.Reflection.CustomAttribute.FilterCustomAttributeRecord(CustomAttrib
uteRecord caRecord, MetadataImport scope, Assembly& lastAptcaOkAssembly, Runtime
Module decoratedModule, MetadataToken decoratedToken, RuntimeType attributeFilte
rType, Boolean mustBeInheritable, Object[] attributes, IList derivedAttributes,
RuntimeType& attributeType, IRuntimeMethodInfo& ctor, Boolean& ctorHasParameters
, Boolean& isVarArg)
   at System.Reflection.CustomAttribute.GetCustomAttributes(RuntimeModule decora
tedModule, Int32 decoratedMetadataToken, Int32 pcaCount, RuntimeType attributeFi
lterType, Boolean mustBeInheritable, IList derivedAttributes, Boolean isDecorate
dTargetSecurityTransparent)
   at System.Reflection.CustomAttribute.GetCustomAttributes(RuntimeAssembly asse
mbly, RuntimeType caType)
   at System.Attribute.GetCustomAttributes(Assembly element, Type attributeType,
 Boolean inherit)
   at System.AppDomain.GetTargetFrameworkName()


Pls advise.

Answer

Answer

This shouldn't have been caused by an external installation, if it was (e.g. after rolling back the hotfixes), you may wish to raise a support call with Microsoft.

Please check the installed MIM Event Broker service executable versions, as this was fixed in v3.2.1 (issue was caused by a breaking change to the way .NET loaded assembly level attributes, similar to https://voice.unifysolutions.net/communities/6/topics/66-service-fails-to-start-filenotfoundexception-filtercustomattributerecord). Or update to v4.x to be sure.

Under review

Is there any more information that you can provide? What version of MIM Event Broker? Is it a fresh install? Was .NET just upgraded? Did you have a look for existing issues?

Version is 3.2.1. It was a fresh install but it was running initially. I believe it failed after I applied MIM SP1 hoxfixes and GenericLDAP hotfix. 

Answer

This shouldn't have been caused by an external installation, if it was (e.g. after rolling back the hotfixes), you may wish to raise a support call with Microsoft.

Please check the installed MIM Event Broker service executable versions, as this was fixed in v3.2.1 (issue was caused by a breaking change to the way .NET loaded assembly level attributes, similar to https://voice.unifysolutions.net/communities/6/topics/66-service-fails-to-start-filenotfoundexception-filtercustomattributerecord). Or update to v4.x to be sure.

Yeap. It fixed the issue. Thanks heap Adam.


Apology. I should have search the forum harder initially.