![]() |
The following steps describe how to remove an MPS.
1. Invoke AMT_ManagementPresenceRemoteSAP.Delete using the EPR returned when the MPS instance was created (see Add a Management Presence Server), or by using the following parameters:
Parameter | Value |
SystemCreationClassName | “CIM_ComputerSystem” |
SystemName | “Intel(R) AMT” |
CreationClassName | “AMT_ManagementPresenceRemoteSAP” |
Name | “AMT:Management Presence Server” [handle] Where [handle] is the number of the MPS, returned when adding the instance. |
|
First remove any policy associated with the MPS (see Remove a Remote Access Policy). If the MPS is associated with a policy it will not be deleted, and the return code will be “AccessDenied”. |
Click here for a snippet demonstrating this step
You can execute this snippet by inserting it into the execution template found here.
# $mpServerRef is an EPR to the AMT_ManagementPresenceRemoteSAP object created by the 'Add a Management Presence Server' use case.
$mpServerRef.Delete()
2. If the MPS could not be removed because it is associated with a policy, perform the following:
a. Enumerate the AMT_RemoteAccessPolicyAppliesToMPS association.
b. Examine the ManagedElement property, looking for a match with the Name property in the AMT_ManagementPresenceRemoteSAP instance defining the MPS.
c. For each matching instance, examine the PolicySet property to find the EPR of the policy to delete. Perform AMT_RemoteAccessPolicyRule.Delete to delete policy.
d. Repeat step 1 to delete the MPS.
Click here for a snippet demonstrating this step
You can execute this snippet by inserting it into the execution template found here.
$remoteAccessPolicyAppliesToMPSRef =$wsmanConnectionObject.NewReference("AMT_RemoteAccessPolicyAppliesToMPS")
# $mpServer is an EPR to the AMT_ManagementPresenceRemoteSAP object created by the 'Add a Management Presence Server' use case.
$remoteAccessPolicyAppliesToMPSRef.AddSelector("ManagedElement",$mpServerRef)
# Traverse to the AMT_RemoteAccessPolicyAppliesToMPS instances that are connected to the $mpServer.
foreach($remoteAccessPolicyAppliesToMPSItem in$remoteAccessPolicyAppliesToMPSRef.Enumerate("http://schemas.dmtf.org/wbem/wsman/1/wsman/SelectorFilter",$null))
{
$remoteAccessPolicyRuleRef =$remoteAccessPolicyAppliesToMPSItem.Object.GetProperty("PolicySet").Ref
$remoteAccessPolicyRuleRef.Delete()
}
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.
Copyright © 2006-2022, Intel Corporation. All rights reserved. |