VirtualMachines interface
Interface representing a VirtualMachines.
Methods
begin |
Assess patches on the VM. |
begin |
Assess patches on the VM. |
begin |
Attach and detach data disks to/from the virtual machine. |
begin |
Attach and detach data disks to/from the virtual machine. |
begin |
Captures the VM by copying virtual hard disks of the VM and outputs a template that can be used to create similar VMs. |
begin |
Captures the VM by copying virtual hard disks of the VM and outputs a template that can be used to create similar VMs. |
begin |
Converts virtual machine disks from blob-based to managed disks. Virtual machine must be stop-deallocated before invoking this operation. |
begin |
Converts virtual machine disks from blob-based to managed disks. Virtual machine must be stop-deallocated before invoking this operation. |
begin |
The operation to create or update a virtual machine. Please note some properties can be set only during virtual machine creation. |
begin |
The operation to create or update a virtual machine. Please note some properties can be set only during virtual machine creation. |
begin |
Shuts down the virtual machine and releases the compute resources. You are not billed for the compute resources that this virtual machine uses. |
begin |
Shuts down the virtual machine and releases the compute resources. You are not billed for the compute resources that this virtual machine uses. |
begin |
The operation to delete a virtual machine. |
begin |
The operation to delete a virtual machine. |
begin |
Installs patches on the VM. |
begin |
Installs patches on the VM. |
begin |
The operation to perform maintenance on a virtual machine. |
begin |
The operation to perform maintenance on a virtual machine. |
begin |
The operation to power off (stop) a virtual machine. The virtual machine can be restarted with the same provisioned resources. You are still charged for this virtual machine. |
begin |
The operation to power off (stop) a virtual machine. The virtual machine can be restarted with the same provisioned resources. You are still charged for this virtual machine. |
begin |
The operation to reapply a virtual machine's state. |
begin |
The operation to reapply a virtual machine's state. |
begin |
Shuts down the virtual machine, moves it to a new node, and powers it back on. |
begin |
Shuts down the virtual machine, moves it to a new node, and powers it back on. |
begin |
Reimages (upgrade the operating system) a virtual machine which don't have a ephemeral OS disk, for virtual machines who have a ephemeral OS disk the virtual machine is reset to initial state. NOTE: The retaining of old OS disk depends on the value of deleteOption of OS disk. If deleteOption is detach, the old OS disk will be preserved after reimage. If deleteOption is delete, the old OS disk will be deleted after reimage. The deleteOption of the OS disk should be updated accordingly before performing the reimage. |
begin |
Reimages (upgrade the operating system) a virtual machine which don't have a ephemeral OS disk, for virtual machines who have a ephemeral OS disk the virtual machine is reset to initial state. NOTE: The retaining of old OS disk depends on the value of deleteOption of OS disk. If deleteOption is detach, the old OS disk will be preserved after reimage. If deleteOption is delete, the old OS disk will be deleted after reimage. The deleteOption of the OS disk should be updated accordingly before performing the reimage. |
begin |
The operation to restart a virtual machine. |
begin |
The operation to restart a virtual machine. |
begin |
Run command on the VM. |
begin |
Run command on the VM. |
begin |
The operation to start a virtual machine. |
begin |
The operation to start a virtual machine. |
begin |
The operation to update a virtual machine. |
begin |
The operation to update a virtual machine. |
generalize(string, string, Virtual |
Sets the OS state of the virtual machine to generalized. It is recommended to sysprep the virtual machine before performing this operation. For Windows, please refer to Create a managed image of a generalized VM in Azure. For Linux, please refer to How to create an image of a virtual machine or VHD. |
get(string, string, Virtual |
Retrieves information about the model view or the instance view of a virtual machine. |
instance |
Retrieves information about the run-time state of a virtual machine. |
list(string, Virtual |
Lists all of the virtual machines in the specified resource group. Use the nextLink property in the response to get the next page of virtual machines. |
list |
Lists all of the virtual machines in the specified subscription. Use the nextLink property in the response to get the next page of virtual machines. |
list |
Lists all available virtual machine sizes to which the specified virtual machine can be resized. |
list |
Gets all the virtual machines under the specified subscription for the specified location. |
retrieve |
The operation to retrieve SAS URIs for a virtual machine's boot diagnostic logs. |
simulate |
The operation to simulate the eviction of spot virtual machine. |
Method Details
beginAssessPatches(string, string, VirtualMachinesAssessPatchesOptionalParams)
Assess patches on the VM.
function beginAssessPatches(resourceGroupName: string, vmName: string, options?: VirtualMachinesAssessPatchesOptionalParams): Promise<SimplePollerLike<OperationState<VirtualMachineAssessPatchesResult>, VirtualMachineAssessPatchesResult>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<VirtualMachineAssessPatchesResult>, VirtualMachineAssessPatchesResult>>
beginAssessPatchesAndWait(string, string, VirtualMachinesAssessPatchesOptionalParams)
Assess patches on the VM.
function beginAssessPatchesAndWait(resourceGroupName: string, vmName: string, options?: VirtualMachinesAssessPatchesOptionalParams): Promise<VirtualMachineAssessPatchesResult>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<VirtualMachineAssessPatchesResult>
beginAttachDetachDataDisks(string, string, AttachDetachDataDisksRequest, VirtualMachinesAttachDetachDataDisksOptionalParams)
Attach and detach data disks to/from the virtual machine.
function beginAttachDetachDataDisks(resourceGroupName: string, vmName: string, parameters: AttachDetachDataDisksRequest, options?: VirtualMachinesAttachDetachDataDisksOptionalParams): Promise<SimplePollerLike<OperationState<StorageProfile>, StorageProfile>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
- parameters
- AttachDetachDataDisksRequest
Parameters supplied to the attach and detach data disks operation on the virtual machine.
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<StorageProfile>, StorageProfile>>
beginAttachDetachDataDisksAndWait(string, string, AttachDetachDataDisksRequest, VirtualMachinesAttachDetachDataDisksOptionalParams)
Attach and detach data disks to/from the virtual machine.
function beginAttachDetachDataDisksAndWait(resourceGroupName: string, vmName: string, parameters: AttachDetachDataDisksRequest, options?: VirtualMachinesAttachDetachDataDisksOptionalParams): Promise<StorageProfile>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
- parameters
- AttachDetachDataDisksRequest
Parameters supplied to the attach and detach data disks operation on the virtual machine.
The options parameters.
Returns
Promise<StorageProfile>
beginCapture(string, string, VirtualMachineCaptureParameters, VirtualMachinesCaptureOptionalParams)
Captures the VM by copying virtual hard disks of the VM and outputs a template that can be used to create similar VMs.
function beginCapture(resourceGroupName: string, vmName: string, parameters: VirtualMachineCaptureParameters, options?: VirtualMachinesCaptureOptionalParams): Promise<SimplePollerLike<OperationState<VirtualMachineCaptureResult>, VirtualMachineCaptureResult>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
- parameters
- VirtualMachineCaptureParameters
Parameters supplied to the Capture Virtual Machine operation.
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<VirtualMachineCaptureResult>, VirtualMachineCaptureResult>>
beginCaptureAndWait(string, string, VirtualMachineCaptureParameters, VirtualMachinesCaptureOptionalParams)
Captures the VM by copying virtual hard disks of the VM and outputs a template that can be used to create similar VMs.
function beginCaptureAndWait(resourceGroupName: string, vmName: string, parameters: VirtualMachineCaptureParameters, options?: VirtualMachinesCaptureOptionalParams): Promise<VirtualMachineCaptureResult>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
- parameters
- VirtualMachineCaptureParameters
Parameters supplied to the Capture Virtual Machine operation.
The options parameters.
Returns
Promise<VirtualMachineCaptureResult>
beginConvertToManagedDisks(string, string, VirtualMachinesConvertToManagedDisksOptionalParams)
Converts virtual machine disks from blob-based to managed disks. Virtual machine must be stop-deallocated before invoking this operation.
function beginConvertToManagedDisks(resourceGroupName: string, vmName: string, options?: VirtualMachinesConvertToManagedDisksOptionalParams): Promise<SimplePollerLike<OperationState<void>, void>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<void>, void>>
beginConvertToManagedDisksAndWait(string, string, VirtualMachinesConvertToManagedDisksOptionalParams)
Converts virtual machine disks from blob-based to managed disks. Virtual machine must be stop-deallocated before invoking this operation.
function beginConvertToManagedDisksAndWait(resourceGroupName: string, vmName: string, options?: VirtualMachinesConvertToManagedDisksOptionalParams): Promise<void>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<void>
beginCreateOrUpdate(string, string, VirtualMachine, VirtualMachinesCreateOrUpdateOptionalParams)
The operation to create or update a virtual machine. Please note some properties can be set only during virtual machine creation.
function beginCreateOrUpdate(resourceGroupName: string, vmName: string, parameters: VirtualMachine, options?: VirtualMachinesCreateOrUpdateOptionalParams): Promise<SimplePollerLike<OperationState<VirtualMachine>, VirtualMachine>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
- parameters
- VirtualMachine
Parameters supplied to the Create Virtual Machine operation.
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<VirtualMachine>, VirtualMachine>>
beginCreateOrUpdateAndWait(string, string, VirtualMachine, VirtualMachinesCreateOrUpdateOptionalParams)
The operation to create or update a virtual machine. Please note some properties can be set only during virtual machine creation.
function beginCreateOrUpdateAndWait(resourceGroupName: string, vmName: string, parameters: VirtualMachine, options?: VirtualMachinesCreateOrUpdateOptionalParams): Promise<VirtualMachine>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
- parameters
- VirtualMachine
Parameters supplied to the Create Virtual Machine operation.
The options parameters.
Returns
Promise<VirtualMachine>
beginDeallocate(string, string, VirtualMachinesDeallocateOptionalParams)
Shuts down the virtual machine and releases the compute resources. You are not billed for the compute resources that this virtual machine uses.
function beginDeallocate(resourceGroupName: string, vmName: string, options?: VirtualMachinesDeallocateOptionalParams): Promise<SimplePollerLike<OperationState<void>, void>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<void>, void>>
beginDeallocateAndWait(string, string, VirtualMachinesDeallocateOptionalParams)
Shuts down the virtual machine and releases the compute resources. You are not billed for the compute resources that this virtual machine uses.
function beginDeallocateAndWait(resourceGroupName: string, vmName: string, options?: VirtualMachinesDeallocateOptionalParams): Promise<void>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<void>
beginDelete(string, string, VirtualMachinesDeleteOptionalParams)
The operation to delete a virtual machine.
function beginDelete(resourceGroupName: string, vmName: string, options?: VirtualMachinesDeleteOptionalParams): Promise<SimplePollerLike<OperationState<void>, void>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<void>, void>>
beginDeleteAndWait(string, string, VirtualMachinesDeleteOptionalParams)
The operation to delete a virtual machine.
function beginDeleteAndWait(resourceGroupName: string, vmName: string, options?: VirtualMachinesDeleteOptionalParams): Promise<void>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<void>
beginInstallPatches(string, string, VirtualMachineInstallPatchesParameters, VirtualMachinesInstallPatchesOptionalParams)
Installs patches on the VM.
function beginInstallPatches(resourceGroupName: string, vmName: string, installPatchesInput: VirtualMachineInstallPatchesParameters, options?: VirtualMachinesInstallPatchesOptionalParams): Promise<SimplePollerLike<OperationState<VirtualMachineInstallPatchesResult>, VirtualMachineInstallPatchesResult>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
- installPatchesInput
- VirtualMachineInstallPatchesParameters
Input for InstallPatches as directly received by the API
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<VirtualMachineInstallPatchesResult>, VirtualMachineInstallPatchesResult>>
beginInstallPatchesAndWait(string, string, VirtualMachineInstallPatchesParameters, VirtualMachinesInstallPatchesOptionalParams)
Installs patches on the VM.
function beginInstallPatchesAndWait(resourceGroupName: string, vmName: string, installPatchesInput: VirtualMachineInstallPatchesParameters, options?: VirtualMachinesInstallPatchesOptionalParams): Promise<VirtualMachineInstallPatchesResult>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
- installPatchesInput
- VirtualMachineInstallPatchesParameters
Input for InstallPatches as directly received by the API
The options parameters.
Returns
Promise<VirtualMachineInstallPatchesResult>
beginPerformMaintenance(string, string, VirtualMachinesPerformMaintenanceOptionalParams)
The operation to perform maintenance on a virtual machine.
function beginPerformMaintenance(resourceGroupName: string, vmName: string, options?: VirtualMachinesPerformMaintenanceOptionalParams): Promise<SimplePollerLike<OperationState<void>, void>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<void>, void>>
beginPerformMaintenanceAndWait(string, string, VirtualMachinesPerformMaintenanceOptionalParams)
The operation to perform maintenance on a virtual machine.
function beginPerformMaintenanceAndWait(resourceGroupName: string, vmName: string, options?: VirtualMachinesPerformMaintenanceOptionalParams): Promise<void>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<void>
beginPowerOff(string, string, VirtualMachinesPowerOffOptionalParams)
The operation to power off (stop) a virtual machine. The virtual machine can be restarted with the same provisioned resources. You are still charged for this virtual machine.
function beginPowerOff(resourceGroupName: string, vmName: string, options?: VirtualMachinesPowerOffOptionalParams): Promise<SimplePollerLike<OperationState<void>, void>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<void>, void>>
beginPowerOffAndWait(string, string, VirtualMachinesPowerOffOptionalParams)
The operation to power off (stop) a virtual machine. The virtual machine can be restarted with the same provisioned resources. You are still charged for this virtual machine.
function beginPowerOffAndWait(resourceGroupName: string, vmName: string, options?: VirtualMachinesPowerOffOptionalParams): Promise<void>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<void>
beginReapply(string, string, VirtualMachinesReapplyOptionalParams)
The operation to reapply a virtual machine's state.
function beginReapply(resourceGroupName: string, vmName: string, options?: VirtualMachinesReapplyOptionalParams): Promise<SimplePollerLike<OperationState<void>, void>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<void>, void>>
beginReapplyAndWait(string, string, VirtualMachinesReapplyOptionalParams)
The operation to reapply a virtual machine's state.
function beginReapplyAndWait(resourceGroupName: string, vmName: string, options?: VirtualMachinesReapplyOptionalParams): Promise<void>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<void>
beginRedeploy(string, string, VirtualMachinesRedeployOptionalParams)
Shuts down the virtual machine, moves it to a new node, and powers it back on.
function beginRedeploy(resourceGroupName: string, vmName: string, options?: VirtualMachinesRedeployOptionalParams): Promise<SimplePollerLike<OperationState<void>, void>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<void>, void>>
beginRedeployAndWait(string, string, VirtualMachinesRedeployOptionalParams)
Shuts down the virtual machine, moves it to a new node, and powers it back on.
function beginRedeployAndWait(resourceGroupName: string, vmName: string, options?: VirtualMachinesRedeployOptionalParams): Promise<void>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<void>
beginReimage(string, string, VirtualMachinesReimageOptionalParams)
Reimages (upgrade the operating system) a virtual machine which don't have a ephemeral OS disk, for virtual machines who have a ephemeral OS disk the virtual machine is reset to initial state. NOTE: The retaining of old OS disk depends on the value of deleteOption of OS disk. If deleteOption is detach, the old OS disk will be preserved after reimage. If deleteOption is delete, the old OS disk will be deleted after reimage. The deleteOption of the OS disk should be updated accordingly before performing the reimage.
function beginReimage(resourceGroupName: string, vmName: string, options?: VirtualMachinesReimageOptionalParams): Promise<SimplePollerLike<OperationState<void>, void>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<void>, void>>
beginReimageAndWait(string, string, VirtualMachinesReimageOptionalParams)
Reimages (upgrade the operating system) a virtual machine which don't have a ephemeral OS disk, for virtual machines who have a ephemeral OS disk the virtual machine is reset to initial state. NOTE: The retaining of old OS disk depends on the value of deleteOption of OS disk. If deleteOption is detach, the old OS disk will be preserved after reimage. If deleteOption is delete, the old OS disk will be deleted after reimage. The deleteOption of the OS disk should be updated accordingly before performing the reimage.
function beginReimageAndWait(resourceGroupName: string, vmName: string, options?: VirtualMachinesReimageOptionalParams): Promise<void>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<void>
beginRestart(string, string, VirtualMachinesRestartOptionalParams)
The operation to restart a virtual machine.
function beginRestart(resourceGroupName: string, vmName: string, options?: VirtualMachinesRestartOptionalParams): Promise<SimplePollerLike<OperationState<void>, void>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<void>, void>>
beginRestartAndWait(string, string, VirtualMachinesRestartOptionalParams)
The operation to restart a virtual machine.
function beginRestartAndWait(resourceGroupName: string, vmName: string, options?: VirtualMachinesRestartOptionalParams): Promise<void>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<void>
beginRunCommand(string, string, RunCommandInput, VirtualMachinesRunCommandOptionalParams)
Run command on the VM.
function beginRunCommand(resourceGroupName: string, vmName: string, parameters: RunCommandInput, options?: VirtualMachinesRunCommandOptionalParams): Promise<SimplePollerLike<OperationState<RunCommandResult>, RunCommandResult>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
- parameters
- RunCommandInput
Parameters supplied to the Run command operation.
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<RunCommandResult>, RunCommandResult>>
beginRunCommandAndWait(string, string, RunCommandInput, VirtualMachinesRunCommandOptionalParams)
Run command on the VM.
function beginRunCommandAndWait(resourceGroupName: string, vmName: string, parameters: RunCommandInput, options?: VirtualMachinesRunCommandOptionalParams): Promise<RunCommandResult>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
- parameters
- RunCommandInput
Parameters supplied to the Run command operation.
The options parameters.
Returns
Promise<RunCommandResult>
beginStart(string, string, VirtualMachinesStartOptionalParams)
The operation to start a virtual machine.
function beginStart(resourceGroupName: string, vmName: string, options?: VirtualMachinesStartOptionalParams): Promise<SimplePollerLike<OperationState<void>, void>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<void>, void>>
beginStartAndWait(string, string, VirtualMachinesStartOptionalParams)
The operation to start a virtual machine.
function beginStartAndWait(resourceGroupName: string, vmName: string, options?: VirtualMachinesStartOptionalParams): Promise<void>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<void>
beginUpdate(string, string, VirtualMachineUpdate, VirtualMachinesUpdateOptionalParams)
The operation to update a virtual machine.
function beginUpdate(resourceGroupName: string, vmName: string, parameters: VirtualMachineUpdate, options?: VirtualMachinesUpdateOptionalParams): Promise<SimplePollerLike<OperationState<VirtualMachine>, VirtualMachine>>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
- parameters
- VirtualMachineUpdate
Parameters supplied to the Update Virtual Machine operation.
The options parameters.
Returns
Promise<@azure/core-lro.SimplePollerLike<OperationState<VirtualMachine>, VirtualMachine>>
beginUpdateAndWait(string, string, VirtualMachineUpdate, VirtualMachinesUpdateOptionalParams)
The operation to update a virtual machine.
function beginUpdateAndWait(resourceGroupName: string, vmName: string, parameters: VirtualMachineUpdate, options?: VirtualMachinesUpdateOptionalParams): Promise<VirtualMachine>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
- parameters
- VirtualMachineUpdate
Parameters supplied to the Update Virtual Machine operation.
The options parameters.
Returns
Promise<VirtualMachine>
generalize(string, string, VirtualMachinesGeneralizeOptionalParams)
Sets the OS state of the virtual machine to generalized. It is recommended to sysprep the virtual machine before performing this operation. For Windows, please refer to Create a managed image of a generalized VM in Azure. For Linux, please refer to How to create an image of a virtual machine or VHD.
function generalize(resourceGroupName: string, vmName: string, options?: VirtualMachinesGeneralizeOptionalParams): Promise<void>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<void>
get(string, string, VirtualMachinesGetOptionalParams)
Retrieves information about the model view or the instance view of a virtual machine.
function get(resourceGroupName: string, vmName: string, options?: VirtualMachinesGetOptionalParams): Promise<VirtualMachine>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
- options
- VirtualMachinesGetOptionalParams
The options parameters.
Returns
Promise<VirtualMachine>
instanceView(string, string, VirtualMachinesInstanceViewOptionalParams)
Retrieves information about the run-time state of a virtual machine.
function instanceView(resourceGroupName: string, vmName: string, options?: VirtualMachinesInstanceViewOptionalParams): Promise<VirtualMachineInstanceView>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<VirtualMachineInstanceView>
list(string, VirtualMachinesListOptionalParams)
Lists all of the virtual machines in the specified resource group. Use the nextLink property in the response to get the next page of virtual machines.
function list(resourceGroupName: string, options?: VirtualMachinesListOptionalParams): PagedAsyncIterableIterator<VirtualMachine, VirtualMachine[], PageSettings>
Parameters
- resourceGroupName
-
string
The name of the resource group.
The options parameters.
Returns
listAll(VirtualMachinesListAllOptionalParams)
Lists all of the virtual machines in the specified subscription. Use the nextLink property in the response to get the next page of virtual machines.
function listAll(options?: VirtualMachinesListAllOptionalParams): PagedAsyncIterableIterator<VirtualMachine, VirtualMachine[], PageSettings>
Parameters
The options parameters.
Returns
listAvailableSizes(string, string, VirtualMachinesListAvailableSizesOptionalParams)
Lists all available virtual machine sizes to which the specified virtual machine can be resized.
function listAvailableSizes(resourceGroupName: string, vmName: string, options?: VirtualMachinesListAvailableSizesOptionalParams): PagedAsyncIterableIterator<VirtualMachineSize, VirtualMachineSize[], PageSettings>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
listByLocation(string, VirtualMachinesListByLocationOptionalParams)
Gets all the virtual machines under the specified subscription for the specified location.
function listByLocation(location: string, options?: VirtualMachinesListByLocationOptionalParams): PagedAsyncIterableIterator<VirtualMachine, VirtualMachine[], PageSettings>
Parameters
- location
-
string
The location for which virtual machines under the subscription are queried.
The options parameters.
Returns
retrieveBootDiagnosticsData(string, string, VirtualMachinesRetrieveBootDiagnosticsDataOptionalParams)
The operation to retrieve SAS URIs for a virtual machine's boot diagnostic logs.
function retrieveBootDiagnosticsData(resourceGroupName: string, vmName: string, options?: VirtualMachinesRetrieveBootDiagnosticsDataOptionalParams): Promise<RetrieveBootDiagnosticsDataResult>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<RetrieveBootDiagnosticsDataResult>
simulateEviction(string, string, VirtualMachinesSimulateEvictionOptionalParams)
The operation to simulate the eviction of spot virtual machine.
function simulateEviction(resourceGroupName: string, vmName: string, options?: VirtualMachinesSimulateEvictionOptionalParams): Promise<void>
Parameters
- resourceGroupName
-
string
The name of the resource group.
- vmName
-
string
The name of the virtual machine.
The options parameters.
Returns
Promise<void>