Pages

Friday 11 November 2011

My Experience Handling Event ID: 10830 issue


My Experience Handling Event ID: 10830 issue

Event Type:           Error
Event Source:       Health Service Modules
Event Category:   None
Event ID:                10830
Date:                      11/11/2011
Time:                      10:33:27 AM
User:                      N/A
Computer:             IND-APP142
Description:
An alert couldn't be inserted to the database. This could have happened because  of one of the following reasons:

                - Alert is stale. The alert is generated by an MP recently deleted.
                - Database connectivity problems or database running out of space.
                - Alert received is not valid.

 The following details should help to further diagnose:

 Details: RuleId:8654b44b-a532-3e3a-19be-1d4a66e9f790. HealthServiceId:e840b3ad-86d3-d373-1970-4c8b39f171c2. The INSERT statement conflicted with the FOREIGN KEY constraint "FK_Alert_BaseManagedEntity". The conflict occurred in database "OperationsManager", table "dbo.BaseManagedEntity", column 'BaseManagedEntityId'.
The statement has been terminated.RuleId:8654b44b-a532-3e3a-19be-1d4a66e9f790. HealthServiceId:e840b3ad-86d3-d373-1970-4c8b39f171c2. The INSERT statement conflicted with the FOREIGN KEY constraint "FK_Alert_BaseManagedEntity". The conflict occurred in database "OperationsManager", table "dbo.BaseManagedEntity", column 'BaseManagedEntityId'.
The statement has been terminated..


To display which Agent is sending the Stale Data use the below commandlet

get-monitoringobject -id < HealthServiceId>
Ex: get-monitoringobject -id e840b3ad-86d3-d373-1970-4c8b39f171c2

This will display the agent name which is causing the issue. Follow the below steps to resolve the issue.

1.     Login to the effected server
2.     Stop the System Center Management Service
4.     Start the System Center Management service.

My Experience Handling Event ID: 31552 issue


My Experience Handling Event ID: 31552 issue

We have observed below two flavors of Event ID’s. I have worked with PSS support team around 3 months to fix this issue.  Belo w are the Event Details


Event Type:           Error
Event Source:       Health Service Modules
Event Category:   Data Warehouse
Event ID:                31552
Date:                      6/28/2011
Time:                      9:16:46 AM
User:                      N/A
Computer:             IND-APP142
Description:
Failed to store data in the Data Warehouse.
Exception 'SqlException': Timeout expired.  The timeout period elapsed prior to completion of the operation or the server is not responding.
One or more workflows were affected by this. 
Workflow name: Microsoft.SystemCenter.DataWarehouse.StandardDataSetMaintenance
Instance name: State data set
Instance ID: {0AD76E64-3116-AE30-BCF0-740C26A1863C}
Management group: MG_IND
For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.
-----------------------------------------------------------------------------------------------------------------------------------------------------------
Event Type:           Error
Event Source:       Health Service Modules
Event Category:   Data Warehouse
Event ID:                31552
Date:                      6/24/2011
Time:                      5:37:48 AM
User:                      N/A
Computer:             IND-APP142
Description:
Failed to store data in the Data Warehouse.
Exception 'SqlException': Timeout expired.  The timeout period elapsed prior to completion of the operation or the server is not responding.
One or more workflows were affected by this. 
Workflow name: Microsoft.SystemCenter.DataWarehouse.Synchronization.Configuration
Instance name: tac-app142.prod.ds.russell.com
Instance ID: {024F88C7-F71B-9221-D650-8D988DB4901B}
Management group: MG_IND
For more information, see Help and Support Center at http://go.microsoft.com/fwlink/events.asp.


The first event (Instance name: State data set) we have fixed with the below steps.

Query to display the Dirty Ind’s

Declare @DataSet as uniqueidentifier
Set @DataSet = (Select datasetid from standarddataset where schemaname = 'State')

Select Count(*) from StandardDataSetAggregationHistory
where DataSetId = @DataSet
And DirtyInd = 1
----------------------------------------------------------------------------------------------------------------------------------

Query to clear the Dirty Ind’s
declare @i int
set @i=0
DECLARE @DataSet uniqueidentifier
SET @DataSet = (SELECT DatasetId FROM StandardDataset WHERE SchemaName = 'State')
while(@i<=500)
begin
EXEC standarddatasetmaintenance @DataSet
set @i=@i+1
Waitfor delay '00:00:05'
end
---------------------------------------------------------------------------------------------------------------------------

Second 31552 event was due to we are using SQL 2005 standard version and Online Indexing was failing every hour. This which captured using SQL profiler tool.


Thursday 27 October 2011

Custom Monitoring to check Folder exist using VB script for SCOM

Custom Monitoring to check Folder exist using VB script
Steps to create the new Class
1.     Open the Authoring Console
2.     Select  Service Model
3.     Click on Class New - Select Windows Server Role
4.      Provide the ID, Display name and description (Ex: ID: BizTalk.AppServer.Class and Display name: BizTalk Application Server Class and Description


5.     Click on Finish

Steps to create the new Discovery
1.     Select Health Model
2.     Click on Discoveries - Expand the class name  
3.     Enter the Element ID:, Display Name, Description, Target and Category as below
a.     Element ID: BizTalk.AppServer.Discovery
b.    Display Name: BizTalk Application server Discovery
c.     Target:Microsoft.Windows.Computer
d.    Category:Discovery

4.     Configure your schedule screen enter the discovery interval and click on Next

5.     Find the target computer’s name don’t change anything click on Next

6.     On the Registry Probe Configuration click on Add Change the Object Type to Value and enter the Properties as below
a.     Name: ServerRole
b.    Path: SOFTWARE\SCOM\BizTalk\ServerRole
c.     Attribute Type:String

7.     On the Build event Expression  click on Insert and Enter the below Values
a.     Parameter Name: values/ServerRole
b.    Operator:Equals
c.     Value: BiztalkApp

8.     On the Discovery Mapper select the below values
a.     Class ID:Biztalk.AppServer
b.    Key Properties select the Principle name
c.     Click on Finish



Steps to create the monitor
1.     Select Health Model
2.     Click on Monitors - New  -  Scripting  - Two State
3.     Specify the Element ID, Display Name, Description, Target, Parent Monitor and Category as below
a.     Element ID: FolderCheckMonitor
b.    Display Name: FolderCheckMonitor
c.     Target:BizTalk. AppServer
d.    Parent Monitor: System.health.AvailabilityState
e.     Category: AvailabilityHealth


4.     Configure your schedule screen specify the interval

5.     Enter script information page specify the File Name, timeout and script


Dim Fname,FSO,x,Problem,oArgs,oAPI
Dim sfolder, folder, files, sfile, sfilePart1, ScriptExitTime, strMessage,FileModTime,ChkOtherFIle,FinalIDD
On Error Resume Next
Problem=0
Set oAPI = CreateObject("MOM.ScriptAPI")
Set FSO= CreateObject("Scripting.FileSystemObject")
Set oArgs = WScript.Arguments
'Collect data from the arguments
sfolder = oArgs(0)
sfolder = “Location of the Folder"
'Check the folder existence...
If (fso.FolderExists(sFolder)) Then
             Problem = 0
             wscript.quit
Else
                Problem = 1
End If

if Problem = 0 Then
                Set propertyBag = oAPI.CreatePropertyBag ()
                Call propertyBag.AddValue ("Status", "Good")
Else
                Set propertyBag = oAPI.CreatePropertyBag ()
                Call propertyBag.AddValue ("Status", "Error")
End if
Call oAPI.Return(propertyBag)

6.     Unhealthy Expression screen Enter the Parameter Name Operator and Value as below
a.     Parameter Name: Property[@Name='Status']
b.    Operator: Equals
c.     Value: Error

7.     Healthy Expression screen Enter the Parameter Name Operator and Value as below
a.     Parameter Name: Property[@Name='Status']
b.    Operator: Equals
c.     Value: Good

8.     Click on Finish