list_virtual_machines

BackupGateway.Client.list_virtual_machines(**kwargs)

Lists your virtual machines.

See also: AWS API Documentation

Request Syntax

response = client.list_virtual_machines(
    HypervisorArn='string',
    MaxResults=123,
    NextToken='string'
)
Parameters
  • HypervisorArn (string) -- The Amazon Resource Name (ARN) of the hypervisor connected to your virtual machine.
  • MaxResults (integer) -- The maximum number of virtual machines to list.
  • NextToken (string) -- The next item following a partial list of returned resources. For example, if a request is made to return maxResults number of resources, NextToken allows you to return more items in your list starting at the location pointed to by the next token.
Return type

dict

Returns

Response Syntax

{
    'NextToken': 'string',
    'VirtualMachines': [
        {
            'HostName': 'string',
            'HypervisorId': 'string',
            'LastBackupDate': datetime(2015, 1, 1),
            'Name': 'string',
            'Path': 'string',
            'ResourceArn': 'string'
        },
    ]
}

Response Structure

  • (dict) --

    • NextToken (string) --

      The next item following a partial list of returned resources. For example, if a request is made to return maxResults number of resources, NextToken allows you to return more items in your list starting at the location pointed to by the next token.

    • VirtualMachines (list) --

      A list of your VirtualMachine objects, ordered by their Amazon Resource Names (ARNs).

      • (dict) --

        A virtual machine that is on a hypervisor.

        • HostName (string) --

          The host name of the virtual machine.

        • HypervisorId (string) --

          The ID of the virtual machine's hypervisor.

        • LastBackupDate (datetime) --

          The most recent date a virtual machine was backed up, in Unix format and UTC time.

        • Name (string) --

          The name of the virtual machine.

        • Path (string) --

          The path of the virtual machine.

        • ResourceArn (string) --

          The Amazon Resource Name (ARN) of the virtual machine. For example, arn:aws:backup-gateway:us-west-1:0000000000000:vm/vm-0000ABCDEFGIJKL .

Exceptions

  • BackupGateway.Client.exceptions.ValidationException
  • BackupGateway.Client.exceptions.InternalServerException
  • BackupGateway.Client.exceptions.ThrottlingException