Workflows do not start anymore “Error at startup” The error is caused by improperly initialized Performance Counters based on Windows. A look in the log of SharePoint reveals the following error message:

Load Workflow Class: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. —> System.InvalidOperationException: The requested Performance Counter is not a custom counter, it has to be initialized as ReadOnly.
at System.Diagnostics.PerformanceCounter.InitializeImpl()
at System.Diagnostics.PerformanceCounter..ctor(String categoryName, String counterName, String instanceName, Boolean readOnly)
at System.Workflow.Runtime.PerformanceCounterManager.CreateCounters(String name)
at System.Workflow.Runtime.Hosting.ManualWorkflowSchedulerService.OnStarted()
at System.EventHandler`1.Invoke(Object sender, TEventArgs e)
at System.Workflow.Runtime.WorkflowRuntime.StartRuntime()
at Microsoft.SharePoint.Workflow.SPWinOeHostServices..ctor(SPSite site, SPWeb web, SPWorkflowManager manager, SPWorkflowEngine engine) — End of inner exception stack trace —
at System.RuntimeMethodHandle.InvokeMethod(Object target, Object[] arguments, Signature sig, Boolean constructor)
at System.Reflection.RuntimeConstructorInfo.Invoke(BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
at System.RuntimeType.CreateInstanceImpl(BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes, StackCrawlMark& stackMark)
at System.Activator.CreateInstance(Type type, BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes)
at System.Reflection.Assembly.CreateInstance(String typeName, Boolean ignoreCase, BindingFlags bindingAttr, Binder binder, Object[] args, CultureInfo culture, Object[] activationAttributes)
at Microsoft.SharePoint.Workflow.SPWorkflowManager.LoadPluggableClass(String classname, String assembly, Object[] parameters)

Reinitializing the relevant counter of the Workflow Foundation will solve the problem. Here you have to distinguish whether you have the Foundation 3.0 or 4.0 installed.

Reset Performance Counter Workflow Foundation:

  • C:\> lodctr ‘C:\Windows\inf\Windows Workflow Foundation 3.0.0.0\PerfCounters.ini’
  • C:\> lodctr ‘C:\Windows\inf\Windows Workflow Foundation 4.0.0.0\PerfCounters.ini’
Werbung

Leave a Reply

Your email address will not be published. Required fields are marked *

Fill out this field
Fill out this field
Please enter a valid email address.
You need to agree with the terms to proceed