Intel AMT Features > Agent Presence > Use Cases > Set an Agent Watchdog's Actions
CollapseAll image

Set an Agent Watchdog's Actions

The following steps describe how to set the actions of an agent watchdog.

1.  Retrieve the instance of AMT_AgentPresenceWatchdog with the DeviceID used to define the agent (See Create an Agent Watchdog).

 Note:

The DeviceID is the ID of the Agent watchdog in Base64 format.

2.  Invoke AMT_AgentPresenceWatchdog.AddAction, as shown in the following examples:

   To specify that an event will occur in response to any state transition:

Parameter

Value

OldState

31

NewState

31

EventOnTransition

True

   To specify that event System Defense and EAC actions will occur if the agent enters into an expired state:

Parameter

Value

OldState

31

NewState

8

EventOnTransition

True

ActionSd

1

ActionEAC

True

 

Click here for a snippet demonstrating this step

See the General Info Get Core Version use case for the GetCoreVersion function.

You can execute this snippet by inserting it into the execution template found here.

  

$deviceID =# The ID of the agent watchdog in Base64 format, provided by the caller when the AMT_AgentPresenceWatchdog was created.

$agentPresenceWatchdogRef =$wsmanConnectionObject.NewReference("SELECT * FROM AMT_AgentPresenceWatchdog WHERE DeviceID='" +$deviceID +"'")

$inputObject =$agentPresenceWatchdogRef.CreateMethodInput("AddAction")

$inputObject.SetProperty("OldState","31")

$inputObject.SetProperty("NewState","8")

$inputObject.SetProperty("EventOnTransition","true")

$inputObject.SetProperty("ActionSd","0")

$fwVersion = GetCoreVersion

if($fwVersion.ToString() -ge "4.0")

{

    $inputObject.SetProperty("ActionEac","true")

}

$outputObject =$agentPresenceWatchdogRef.InvokeMethod($inputObject)

$returnValue =$outputObject.GetProperty("ReturnValue")

 

 

 

 Note:

   The OldState and NewState parameters can be set to a computed logical OR value of the watchdog states. The value of 31 in these examples is the logical OR value of all the states (1+2+4+8+16=31).

   The ActionEAC parameter is supported only by Intel AMT Release 4.0 and later.

 

Additional Information

The AMT_AgentPresenceWatchdog.AddAction() method creates an AMT_StateTransitionCondition instance associated to the AMT_AgentPresenceWatchdog  using a newly created association class CIM_ConcreteDependency. In addition, an AMT_AgentPresenceWatchdogAction instance is created and associated to the AMT_StateTransitionCondition using another newly created association class CIM_ConcreteDependency.

Instance Diagram

Classes Used in This Flow

SDK Sample

If there is a sample demonstrating this flow, it is included in the SDK installation file. See SDK Installation Layout for details.

 

See Also:

   Agent States

   Agent Watchdog Timers and Actions

Copyright © 2006-2022, Intel Corporation. All rights reserved.