“An object of type MonitoringClass” error when you work with a SCOM connector in the System Center Service Manager console

Applies to: System Center 2012 R2 Service ManagerSystem Center 2016 Service Manager

Symptoms


When you work with a System Center Operations Manager (SCOM) connector in the System Center Service Manager console, you receive an error message that resembles the following:

Note The <GUID> value that is reported will depend on the Management Pack that causes the problem.

Cause


In SCOM, it is not valid to have a NULL ImageCategory field in the Operations Manager ImageReference SQL table. The ImageCategory field should be defined by the Management Pack that added the reference.

Resolution


To resolve this problem, get an updated Management Pack that correctly defines the ImageCategory field. Or, remove from Operations Manager the Management Pack that is causing the problem. To determine which Management Pack is at fault, run the following SQL query against the Operations Manager SQL database:

SELECT [ImageReference].[ImageId], [ImageReference].[ReferenceId], [ImageReference].[ManagementPackId], [ImageReference].TimeAdded,  [ImageReference].LastModified, SUBSTRING([EnumType].EnumTypeName, 39, 100) AS ImageCategory, [MPElementView].[MPElementName],[ManagementPack].[ContentReadable]FROM dbo.ImageReferenceJOIN dbo.[Resource] on ([Resource].ResourceId = ImageReference.ImageId)LEFT JOIN dbo.[Category] ON [Category].CategoryTarget = [Resource].ResourceIdLEFT JOIN dbo.[EnumType] ON [EnumType].EnumTypeId = [Category].CategoryValueJOIN dbo.MPElementView ON (ImageReference.ReferenceId = MPElementView.MPElementId)INNER JOIN dbo.[ManagementPack] ON dbo.ManagementPack.ManagementPackId = [ImageReference].ManagementPackId AND dbo.ManagementPack.ContentReadable = 1WHERE dbo.[ImageReference].[ReferenceId] IN (select dbo.ManagedType.ManagedTypeId from dbo.ManagedType)and dbo.[Resource].ResourceType = 4order by ImageCategory


To find the Management Pack that has a NULL value for the ImageCategory field, substitute the Management Pack ID from the query results for the ########-####-####-####-############ placeholder in the following Select statement:

Select MPName, Version, MPKeyToken, ManagementPackId, IsSealed, isDeleted, TimeAdded from ManagementPackHistorywhere ManagementPackId = '########-####-####-####-############'