Virtual Machine Get Runtime

Virtual Machine Get Runtime

Execution state and history for this virtual machine.

The contents of this property change when:

  • the virtual machine's power state changes.
  • an execution message is pending.
  • an event occurs.
Request
URI
GET
https://{vcenter-host}/sdk/vim25/{release}/VirtualMachine/{moId}/runtime
COPY
Path Parameters
string
moId
Required

The unique identifier for the managed object to which the property attaches; the serialized managed object reference for a request has the form moType/moId, in this case VirtualMachine/{moId}.

string
release
Required

The vSphere release schema. The current specification covers vSphere 8.0.2.0 APIs.


Authentication
This operation uses the following authentication methods.
Responses
200

OK

Returns VirtualMachineRuntimeInfo of type(s) application/json
This response body class contains all of the following: DataObject
{
    "_typeName": "string",
    "device": [
        {
            "_typeName": "string",
            "runtimeState": {
                "_typeName": "string"
            },
            "key": 0
        }
    ],
    "host": {
        "_typeName": "string",
        "type": "string",
        "value": "string"
    },
    "connectionState": "string",
    "powerState": "string",
    "vmFailoverInProgress": false,
    "faultToleranceState": "string",
    "dasVmProtection": {
        "_typeName": "string",
        "dasProtected": false
    },
    "toolsInstallerMounted": false,
    "suspendTime": "string",
    "bootTime": "string",
    "suspendInterval": 0,
    "question": {
        "_typeName": "string",
        "id": "string",
        "text": "string",
        "choice": {
            "_typeName": "string",
            "valueIsReadonly": false,
            "choiceInfo": [
                {
                    "_typeName": "string",
                    "label": "string",
                    "summary": "string",
                    "key": "string"
                }
            ],
            "defaultIndex": 0
        },
        "message": [
            {
                "_typeName": "string",
                "id": "string",
                "argument": [
                    {
                        "_typeName": "string"
                    }
                ],
                "text": "string"
            }
        ]
    },
    "memoryOverhead": 0,
    "maxCpuUsage": 0,
    "maxMemoryUsage": 0,
    "numMksConnections": 0,
    "recordReplayState": "string",
    "cleanPowerOff": false,
    "needSecondaryReason": "string",
    "onlineStandby": false,
    "minRequiredEVCModeKey": "string",
    "consolidationNeeded": false,
    "offlineFeatureRequirement": [
        {
            "_typeName": "string",
            "key": "string",
            "featureName": "string",
            "value": "string"
        }
    ],
    "featureRequirement": [
        {
            "_typeName": "string",
            "key": "string",
            "featureName": "string",
            "value": "string"
        }
    ],
    "featureMask": [
        {
            "_typeName": "string",
            "key": "string",
            "featureName": "string",
            "value": "string"
        }
    ],
    "vFlashCacheAllocation": 0,
    "paused": false,
    "snapshotInBackground": false,
    "quiescedForkParent": false,
    "instantCloneFrozen": false,
    "cryptoState": "string",
    "suspendedToMemory": false,
    "opNotificationTimeout": 0,
    "iommuActive": false
}
device
Optional

Per-device runtime info.

This array will be empty if the host software does not provide runtime info for any of the device types currently in use by the virtual machine. In releases after vSphere API 5.0, vSphere Servers might not generate property collector update notifications for this property. To obtain the latest value of the property, you can use PropertyCollector methods RetrievePropertiesEx or WaitForUpdatesEx. If you use the PropertyCollector.WaitForUpdatesEx method, specify an empty string for the version parameter. Since this property is on a DataObject, an update returned by WaitForUpdatesEx may contain values for this property when some other property on the DataObject changes. If this update is a result of a call to WaitForUpdatesEx with a non-empty version parameter, the value for this property may not be current.

host
Optional

Reference to an instance of the HostSystem managed object.

connectionState
Required

The connectivity state of a virtual machine.

When the API is provided directly by a server product, such as ESX Server, then the disconnected state is not possible. However, when accessed through VirtualCenter, the state of a virtual machine is set to disconnected if the hosts that manage the virtual machine becomes unavailable.

Possible values:

  • connected: The server has access to the virtual machine.

  • disconnected: The server is currently disconnected from the virtual machine, since its host is disconnected.

    See general comment for this enumerated type for more details.

  • orphaned: The virtual machine is no longer registered on the host it is associated with.

    For example, a virtual machine that is unregistered or deleted directly on a host managed by VirtualCenter shows up in this state.

  • inaccessible: One or more of the virtual machine configuration files are inaccessible.

    For example, this can be due to transient disk failures. In this case, no configuration can be returned for a virtual machine.

  • invalid: The virtual machine configuration format is invalid.

    Thus, it is accessible on disk, but corrupted in a way that does not allow the server to read the content. In this case, no configuration can be returned for a virtual machine.

Possible values are : connected, disconnected, orphaned, inaccessible, invalid,
powerState
Required

The PowerState type defines a simple set of states for a virtual machine: poweredOn, poweredOff, and suspended.

This type does not model substates, such as when a task is running to change the virtual machine state. If the virtual machine is in a state with a task in progress, it transitions to a new state when the task completes. For example, a virtual machine continues to be in the poweredOn state while a suspend task is running, and changes to the suspended state once the task finishes.

As a consequence of this approach, clients interested in monitoring the status of a virtual machine should typically track the activeTask data object in addition to the powerState object.

Possible values:

  • poweredOff: The virtual machine is currently powered off.
  • poweredOn: The virtual machine is currently powered on.
  • suspended: The virtual machine is currently suspended.
Possible values are : poweredOff, poweredOn, suspended,
boolean
vmFailoverInProgress
Optional

Represents if the vm is currently being failed over by FDM

Since: vSphere API Release 7.0.2.0

faultToleranceState
Required

The FaultToleranceState type defines a simple set of states for a fault tolerant virtual machine: disabled, starting, and enabled.

Possible values:

  • notConfigured: This state indicates that the virtual machine has not been configured for fault tolerance.

  • disabled: For a virtual machine that is the primary in a fault tolerant group, this state indicates that the virtual machine has at least one registered secondary, but no secondary is enabled.

    For a virtual machine that is the secondary in a fault tolerant group, this state indicates that the secondary is disabled.

  • enabled: For a virtual machine that is the primary in a fault tolerant group, this state indicates that the virtual machine is not currently powered on, but has at least one enabled secondary For a virtual machine that is the secondary in a fault tolerant group, this state indicates that the secondary is enabled, but is not currently powered on.

  • needSecondary: For a virtual machine that is the primary in a fault tolerant group, this state indicates that the virtual machine is powered on and has at least one enabled secondary, but no secondary is currently active.

    This state is not valid for a virtual machine that is a secondary in a fault tolerant group.

  • starting: For a virtual machine that is the primary in a fault tolerant group, this state indicates that the virtual machine is powered on and has at least one secondary that is synchronizing its state with the primary.

    For a virtual machine that is the secondary in a fault tolerant group, this state indicates that the secondary is powered on and is synchronizing its state with the primary virtual machine.

  • running: This state indicates that the virtual machine is running with fault tolerance protection.

Possible values are : notConfigured, disabled, enabled, needSecondary, starting, running,
dasVmProtection
Optional

The VirtualMachineRuntimeInfoDasProtectionState object describes the vSphere HA protection state of a virtual machine (VM).

boolean
toolsInstallerMounted
Required

Flag to indicate whether or not the VMware Tools installer is mounted as a CD-ROM.

string As date-time As date-time
suspendTime
Optional

The timestamp when the virtual machine was most recently suspended.

This property is updated every time the virtual machine is suspended.

string As date-time As date-time
bootTime
Optional

The timestamp when the virtual machine was most recently powered on.

This property is updated when the virtual machine is powered on from the poweredOff state, and is cleared when the virtual machine is powered off. This property is not updated when a virtual machine is resumed from a suspended state.

integer As int64 As int64
suspendInterval
Optional

The total time the virtual machine has been suspended since it was initially powered on.

This time excludes the current period, if the virtual machine is currently suspended. This property is updated when the virtual machine resumes, and is reset to zero when the virtual machine is powered off.

question
Optional

This data object type describes the question that is currently blocking a virtual machine.

integer As int64 As int64
memoryOverhead
Optional

Deprecated as of vSphere API 4.1, use the PerformanceManager memory overhead counter to get this value.

The amount of memory resource (in bytes) that will be used by the virtual machine above its guest memory requirements.

This value is set if and only if the virtual machine is registered on a host that supports memory resource allocation features.

For powered off VMs, this is the minimum overhead required to power on the VM on the registered host.

For powered on VMs, this is the current overhead reservation, a value which is almost always larger than the minimum overhead, and which grows with time.

See also HostSystem.QueryMemoryOverheadEx.

integer As int32 As int32
maxCpuUsage
Optional

Current upper-bound on CPU usage.

The upper-bound is based on the host the virtual machine is current running on, as well as limits configured on the virtual machine itself or any parent resource pool. Valid while the virtual machine is running. In releases after vSphere API 5.0, vSphere Servers might not generate property collector update notifications for this property. To obtain the latest value of the property, you can use PropertyCollector methods RetrievePropertiesEx or WaitForUpdatesEx. If you use the PropertyCollector.WaitForUpdatesEx method, specify an empty string for the version parameter. Since this property is on a DataObject, an update returned by WaitForUpdatesEx may contain values for this property when some other property on the DataObject changes. If this update is a result of a call to WaitForUpdatesEx with a non-empty version parameter, the value for this property may not be current.

integer As int32 As int32
maxMemoryUsage
Optional

Current upper-bound on memory usage.

The upper-bound is based on memory configuration of the virtual machine, as well as limits configured on the virtual machine itself or any parent resource pool. Valid while the virtual machine is running. In releases after vSphere API 5.0, vSphere Servers might not generate property collector update notifications for this property. To obtain the latest value of the property, you can use PropertyCollector methods RetrievePropertiesEx or WaitForUpdatesEx. If you use the PropertyCollector.WaitForUpdatesEx method, specify an empty string for the version parameter. Since this property is on a DataObject, an update returned by WaitForUpdatesEx may contain values for this property when some other property on the DataObject changes. If this update is a result of a call to WaitForUpdatesEx with a non-empty version parameter, the value for this property may not be current.

integer As int32 As int32
numMksConnections
Required

Number of active MKS connections to this virtual machine.

recordReplayState
Required

Deprecated as of vSphere API 6.0.

The RecordReplayState type defines a simple set of record and replay states for a virtual machine.

Possible values:

  • recording: The virtual machine is recording.
  • replaying: The virtual machine is replaying.
  • inactive: The virtual machine is currently not participating in record or replay.
Possible values are : recording, replaying, inactive,
boolean
cleanPowerOff
Optional

For a powered off virtual machine, indicates whether the virtual machine's last shutdown was an orderly power off or not.

Unset if the virtual machine is running or suspended.

string
needSecondaryReason
Optional

If set, indicates the reason the virtual machine needs a secondary.

boolean
onlineStandby
Required

This property indicates whether the guest has gone into one of the s1, s2 or s3 standby modes, false indicates the guest is awake.

string
minRequiredEVCModeKey
Optional

For a powered-on or suspended virtual machine in a cluster with Enhanced VMotion Compatibility (EVC) enabled, this identifies the least-featured EVC mode (among those for the appropriate CPU vendor) that could admit the virtual machine.

See EVCMode. Until vSphere 6.5, this property will be unset if the virtual machine is powered off or is not in an EVC cluster.

This property may be used as a general indicator of the CPU feature baseline currently in use by the virtual machine. However, the virtual machine may be suppressing some of the features present in the CPU feature baseline of the indicated mode, either explicitly (in the virtual machine's configured cpuFeatureMask) or implicitly (in the default masks for the GuestOsDescriptor appropriate for the virtual machine's configured guest OS).

boolean
consolidationNeeded
Required

Whether any disk of the virtual machine requires consolidation.

This can happen for example when a snapshot is deleted but its associated disk is not committed back to the base disk. Use VirtualMachine.ConsolidateVMDisks_Task to consolidate if needed.

offlineFeatureRequirement
Optional

These requirements must have equivalent host capabilities HostConfigInfo.featureCapability in order to power on.

featureRequirement
Optional

These requirements must have equivalent host capabilities HostConfigInfo.featureCapability in order to power on, resume, or migrate to the host.

featureMask
Optional

The masks applied to an individual virtual machine as a result of its configuration.

integer As int64 As int64
vFlashCacheAllocation
Optional

Deprecated since vSphere 7.0 because vFlash Read Cache end of availability.

Specifies the total allocated vFlash resource for the vFlash caches associated with VM's VMDKs when VM is powered on, in bytes.

boolean
paused
Optional

Whether the virtual machine is paused, or not.

boolean
snapshotInBackground
Optional

Whether a snapshot operation is in progress in the background, or not.

boolean
quiescedForkParent
Optional

This flag indicates whether a parent virtual machine is in a fork ready state.

A persistent instant clone child can be created only when this flag is true. While a non-persistent instant clone child can be created independent of this flag, it can only be powered on if this flag is true.

boolean
instantCloneFrozen
Optional

Whether the virtual machine is frozen for instant clone, or not.

string
cryptoState
Optional

Encryption state of the virtual machine.

Valid values are enumerated by the CryptoState type.

boolean
suspendedToMemory
Optional

Whether the virtual machine is suspended to memory, or not.

Since: vSphere API Release 7.0.2.0

integer As int64 As int64
opNotificationTimeout
Optional

Operation notification timeout in seconds.

Specifies the maximum time duration the application may take to prepare for the operation after it has been notified. This property is set only for powered on VMs.

Since: vSphere API Release 8.0.0.1

boolean
iommuActive
Optional

Indicates whether there is active IOMMU domain in the current VM.

Since: vSphere API Release 8.0.1.0


Virtual Machine Operations
POST
Virtual Machine Acquire Mks Ticket
POST
Virtual Machine Acquire Ticket
POST
Virtual Machine Answer VM
POST
Virtual Machine Apply Evc Mode VM Task
POST
Virtual Machine Attach Disk Task
POST
Virtual Machine Check Customization Spec
POST
Virtual Machine Clone VM Task
POST
Virtual Machine Consolidate VM Disks Task
POST
Virtual Machine Create Screenshot Task
POST
Virtual Machine Create Secondary VM Task
POST
Virtual Machine Create Secondary VM Ex Task
POST
Virtual Machine Create Snapshot Task
POST
Virtual Machine Create Snapshot Ex Task
POST
Virtual Machine Crypto Unlock Task
POST
Virtual Machine Customize VM Task
POST
Virtual Machine Defragment All Disks
POST
Virtual Machine Destroy Task
POST
Virtual Machine Detach Disk Task
POST
Virtual Machine Disable Secondary VM Task
POST
Virtual Machine Drop Connections
POST
Virtual Machine Enable Secondary VM Task
POST
Virtual Machine Estimate Storage For Consolidate Snapshots Task
POST
Virtual Machine Export Vm
POST
Virtual Machine Extract Ovf Environment
GET
Virtual Machine Get Alarm Actions Enabled
GET
Virtual Machine Get Available Field
GET
Virtual Machine Get Capability
GET
Virtual Machine Get Config
GET
Virtual Machine Get Config Issue
GET
Virtual Machine Get Config Status
GET
Virtual Machine Get Custom Value
GET
Virtual Machine Get Datastore
GET
Virtual Machine Get Declared Alarm State
GET
Virtual Machine Get Disabled Method
GET
Virtual Machine Get Effective Role
GET
Virtual Machine Get Environment Browser
GET
Virtual Machine Get Guest
GET
Virtual Machine Get Guest Heartbeat Status
GET
Virtual Machine Get Layout
GET
Virtual Machine Get Layout Ex
GET
Virtual Machine Get Name
GET
Virtual Machine Get Network
GET
Virtual Machine Get Overall Status
GET
Virtual Machine Get Parent
GET
Virtual Machine Get Parent V App
GET
Virtual Machine Get Permission
GET
Virtual Machine Get Recent Task
GET
Virtual Machine Get Resource Config
GET
Virtual Machine Get Resource Pool
GET
Virtual Machine Get Root Snapshot
GET
Virtual Machine Get Runtime
GET
Virtual Machine Get Snapshot
GET
Virtual Machine Get Storage
GET
Virtual Machine Get Summary
GET
Virtual Machine Get Tag
GET
Virtual Machine Get Triggered Alarm State
GET
Virtual Machine Get Value
POST
Virtual Machine Instant Clone Task
POST
Virtual Machine Make Primary VM Task
POST
Virtual Machine Mark As Template
POST
Virtual Machine Mark As Virtual Machine
POST
Virtual Machine Migrate VM Task
POST
Virtual Machine Mount Tools Installer
POST
Virtual Machine Power Off VM Task
POST
Virtual Machine Power On VM Task
POST
Virtual Machine Promote Disks Task
POST
Virtual Machine Put Usb Scan Codes
POST
Virtual Machine Query Changed Disk Areas
POST
Virtual Machine Query Connections
POST
Virtual Machine Query Fault Tolerance Compatibility
POST
Virtual Machine Query Fault Tolerance Compatibility Ex
POST
Virtual Machine Query Unowned Files
POST
Virtual Machine Reboot Guest
POST
Virtual Machine Reconfig VM Task
POST
Virtual Machine Refresh Storage Info
POST
Virtual Machine Reload
POST
Virtual Machine Reload Virtual Machine From Path Task
POST
Virtual Machine Relocate VM Task
POST
Virtual Machine Remove All Snapshots Task
POST
Virtual Machine Rename Task
POST
Virtual Machine Reset Guest Information
POST
Virtual Machine Reset VM Task
POST
Virtual Machine Revert To Current Snapshot Task
POST
Virtual Machine Send NMI
POST
Virtual Machine Set Custom Value
POST
Virtual Machine Set Display Topology
POST
Virtual Machine Set Screen Resolution
POST
Virtual Machine Shutdown Guest
POST
Virtual Machine Standby Guest
POST
Virtual Machine Start Recording Task
POST
Virtual Machine Start Replaying Task
POST
Virtual Machine Stop Recording Task
POST
Virtual Machine Stop Replaying Task
POST
Virtual Machine Suspend VM Task
POST
Virtual Machine Terminate Fault Tolerant VM Task
POST
Virtual Machine Terminate VM
POST
Virtual Machine Turn Off Fault Tolerance For VM Task
POST
Virtual Machine Unmount Tools Installer
POST
Virtual Machine Unregister VM
POST
Virtual Machine Upgrade Tools Task
POST
Virtual Machine Upgrade VM Task