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
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.
We are solution-centered and not application-centered.
Being creative and having fun and yet still delivering a fantastic service is the center of our values.
TFS Consulting Services guarantees delivery that is within budget and deadline or you engage us for free.
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.
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.
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.
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.
For more detailed service offerings please visit our Solutions page.
Tommy Segoro
tommy@tfsconsulting.com.au
+61 404 457 754
© TFS Consulting Services 2024. All rights reserved.