MSCRMMonitoringRuntime and MSCRMKeyGenerator Issue

Posted in: Blog, MS CRM, MS CRM 2011, MS CRM 2013 |

No comments

INTRODUCTION

A CRM 2013 application has been running for more than a year and out of nowhere user can’t get into CRM from the browser.

Then upon checking the Event Viewer, they’re getting the following every 1-5 minutes:

==

The current active key (KeyType : CrmWRPCTokenKey) is expired.  This may indicate that a key is not being regenerated correctly.  Current Active Key : CrmKey(Id:c9643987-c39a-e411-80d6-005056ba6cbc, ScaleGroupId:00000000-0000-0000-0000-000000000000, KeyType:CrmWRPCTokenKey, Expired:True, ValidOn:01/13/2015 01:28:52, ExpiresOn:02/15/2015 01:28:52, CreatedOn:01/13/2015 01:28:52, CreatedBy:DOMAIN\PRODASYNC.  Key Setting : CrmKeySetting(Id:a25534e8-f95d-4885-9b90-91894176bba3, KeyType:CrmWRPCTokenKey, KeyLength:128, KeyGenerationInterval:720, KeyTimeToLive:792, CryptoTimeToLive:72, Algorithm:HMACSHA256, ArchiveLength:1, Enabled:True, ActiveKeys:[ScaleGroupId=00000000-0000-0000-0000-000000000000,ActiveKeyId=c9743987-c39a-e411-80d6-005056ba6cbc])

==

Monitoring runtime failed: Machine: CRM2013VM: Exception: The type initializer for ‘Microsoft.Crm.Monitoring.Engine.MonitoringRuntime’ threw an exception.
   at Microsoft.Crm.Monitoring.Engine.MonitoringRuntime.RetrieveServerRolesForMachine(String machineName)
   at Microsoft.Crm.Monitoring.Engine.MonitoringRuntime..ctor(TestFrequency testFrequency)

InnerException Type:System.TypeInitializationException
The type initializer for ‘Microsoft.Crm.Monitoring.MonitoringSettings’ threw an exception.
   at Microsoft.Crm.Monitoring.MonitoringSettings.get_MaxExecuteTestAttempts()
   at Microsoft.Crm.Monitoring.ResultTracker..ctor()
   at Microsoft.Crm.Monitoring.Engine.MonitoringRuntime..cctor()

InnerException Type:System.TypeInitializationException
Login failed for user ‘DOMAIN\ProdMonitoring’.
   at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, UInt32 waitForMultipleObjectsTimeout, Boolean allowCreate, Boolean onlyOneCheckConnection, DbConnectionOptions userOptions, DbConnectionInternal& connection)
   at System.Data.ProviderBase.DbConnectionPool.TryGetConnection(DbConnection owningObject, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal& connection)
   at System.Data.ProviderBase.DbConnectionFactory.TryGetConnection(DbConnection owningConnection, TaskCompletionSource`1 retry, DbConnectionOptions userOptions, DbConnectionInternal oldConnection, DbConnectionInternal& connection)
   at System.Data.ProviderBase.DbConnectionInternal.TryOpenConnectionInternal(DbConnection outerConnection, DbConnectionFactory connectionFactory, TaskCompletionSource`1 retry, DbConnectionOptions userOptions)
   at System.Data.SqlClient.SqlConnection.TryOpenInner(TaskCompletionSource`1 retry)
   at System.Data.SqlClient.SqlConnection.TryOpen(TaskCompletionSource`1 retry)
   at System.Data.SqlClient.SqlConnection.Open()
   at Microsoft.Crm.CrmDbConnection.GetCreateAndOpenConnection()
   at Microsoft.Crm.CrmDbConnection.Open()
   at Microsoft.Crm.SharedDatabase.DatabaseMetadata.LoadMetadataXmlFromDatabase(CrmDBConnectionType connectionType, String connectionString, Int32& maxBlobSize)
   at Microsoft.Crm.ConfigurationDatabase.ConfigurationMetadata.get_Cache()
   at Microsoft.Crm.SharedDatabase.DatabaseService.Initialize(String tableName)
   at Microsoft.Crm.SharedDatabase.DatabaseService.RetrieveInternal(String tableName, String[] columns, PropertyBag[] conditions, Nullable`1 top, IList`1 orderBy, IDictionary collectionToFill)
   at Microsoft.Crm.SharedDatabase.DatabaseService.Retrieve(String tableName, String[] columns, PropertyBag[] conditions)
   at Microsoft.Crm.ServerLocatorService.Retrieve(String tableName, String[] columns, PropertyBag[] conditions)
   at Microsoft.Crm.Monitoring.MonitoringSettings..cctor()

InnerException Type:System.Data.SqlClient.SqlException
.

==

RESOLUTION

I checked with the ICT Team to ensure that passwords for service accounts didn’t change nor they expire nor locked. Everything looked green from their side.

So what I did to resolve the issue was the following:

– Restart Microsoft Dynamics CRM Asynchronous Processing Service

– Restart Microsoft Dynamics CRM Asynchronous Processing Service (maintenance)

– Open command prompt and run the following:
C:\Program Files\Microsoft Dynamics CRM\tools\Microsoft.Crm.Tools.WRPCKeyRenewal.exe /R

– Restart Microsoft Dynamics CRM Monitoring Service

– IISRESET

And done. I no longer get any errors in Event Viewer and users can now access CRM again.

 

Hope this helps,

Tommy

 

 

Written by

A web solution expert who has passion in website technologies. Tommy has been in the web industry for more than 10 years. He started his career as a PHP developer and has now specialized in ASP.NET, SharePoint and MS CRM. During his career he has also been in many roles: system tester, business analyst, deployment and QA manager, team and practice leader and IT manager.

No Comments Yet.

Leave a Reply

You must be logged in to post a comment.

Our Services

We provides you the best Services in our themes.

  • Click on the link below to see a full list of clients which we have developed solutions and provided consultancy for.

    READ MORE

  • We are solution-centered and not application-centered.

    READ MORE

  • Being creative and having fun and yet still delivering a fantastic service is the center of our values.

    READ MORE

  • TFS Consulting Services guarantees delivery that is within budget and deadline or you engage us for free.

    READ MORE

Implementing IT does not have to be difficult.

As long as you have the right methodologies

We have heard a lot of complaints from our clients that IT a lot of the times give them headache. The issues range from over-budget implementation, server is too hard to maintain, application is not user friendly, features not complete and many others. If you have ever experienced similar situations, don’t worry. This is why TFS Consulting Services is here. We exist to help clients implementing a successful IT solution. We have various methodologies which we have proven working in delivering a successful IT implementation. Below is the list of some of our key service offerings:
  • Planning and Methodologies

    Implementing IT solution does not have to be difficult. TFS Consulting Services has a lot of resources on planning and methodologies that will ensure successful delivery of your IT solution. TFS Consulting Services has been around in the web industry for more than 10 years and has experienced all the successes and failures of various type of IT deployment.

    read more

  • Technical Resource

    Do you need a technical resource? TFS Consulting Services can also provide you with technical resource for developing ASP.NET (C# and VB.NET), SharePoint (2003, 2007, 2010, 2013) and MS CRM applications. Our resource is an Microsoft Certified Personnel (MVP) and Microsoft Certified Technology Specialist (MCTS) in all ASP.NET, SharePoint and CRM.

    read more

  • IT Consulting & Advice

    Make sure your IT implementation is robust and scalable. TFS Consulting Services can provide consulting and advice on industry’s best practice on various web-related areas such as website security, design and usability, application-specific (such as SharePoint)’s best practice, Search Engine Optimisation (SEO), coding standards and many others.

    read more

  • Solution Development

    Finally TFS Consulting Services provides you with solution development service. We mainly work with Microsoft technologies (ie. .NET and SQL Server), however we are also capable of developing with PHP and MySQL. If you ever need any business process automation, integration and solution development work,  we are the trusted expert you should go to.

    read more

For more detailed service offerings please visit our Solutions page.

Testimonials

  • I’m happy to recommend Tommy as a knowledgeable and diligent developer.

    Mike Stringfellow, Vivid Group
  • Tommy has a lot of great ideas that can be delivered into great products. It’s a pleasure working with him because he has a broad knowledge about available technologies out there and he knows what’s best for the client’s needs. He just knows how to work effectively and efficiently.

    Teddy Segoro, Student Edge
  • I’ve worked with Tommy over the past 6 months and have found his approach to development (especially SharePoint) absolutely outstanding. Tommy goes beyond the boundries of typical software development with his ability understand what a client requires and then build it into fully fledged software solution. Coupled with his professional “Best Practice” approach, you get Continue Reading

    Michael Bonham, DSC-IT

Contact us

Tommy Segoro
tommy@tfsconsulting.com.au
+61 404 457 754

   

© TFS Consulting Services 2024. All rights reserved.

www.incorporator.com.au