Udostępnij za pośrednictwem


IVirtualMachine Interface

Definition

An immutable client-side representation of an Azure virtual machine.

public interface IVirtualMachine : Microsoft.Azure.Management.Compute.Fluent.IVirtualMachineBeta, Microsoft.Azure.Management.Network.Fluent.IHasNetworkInterfaces, Microsoft.Azure.Management.ResourceManager.Fluent.Core.IBeta, Microsoft.Azure.Management.ResourceManager.Fluent.Core.IGroupableResource<Microsoft.Azure.Management.Compute.Fluent.IComputeManager,Microsoft.Azure.Management.Compute.Fluent.Models.VirtualMachineInner>, Microsoft.Azure.Management.ResourceManager.Fluent.Core.IHasInner<Microsoft.Azure.Management.Compute.Fluent.Models.VirtualMachineInner>, Microsoft.Azure.Management.ResourceManager.Fluent.Core.IHasManager<Microsoft.Azure.Management.Compute.Fluent.IComputeManager>, Microsoft.Azure.Management.ResourceManager.Fluent.Core.ResourceActions.IRefreshable<Microsoft.Azure.Management.Compute.Fluent.IVirtualMachine>, Microsoft.Azure.Management.ResourceManager.Fluent.Core.ResourceActions.IUpdatable<Microsoft.Azure.Management.Compute.Fluent.VirtualMachine.Update.IUpdate>
type IVirtualMachine = interface
    interface IGroupableResource<IComputeManager, VirtualMachineInner>
    interface IResource
    interface IIndexable
    interface IHasId
    interface IHasName
    interface IHasResourceGroup
    interface IHasManager<IComputeManager>
    interface IHasInner<VirtualMachineInner>
    interface IRefreshable<IVirtualMachine>
    interface IUpdatable<IUpdate>
    interface IHasNetworkInterfaces
    interface IVirtualMachineBeta
    interface IBeta
Public Interface IVirtualMachine
Implements IBeta, IGroupableResource(Of IComputeManager, VirtualMachineInner), IHasInner(Of VirtualMachineInner), IHasManager(Of IComputeManager), IHasNetworkInterfaces, IRefreshable(Of IVirtualMachine), IUpdatable(Of IUpdate), IVirtualMachineBeta
Implements

Properties

AvailabilitySetId

Gets the resource ID of the availability set associated with this virtual machine.

AvailabilityZones

Gets the availability zones assigned to the virtual machine.

(Inherited from IVirtualMachineBeta)
BillingProfile

Gets the billing related details of a low priority virtual machine.

(Inherited from IVirtualMachineBeta)
BootDiagnosticsStorageUri

Gets the storage blob endpoint uri if boot diagnostics is enabled for the virtual machine.

ComputerName

Gets name of this virtual machine.

DataDisks

Gets the managed data disks associated with this virtual machine, indexed by LUN.

DiagnosticsProfile

Gets the diagnostics profile.

DiskEncryption

Gets entry point to enabling, disabling and querying disk encryption.

EvictionPolicy

Gets the eviction policy for the virtual machine.

(Inherited from IVirtualMachineBeta)
Id

Gets the resource id string

(Inherited from IHasId)
Inner (Inherited from IHasInner<T>)
InstanceView

Gets the virtual machine instance view. The instance view will be cached for later retrieval using instanceView.

IsBootDiagnosticsEnabled

Gets true if boot diagnostics is enabled for the virtual machine.

IsManagedDiskEnabled

Gets true if managed disks are used for the virtual machine's disks (OS, data).

IsManagedServiceIdentityEnabled

Gets true if Managed Service Identity is enabled for the virtual machine.

(Inherited from IVirtualMachineBeta)
Key (Inherited from IIndexable)
LicenseType

Gets the licenseType value.

ManagedServiceIdentityType

Gets the type of Managed Service Identity used for the virtual machine.

(Inherited from IVirtualMachineBeta)
Manager

Gets the manager client type of this resource type.

(Inherited from IHasManager<ManagerT>)
Name

Gets the name of the resource

(Inherited from IHasName)
NetworkInterfaceIds

Gets the list of resource IDs of the network interfaces associated with this resource.

(Inherited from IHasNetworkInterfaces)
OSDiskCachingType

Gets the operating system disk caching type.

OSDiskId

Gets resource ID of the managed disk backing the OS disk.

OSDiskSize

Gets the size of the operating system disk in GB.

OSDiskStorageAccountType

Gets the storage account type of the managed disk backing OS disk.

OSProfile

Gets the operating system profile.

OSType

Gets the operating system of this virtual machine.

OSUnmanagedDiskVhdUri

Gets the URI to the VHD file backing this virtual machine's operating system disk.

Plan

Gets the plan value.

PowerState

Gets the power state of the virtual machine.

PrimaryNetworkInterfaceId

Gets the resource id of the primary network interface associated with this resource.

(Inherited from IHasNetworkInterfaces)
Priority

Gets the priority for the virtual machine.

(Inherited from IVirtualMachineBeta)
ProvisioningState

Gets the provisioningState value.

ProximityPlacementGroup

Get specifies information about the proximity placement group that the virtual machine scale set should be assigned to.

Region (Inherited from IResource)
RegionName (Inherited from IResource)
ResourceGroupName (Inherited from IHasResourceGroup)
Size

Gets the virtual machine size.

StorageProfile

Gets Returns the storage profile of an Azure virtual machine.

SystemAssignedManagedServiceIdentityPrincipalId

Gets the System Assigned (Local) Managed Service Identity specific Active Directory service principal ID assigned to the virtual machine.

(Inherited from IVirtualMachineBeta)
SystemAssignedManagedServiceIdentityTenantId

Gets the System Assigned (Local) Managed Service Identity specific Active Directory tenant ID assigned to the virtual machine.

(Inherited from IVirtualMachineBeta)
Tags (Inherited from IResource)
Type (Inherited from IResource)
UnmanagedDataDisks

Gets the unmanaged data disks associated with this virtual machine, indexed by LUN number.

UserAssignedManagedServiceIdentityIds

Gets the resource ids of User Assigned Managed Service Identities associated with the virtual machine.

(Inherited from IVirtualMachineBeta)
VMId

Gets the virtual machine unique ID.

Methods

AvailableSizes()

Lists all available virtual machine sizes this virtual machine can resized to.

Capture(String, String, Boolean)

Captures the virtual machine by copying virtual hard disks of the VM.

CaptureAsync(String, String, Boolean, CancellationToken)

Captures the virtual machine by copying virtual hard disks of the VM asynchronously.

ConvertToManaged()

Converts (migrates) the virtual machine with un-managed disks to use managed disk.

ConvertToManagedAsync(CancellationToken)

Converts (migrates) the virtual machine with un-managed disks to use managed disk asynchronously.

Deallocate()

Shuts down the virtual machine and releases the compute resources.

DeallocateAsync(CancellationToken)

Shuts down the virtual machine and releases the compute resources asynchronously.

Generalize()

Generalizes the virtual machine.

GeneralizeAsync(CancellationToken)

Generalizes the virtual machine asynchronously.

GetPrimaryNetworkInterface()

Gets the primary network interface. Note that this method can result in a call to the cloud to fetch the network interface information.

(Inherited from IHasNetworkInterfaces)
GetPrimaryNetworkInterfaceAsync()

Gets the primary network interface. Note that this method can result in a call to the cloud to fetch the network interface information.

(Inherited from IHasNetworkInterfaces)
GetPrimaryPublicIPAddress()

Gets the public IP address associated with this virtual machine's primary network interface. Note that this method makes a rest API call to fetch the resource.

GetPrimaryPublicIPAddressId()
ListExtensions()
ListExtensionsAsync(CancellationToken)
PowerOff(Boolean)

Powers off (stops) the virtual machine.

PowerOffAsync(Boolean, CancellationToken)

Powers off (stops) the virtual machine asynchronously.

PowerOffAsync(CancellationToken)

Powers off (stops) the virtual machine asynchronously.

Redeploy()

Redeploys the virtual machine.

RedeployAsync(CancellationToken)

Redeploys the virtual machine asynchronously.

Refresh()

Refreshes the resource to sync with Azure.

(Inherited from IRefreshable<T>)
RefreshAsync(CancellationToken)

Refreshes the resource to sync with Azure.

(Inherited from IRefreshable<T>)
RefreshInstanceView()

Refreshes the virtual machine instance view to sync with Azure. The instance view will be cached for later retrieval using instanceView.

RefreshInstanceViewAsync(CancellationToken)

Refreshes the virtual machine instance view to sync with Azure.

Reimage(Nullable<Boolean>)

Reimages the virtual machine.

ReimageAsync(Nullable<Boolean>, CancellationToken)

Reimages the virtual machine asynchronously.

Restart()

Restarts the virtual machine.

RestartAsync(CancellationToken)

Restarts the virtual machine asynchronously.

RunCommand(RunCommandInput)

Run commands in the virtual machine.

(Inherited from IVirtualMachineBeta)
RunCommandAsync(RunCommandInput, CancellationToken)

Run commands in the virtual machine asynchronously.

(Inherited from IVirtualMachineBeta)
RunPowerShellScript(IList<String>, IList<RunCommandInputParameter>)

Run shell script in a virtual machine.

(Inherited from IVirtualMachineBeta)
RunPowerShellScriptAsync(IList<String>, IList<RunCommandInputParameter>, CancellationToken)

Run shell script in the virtual machine asynchronously.

(Inherited from IVirtualMachineBeta)
RunShellScript(IList<String>, IList<RunCommandInputParameter>)

Run shell script in the virtual machine.

(Inherited from IVirtualMachineBeta)
RunShellScriptAsync(IList<String>, IList<RunCommandInputParameter>, CancellationToken)

Run shell script in the virtual machine asynchronously.

(Inherited from IVirtualMachineBeta)
Start()

Starts the virtual machine.

StartAsync(CancellationToken)

Starts the virtual machine asynchronously.

Update() (Inherited from IUpdatable<T>)

Applies to