You can create a compute policy and check the compliance status of the policy for a
specific virtual machine.
Procedure
-
Retrieve the object ID of a
virtual machine.
-
Retrieve the object ID of the
host you want the virtual machine to run on.
Note: The host should be
different from the host the virtual machine is already running on.
-
Tag the virtual machine.
For example, use the tag-1 tag.
-
Tag the host.
For example, use the tag-2 tag.
-
Create a compute policy.
For example, use the tag-1 and tag-2
tags.
-
Check the compliance status of the policy on this virtual machine.
Note: The compliance status can
take up to 3 minutes to update.