get-event-by-monitoring-object operation

The get-event-by-monitoring-object operation retrieves events associated with the specified monitoring object.

The following table describes the <items> XML and request elements for the get-event-by-monitoring-object operation:

Adapter request elements for the get-event-by-monitoring-object operation

Element

Definition

Required

<operation-name>

Specifies the operation name: get-event-by-monitoring-object

Yes

<command-request>

Specifies the parent element for the command elements

Yes

<timeout-secs>

Specifies the duration after which the operation times out

Default value: 60 seconds

No

<command-parameters>

Specifies the parent element for the command parameters

Yes

<monitoringobject>

Specifies the parent element for the <monitoringobject-id> element

Yes

<monitoringobject-id>

Specifies the globally unique identifier (GUID) of the monitoring object

Yes

The following figure illustrates a sample adapter request for the get-event-by-monitoring-object operation: 

Sample adapter request for the get-event-by-monitoring-object operation

<scom-request>
  <operation-name>get-event-by-monitoring-object</operation-name>
  <command-request>
    <timeout-secs>480</timeout-secs>
    <command-parameters>
      <monitoringobject>
        <monitoringobject-id>b9994504-06cd-a393-7a81-d450d9ce5a58</monitoringobject-id>
      </monitoringobject>
    </command-parameters>
  </command-request>
</scom-request>



The following figure illustrates the adapter response for the sample request: 

Sample adapter response for the get-event-by-monitoring-object operation

<scom-response>
  <metadata>
    <status>success</status>
    <count>1</count>
  </metadata>
  <commands-output>
    <command-output>
      <metadata>
        <command>./Microsoft.EnterpriseManagement.OperationsManager.ClientShell.
        Startup.ps1;get-event -monitoringobject (get-monitoringobject -id
         b9994504-06cd-a393-7a81-d450d9ce5a58)</command>
        <execution-milliseconds>134524</execution-milliseconds>
        <exit-code>0</exit-code>
        <status>success</status>
        <count>856</count>
      </metadata>
      <output>
        <item>
          <Id>76c56411-0095-4b5e-8b3e-658ff3219c6f</Id>
          <OriginalId>4de2473b-62e4-4f49-81e9-ea6cbfb876de</OriginalId>
          <MonitoringObjectId>b37fae0e-a654-3a8b-b6f1-139dbe05b573</MonitoringObjectId>
          <MonitoringClassId>66dd9b43-3dc1-3831-95d4-1b03b0a6ea13</MonitoringClassId>
          <MonitoringObjectName />
          <MonitoringObjectDisplayName>Microsoft(R) Windows(R) Server 2003,
           Standard Edition</MonitoringObjectDisplayName>
          <MonitoringObjectPath>win2stdvm.neuron.com</MonitoringObjectPath>
          <MonitoringObjectFullName>Microsoft(R) Windows(R) Server 2003, Standard
           Edition</MonitoringObjectFullName>
          <MonitoringRuleId>4c646af6-6d03-8ef6-1cb7-1f2ebc05fd39</MonitoringRuleId>
          <MonitoringRuleDisplayName>Collection Rule for Windows Restarted
           Events</MonitoringRuleDisplayName>
          <MonitoringRuleDescription>This rule collects events indicating Windows
           has restarted</MonitoringRuleDescription>
          <PublisherName>EventLog</PublisherName>
          <Number>6005</Number>
          <Description>The Event log service was started.</Description>
          <CategoryId>0</CategoryId>
          <Category />
          <User>N/A</User>
          <Channel>System</Channel>
          <LevelId>4</LevelId>
          <Level />
          <LoggingComputer>WIN2STDVM</LoggingComputer>
          <EventData />
          <Parameters>{, , , ...}</Parameters>
          <TimeGenerated>2/23/2009 12:00:08 PM</TimeGenerated>
          <TimeAdded>2/23/2009 12:03:49 PM</TimeAdded>
          <ManagementGroup>M1</ManagementGroup>
          <ManagementGroupId>ae1fcf8a-8088-31d8-93ec-90fe77a32d44</ManagementGroupId>
        </item>
        ...
      </output>
    </command-output>
  </commands-output>
</scom-response>
Was this page helpful? Yes No Submitting... Thank you

Comments