Tuesday, December 16, 2008

Host [Name] failed while starting monitoring asynchronous operations queue.

I've started working on some Microsoft Dynamics CRM development lately, and came accross this issue with on of our servers when the CRM Asyncronous Service stopped:

Host [Name] failed while starting monitoring asynchronous operations queue.

If you have the ApplicationServer and PlatformServer installed on the same machine, you may receive this error (in the event log) when you try and start the service

Host SGCORPCRM1: failed while starting monitoring asynchronous operations queue. Exception: System.InvalidOperationException: The requested Performance Counter is not a custom counter, it has to be initialized as ReadOnly.
at System.Diagnostics.PerformanceCounter.Initialize()
at System.Diagnostics.PerformanceCounter..ctor(String categoryName, String counterName, String instanceName, Boolean readOnly)
at Microsoft.Crm.Asynchronous.PerformanceCounters..ctor(String instanceName)
at Microsoft.Crm.Asynchronous.AsyncService.OnStart(String[] args)

I'm not sure how this happenned, I had a look for answers and found a Microsft KB on the problem - which was similar, but this did not seem to be applicable.

After some more searching, I finally found a post in the eggheadcafe forums , which came up with the goods (thanks Deepak!). Of course, before applying this fix, I checked a working server first, and found that the RoleNames and Roles registry entries were infact incorrect.

Below I've repeated the steps, hopefully making it easier to find for other with the same issue.
Open the registry and go to the path HKLM\SOFTWARE\Microsoft\MSCRM

  1. Check the 'RoleNames' value and the 'roles' value - they should be set to the following values "ApplicationServer,PlatformServer" and "2392107" ( do not include quotes)
  2. If the values do not match these, correct them to be the same
  3. Repair the CRM Installation
  4. Restart IIS The service should start successfully now.

1 comment:

Anonymous said...

Thanks! This solved my problem!