Broker agent Won't start, crashing after power outtage on network switch.
Exception:
System.Management.ManagementException Invalid class
at System.Management.ManagementException.ThrowWithExtendedInfo(ManagementStatus errorCode)
at System.Management.ManagementObjectCollection.ManagementObjectEnumerator.MoveNext()
at Citrix.MetaInstaller.CoreUtilities.IsVirtualMachine(VMType type)
at Citrix.MetaInstaller.MetaInstallerApplication.Run(String[] args)
at Citrix.MetaInstaller.MetaInstallerApplication.InstallResultMain(String[] args)
Application: BrokerAgent.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.Reflection.TargetInvocationException
Stack:
at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
at System.Reflection.RuntimeMethodInfo.UnsafeInvokeInternal(Object obj, Object[] parameters, Object[] arguments)
at System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at Citrix.Cds.PluginLoader.PluginProxy.StartPlugin()
at Citrix.Cds.PluginLoader.PluginProxy.StartPlugin()
at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
at System.Threading.ThreadHelper.ThreadStart()
Faulting application name: BrokerAgent.exe, version: 7.1.0.4019, time stamp: 0x5255694d
Faulting module name: KERNELBASE.dll, version: 6.1.7601.18229, time stamp: 0x51fb1677
Exception code: 0xe0434352
Fault offset: 0x000000000000940d
Faulting process id: 0x1988
Faulting application start time: 0x01d019c5969618fd
Faulting application path: C:\Program Files\Citrix\Virtual Desktop Agent\BrokerAgent.exe
Faulting module path: C:\Windows\system32\KERNELBASE.dll
Report Id: d5d91837-85b8-11e4-86a5-b499babae614
If that doesn't work then you must rebuild the repository.
Rebuilding the WMI repository:
To fully rebuild the WMI Repository follow these steps:
1. Disable and stop the winmgmt service
2. Remove or rename C:\Windows\System32\wbem\repository
3. Enable and start the winmgmt service
4. Open a CMD prompt as Administrator
5. In the CMD prompt Navigate to C:\Windows\System32\wbem\
6. Run the cmd ‘for /f %s in ('dir /b *.mof') do mofcomp %s’
(this will take a minute or so to complete)
Sometimes this step is optional
7. Now run the cmd ‘for /f %s in ('dir /b en-us\*.mfl') do mofcomp en-us\%s’
Reboot machine
For more information: https://msdn.microsoft.com/en-us/library/aa394525(v=vs.85).aspx