Compartir a través de


New-SCVirtualMachine

Creates a virtual machine to be managed by VMM.

Syntax

NewVmFromHWProfile

New-SCVirtualMachine
    [-Name] <String>
    -VMHost <Host>
    -Path <String>
    [-StartVM]
    [-StartAction <VMStartAction>]
    [-StopAction <VMStopAction>]
    [-Generation <Int32>]
    [-OperatingSystem <OperatingSystem>]
    [-LinuxAdministratorSSHKeyString <String>]
    [-VMMServer <ServerConnection>]
    [-Description <String>]
    [-Owner <String>]
    [-UserRole <UserRole>]
    [-UseLocalVirtualHardDisk]
    [-UseDiffDiskOptimization]
    [-DelayStartSeconds <Int32>]
    [-RecoveryPointObjective <Int32>]
    [-ProtectionProvider <ProtectionProvider>]
    [-ReplicationGroup <ReplicationGroup>]
    [-MemoryMB <Int32>]
    [-DynamicMemoryMaximumMB <Int32>]
    [-DynamicMemoryBufferPercentage <Int32>]
    [-MemoryWeight <Int32>]
    [-MonitorMaximumCount <Int32>]
    [-MonitorMaximumResolution <String>]
    [-CPUCount <Byte>]
    [-CPUType <ProcessorType>]
    [-CPURelativeWeight <Int32>]
    [-HardwareProfile <HardwareProfile>]
    [-CPUPerVirtualNumaNodeMaximum <Byte>]
    [-MemoryPerVirtualNumaNodeMaximumMB <Int32>]
    [-VirtualNumaNodesPerSocketMaximum <Byte>]
    [-CPUCyclesReservePercent <UInt16>]
    [-CPUCyclesLimitPercent <UInt16>]
    [-DynamicMemoryMinimumMB <Int32>]
    [-AutomaticCriticalErrorAction <UInt16>]
    [-AutomaticCriticalErrorActionTimeout <Int32>]
    [-CheckpointType <CheckpointType>]
    [-SecureBootTemplate <String>]
    [-JobGroup <Guid>]
    [-SkipInstallVirtualizationGuestServices]
    [-ReturnImmediately]
    [-LinuxDomainName <String>]
    [-LinuxAdministratorSSHKey <SSHKey>]
    [-RunAsynchronously]
    [-PROTipID <Guid>]
    [-JobVariable <String>]
    [-OnBehalfOfUser <String>]
    [-OnBehalfOfUserRole <UserRole>]
    [<CommonParameters>]

NewVmFromTemplate

New-SCVirtualMachine
    [-Name] <String>
    -VMTemplate <Template>
    -VMHost <Host>
    -Path <String>
    [-StartVM]
    [-StartAction <VMStartAction>]
    [-StopAction <VMStopAction>]
    [-OperatingSystem <OperatingSystem>]
    [-LinuxAdministratorSSHKeyString <String>]
    [-VMMServer <ServerConnection>]
    [-Description <String>]
    [-Owner <String>]
    [-UserRole <UserRole>]
    [-VMShieldingData <KeyFile>]
    [-UseLocalVirtualHardDisk]
    [-UseDiffDiskOptimization]
    [-DelayStartSeconds <Int32>]
    [-RecoveryPointObjective <Int32>]
    [-ProtectionProvider <ProtectionProvider>]
    [-ReplicationGroup <ReplicationGroup>]
    [-MemoryMB <Int32>]
    [-DynamicMemoryMaximumMB <Int32>]
    [-DynamicMemoryBufferPercentage <Int32>]
    [-MemoryWeight <Int32>]
    [-MonitorMaximumCount <Int32>]
    [-MonitorMaximumResolution <String>]
    [-CPUCount <Byte>]
    [-CPUType <ProcessorType>]
    [-CPURelativeWeight <Int32>]
    [-HardwareProfile <HardwareProfile>]
    [-CPUPerVirtualNumaNodeMaximum <Byte>]
    [-MemoryPerVirtualNumaNodeMaximumMB <Int32>]
    [-VirtualNumaNodesPerSocketMaximum <Byte>]
    [-CPUCyclesReservePercent <UInt16>]
    [-CPUCyclesLimitPercent <UInt16>]
    [-DynamicMemoryMinimumMB <Int32>]
    [-AutomaticCriticalErrorAction <UInt16>]
    [-AutomaticCriticalErrorActionTimeout <Int32>]
    [-CheckpointType <CheckpointType>]
    [-SecureBootTemplate <String>]
    [-GuestOSProfile <GuestOSProfile>]
    [-FullName <String>]
    [-OrganizationName <String>]
    [-ComputerName <String>]
    [-ProductKey <String>]
    [-GuiRunOnceCommands <String[]>]
    [-TimeZone <Int32>]
    [-LocalAdministratorCredential <VMMCredential>]
    [-Domain <String>]
    [-DomainJoinCredential <VMMCredential>]
    [-Workgroup <String>]
    [-AnswerFile <Script>]
    [-JobGroup <Guid>]
    [-SkipInstallVirtualizationGuestServices]
    [-ReturnImmediately]
    [-LinuxDomainName <String>]
    [-LinuxAdministratorSSHKey <SSHKey>]
    [-RunAsynchronously]
    [-PROTipID <Guid>]
    [-JobVariable <String>]
    [-OnBehalfOfUser <String>]
    [-OnBehalfOfUserRole <UserRole>]
    [<CommonParameters>]

NewVmFromVmCloud

New-SCVirtualMachine
    [-Name] <String>
    -VM <VM>
    -Cloud <Cloud>
    [-StartVM]
    [-StartAction <VMStartAction>]
    [-StopAction <VMStopAction>]
    [-OperatingSystem <OperatingSystem>]
    [-LinuxAdministratorSSHKeyString <String>]
    [-VMMServer <ServerConnection>]
    [-Description <String>]
    [-Owner <String>]
    [-UserRole <UserRole>]
    [-CapabilityProfile <CapabilityProfile>]
    [-UseLocalVirtualHardDisk]
    [-UseDiffDiskOptimization]
    [-StoreToLibrary]
    [-DelayStartSeconds <Int32>]
    [-SelfServiceRole <SelfServiceUserRole>]
    [-MemoryMB <Int32>]
    [-DynamicMemoryMaximumMB <Int32>]
    [-DynamicMemoryBufferPercentage <Int32>]
    [-MemoryWeight <Int32>]
    [-MonitorMaximumCount <Int32>]
    [-MonitorMaximumResolution <String>]
    [-CPUCount <Byte>]
    [-CPUType <ProcessorType>]
    [-CPURelativeWeight <Int32>]
    [-HardwareProfile <HardwareProfile>]
    [-CPUPerVirtualNumaNodeMaximum <Byte>]
    [-MemoryPerVirtualNumaNodeMaximumMB <Int32>]
    [-VirtualNumaNodesPerSocketMaximum <Byte>]
    [-CPUCyclesReservePercent <UInt16>]
    [-CPUCyclesLimitPercent <UInt16>]
    [-DynamicMemoryMinimumMB <Int32>]
    [-SecureBootTemplate <String>]
    [-JobGroup <Guid>]
    [-SkipInstallVirtualizationGuestServices]
    [-ReturnImmediately]
    [-LinuxDomainName <String>]
    [-LinuxAdministratorSSHKey <SSHKey>]
    [-RunAsynchronously]
    [-PROTipID <Guid>]
    [-JobVariable <String>]
    [-OnBehalfOfUser <String>]
    [-OnBehalfOfUserRole <UserRole>]
    [<CommonParameters>]

NewVmFromVm

New-SCVirtualMachine
    [-Name] <String>
    -VM <VM>
    -VMHost <Host>
    -Path <String>
    [-StartVM]
    [-StartAction <VMStartAction>]
    [-StopAction <VMStopAction>]
    [-OperatingSystem <OperatingSystem>]
    [-LinuxAdministratorSSHKeyString <String>]
    [-VMMServer <ServerConnection>]
    [-Description <String>]
    [-Owner <String>]
    [-UserRole <UserRole>]
    [-UseLocalVirtualHardDisk]
    [-UseDiffDiskOptimization]
    [-DelayStartSeconds <Int32>]
    [-MemoryMB <Int32>]
    [-DynamicMemoryMaximumMB <Int32>]
    [-DynamicMemoryBufferPercentage <Int32>]
    [-MemoryWeight <Int32>]
    [-MonitorMaximumCount <Int32>]
    [-MonitorMaximumResolution <String>]
    [-CPUCount <Byte>]
    [-CPUType <ProcessorType>]
    [-CPURelativeWeight <Int32>]
    [-HardwareProfile <HardwareProfile>]
    [-CPUPerVirtualNumaNodeMaximum <Byte>]
    [-MemoryPerVirtualNumaNodeMaximumMB <Int32>]
    [-VirtualNumaNodesPerSocketMaximum <Byte>]
    [-CPUCyclesReservePercent <UInt16>]
    [-CPUCyclesLimitPercent <UInt16>]
    [-DynamicMemoryMinimumMB <Int32>]
    [-SecureBootTemplate <String>]
    [-JobGroup <Guid>]
    [-SkipInstallVirtualizationGuestServices]
    [-ReturnImmediately]
    [-LinuxDomainName <String>]
    [-LinuxAdministratorSSHKey <SSHKey>]
    [-RunAsynchronously]
    [-PROTipID <Guid>]
    [-JobVariable <String>]
    [-OnBehalfOfUser <String>]
    [-OnBehalfOfUserRole <UserRole>]
    [<CommonParameters>]

NewVmFromVirtualDisk

New-SCVirtualMachine
    [-Name] <String>
    -VirtualHardDisk <StandaloneVirtualHardDisk>
    -VMHost <Host>
    -Path <String>
    [-StartVM]
    [-StartAction <VMStartAction>]
    [-StopAction <VMStopAction>]
    [-Generation <Int32>]
    [-OperatingSystem <OperatingSystem>]
    [-LinuxAdministratorSSHKeyString <String>]
    [-VMMServer <ServerConnection>]
    [-Description <String>]
    [-Owner <String>]
    [-UserRole <UserRole>]
    [-UseLocalVirtualHardDisk]
    [-UseDiffDiskOptimization]
    [-DelayStartSeconds <Int32>]
    [-RecoveryPointObjective <Int32>]
    [-ProtectionProvider <ProtectionProvider>]
    [-ReplicationGroup <ReplicationGroup>]
    [-MemoryMB <Int32>]
    [-DynamicMemoryMaximumMB <Int32>]
    [-DynamicMemoryBufferPercentage <Int32>]
    [-MemoryWeight <Int32>]
    [-MonitorMaximumCount <Int32>]
    [-MonitorMaximumResolution <String>]
    [-CPUCount <Byte>]
    [-CPUType <ProcessorType>]
    [-CPURelativeWeight <Int32>]
    [-HardwareProfile <HardwareProfile>]
    [-CPUPerVirtualNumaNodeMaximum <Byte>]
    [-MemoryPerVirtualNumaNodeMaximumMB <Int32>]
    [-VirtualNumaNodesPerSocketMaximum <Byte>]
    [-CPUCyclesReservePercent <UInt16>]
    [-CPUCyclesLimitPercent <UInt16>]
    [-DynamicMemoryMinimumMB <Int32>]
    [-AutomaticCriticalErrorAction <UInt16>]
    [-AutomaticCriticalErrorActionTimeout <Int32>]
    [-CheckpointType <CheckpointType>]
    [-SecureBootTemplate <String>]
    [-JobGroup <Guid>]
    [-SkipInstallVirtualizationGuestServices]
    [-ReturnImmediately]
    [-LinuxDomainName <String>]
    [-LinuxAdministratorSSHKey <SSHKey>]
    [-RunAsynchronously]
    [-PROTipID <Guid>]
    [-JobVariable <String>]
    [-OnBehalfOfUser <String>]
    [-OnBehalfOfUserRole <UserRole>]
    [<CommonParameters>]

NewVmFromVmConfig

New-SCVirtualMachine
    [-Name] <String>
    -VMConfiguration <BaseVMConfiguration>
    [-StartVM]
    [-StartAction <VMStartAction>]
    [-StopAction <VMStopAction>]
    [-OperatingSystem <OperatingSystem>]
    [-LinuxAdministratorSSHKeyString <String>]
    [-VMMServer <ServerConnection>]
    [-Description <String>]
    [-Owner <String>]
    [-UserRole <UserRole>]
    [-VMShieldingData <KeyFile>]
    [-Cloud <Cloud>]
    [-CapabilityProfile <CapabilityProfile>]
    [-UseLocalVirtualHardDisk]
    [-UseDiffDiskOptimization]
    [-StoreToLibrary]
    [-DelayStartSeconds <Int32>]
    [-SelfServiceRole <SelfServiceUserRole>]
    [-MemoryMB <Int32>]
    [-DynamicMemoryMaximumMB <Int32>]
    [-DynamicMemoryBufferPercentage <Int32>]
    [-MemoryWeight <Int32>]
    [-MonitorMaximumCount <Int32>]
    [-MonitorMaximumResolution <String>]
    [-CPUCount <Byte>]
    [-CPUType <ProcessorType>]
    [-CPURelativeWeight <Int32>]
    [-HardwareProfile <HardwareProfile>]
    [-CPUPerVirtualNumaNodeMaximum <Byte>]
    [-MemoryPerVirtualNumaNodeMaximumMB <Int32>]
    [-VirtualNumaNodesPerSocketMaximum <Byte>]
    [-CPUCyclesReservePercent <UInt16>]
    [-CPUCyclesLimitPercent <UInt16>]
    [-DynamicMemoryMinimumMB <Int32>]
    [-AutomaticCriticalErrorAction <UInt16>]
    [-AutomaticCriticalErrorActionTimeout <Int32>]
    [-CheckpointType <CheckpointType>]
    [-SecureBootTemplate <String>]
    [-GuestOSProfile <GuestOSProfile>]
    [-FullName <String>]
    [-OrganizationName <String>]
    [-ComputerName <String>]
    [-ProductKey <String>]
    [-GuiRunOnceCommands <String[]>]
    [-TimeZone <Int32>]
    [-LocalAdministratorCredential <VMMCredential>]
    [-Domain <String>]
    [-DomainJoinCredential <VMMCredential>]
    [-Workgroup <String>]
    [-AnswerFile <Script>]
    [-JobGroup <Guid>]
    [-SkipInstallVirtualizationGuestServices]
    [-ReturnImmediately]
    [-LinuxDomainName <String>]
    [-LinuxAdministratorSSHKey <SSHKey>]
    [-RunAsynchronously]
    [-PROTipID <Guid>]
    [-JobVariable <String>]
    [-OnBehalfOfUser <String>]
    [-OnBehalfOfUserRole <UserRole>]
    [<CommonParameters>]

NewStoredVmFromVirtualDisk

New-SCVirtualMachine
    [-Name] <String>
    -VirtualHardDisk <StandaloneVirtualHardDisk>
    -LibraryServer <LibraryServer>
    -SharePath <String>
    [-StartAction <VMStartAction>]
    [-StopAction <VMStopAction>]
    [-Generation <Int32>]
    [-OperatingSystem <OperatingSystem>]
    [-LinuxAdministratorSSHKeyString <String>]
    [-VMMServer <ServerConnection>]
    [-Description <String>]
    [-Owner <String>]
    [-UserRole <UserRole>]
    [-UseLocalVirtualHardDisk]
    [-UseDiffDiskOptimization]
    [-DelayStartSeconds <Int32>]
    [-MemoryMB <Int32>]
    [-DynamicMemoryMaximumMB <Int32>]
    [-DynamicMemoryBufferPercentage <Int32>]
    [-MemoryWeight <Int32>]
    [-MonitorMaximumCount <Int32>]
    [-MonitorMaximumResolution <String>]
    [-CPUCount <Byte>]
    [-CPUType <ProcessorType>]
    [-CPURelativeWeight <Int32>]
    [-HardwareProfile <HardwareProfile>]
    [-CPUPerVirtualNumaNodeMaximum <Byte>]
    [-MemoryPerVirtualNumaNodeMaximumMB <Int32>]
    [-VirtualNumaNodesPerSocketMaximum <Byte>]
    [-CPUCyclesReservePercent <UInt16>]
    [-CPUCyclesLimitPercent <UInt16>]
    [-DynamicMemoryMinimumMB <Int32>]
    [-SecureBootTemplate <String>]
    [-JobGroup <Guid>]
    [-SkipInstallVirtualizationGuestServices]
    [-ReturnImmediately]
    [-LinuxDomainName <String>]
    [-LinuxAdministratorSSHKey <SSHKey>]
    [-RunAsynchronously]
    [-PROTipID <Guid>]
    [-JobVariable <String>]
    [-OnBehalfOfUser <String>]
    [-OnBehalfOfUserRole <UserRole>]
    [<CommonParameters>]

NewStoredVmFromVm

New-SCVirtualMachine
    [-Name] <String>
    -VM <VM>
    -LibraryServer <LibraryServer>
    -SharePath <String>
    [-StartAction <VMStartAction>]
    [-StopAction <VMStopAction>]
    [-OperatingSystem <OperatingSystem>]
    [-LinuxAdministratorSSHKeyString <String>]
    [-VMMServer <ServerConnection>]
    [-Description <String>]
    [-Owner <String>]
    [-UserRole <UserRole>]
    [-UseLocalVirtualHardDisk]
    [-UseDiffDiskOptimization]
    [-DelayStartSeconds <Int32>]
    [-MemoryMB <Int32>]
    [-DynamicMemoryMaximumMB <Int32>]
    [-DynamicMemoryBufferPercentage <Int32>]
    [-MemoryWeight <Int32>]
    [-MonitorMaximumCount <Int32>]
    [-MonitorMaximumResolution <String>]
    [-CPUCount <Byte>]
    [-CPUType <ProcessorType>]
    [-CPURelativeWeight <Int32>]
    [-HardwareProfile <HardwareProfile>]
    [-CPUPerVirtualNumaNodeMaximum <Byte>]
    [-MemoryPerVirtualNumaNodeMaximumMB <Int32>]
    [-VirtualNumaNodesPerSocketMaximum <Byte>]
    [-CPUCyclesReservePercent <UInt16>]
    [-CPUCyclesLimitPercent <UInt16>]
    [-DynamicMemoryMinimumMB <Int32>]
    [-SecureBootTemplate <String>]
    [-JobGroup <Guid>]
    [-SkipInstallVirtualizationGuestServices]
    [-ReturnImmediately]
    [-LinuxDomainName <String>]
    [-LinuxAdministratorSSHKey <SSHKey>]
    [-RunAsynchronously]
    [-PROTipID <Guid>]
    [-JobVariable <String>]
    [-OnBehalfOfUser <String>]
    [-OnBehalfOfUserRole <UserRole>]
    [<CommonParameters>]

NewVmFromVmConfigScaleOut

New-SCVirtualMachine
    [-Name] <String>
    -VMConfigurationScaleOut <BaseVMConfiguration>
    [-StartAction <VMStartAction>]
    [-StopAction <VMStopAction>]
    [-OperatingSystem <OperatingSystem>]
    [-LinuxAdministratorSSHKeyString <String>]
    [-VMMServer <ServerConnection>]
    [-Description <String>]
    [-Owner <String>]
    [-UserRole <UserRole>]
    [-UseLocalVirtualHardDisk]
    [-UseDiffDiskOptimization]
    [-DelayStartSeconds <Int32>]
    [-MemoryMB <Int32>]
    [-DynamicMemoryMaximumMB <Int32>]
    [-DynamicMemoryBufferPercentage <Int32>]
    [-MemoryWeight <Int32>]
    [-MonitorMaximumCount <Int32>]
    [-MonitorMaximumResolution <String>]
    [-CPUCount <Byte>]
    [-CPUType <ProcessorType>]
    [-CPURelativeWeight <Int32>]
    [-HardwareProfile <HardwareProfile>]
    [-CPUPerVirtualNumaNodeMaximum <Byte>]
    [-MemoryPerVirtualNumaNodeMaximumMB <Int32>]
    [-VirtualNumaNodesPerSocketMaximum <Byte>]
    [-CPUCyclesReservePercent <UInt16>]
    [-CPUCyclesLimitPercent <UInt16>]
    [-DynamicMemoryMinimumMB <Int32>]
    [-SecureBootTemplate <String>]
    [-JobGroup <Guid>]
    [-SkipInstallVirtualizationGuestServices]
    [-ReturnImmediately]
    [-LinuxDomainName <String>]
    [-LinuxAdministratorSSHKey <SSHKey>]
    [-RunAsynchronously]
    [-PROTipID <Guid>]
    [-JobVariable <String>]
    [-OnBehalfOfUser <String>]
    [-OnBehalfOfUserRole <UserRole>]
    [<CommonParameters>]

NewVmFromComputerTierScaleOut

New-SCVirtualMachine
    [-Name] <String>
    -ComputerTier <ComputerTier>
    [-StartAction <VMStartAction>]
    [-StopAction <VMStopAction>]
    [-OperatingSystem <OperatingSystem>]
    [-LinuxAdministratorSSHKeyString <String>]
    [-VMMServer <ServerConnection>]
    [-Description <String>]
    [-Owner <String>]
    [-UserRole <UserRole>]
    [-UseLocalVirtualHardDisk]
    [-UseDiffDiskOptimization]
    [-DelayStartSeconds <Int32>]
    [-MemoryMB <Int32>]
    [-DynamicMemoryMaximumMB <Int32>]
    [-DynamicMemoryBufferPercentage <Int32>]
    [-MemoryWeight <Int32>]
    [-MonitorMaximumCount <Int32>]
    [-MonitorMaximumResolution <String>]
    [-CPUCount <Byte>]
    [-CPUType <ProcessorType>]
    [-CPURelativeWeight <Int32>]
    [-HardwareProfile <HardwareProfile>]
    [-CPUPerVirtualNumaNodeMaximum <Byte>]
    [-MemoryPerVirtualNumaNodeMaximumMB <Int32>]
    [-VirtualNumaNodesPerSocketMaximum <Byte>]
    [-CPUCyclesReservePercent <UInt16>]
    [-CPUCyclesLimitPercent <UInt16>]
    [-DynamicMemoryMinimumMB <Int32>]
    [-SecureBootTemplate <String>]
    [-ComputerName <String>]
    [-JobGroup <Guid>]
    [-SkipInstallVirtualizationGuestServices]
    [-ReturnImmediately]
    [-LinuxDomainName <String>]
    [-LinuxAdministratorSSHKey <SSHKey>]
    [-RunAsynchronously]
    [-PROTipID <Guid>]
    [-JobVariable <String>]
    [-OnBehalfOfUser <String>]
    [-OnBehalfOfUserRole <UserRole>]
    [<CommonParameters>]

NewStoredVmFromHardwareProfile

New-SCVirtualMachine
    [-Name] <String>
    -LibraryServer <LibraryServer>
    -SharePath <String>
    [-StartAction <VMStartAction>]
    [-StopAction <VMStopAction>]
    [-Generation <Int32>]
    [-OperatingSystem <OperatingSystem>]
    [-LinuxAdministratorSSHKeyString <String>]
    [-VMMServer <ServerConnection>]
    [-Description <String>]
    [-Owner <String>]
    [-UserRole <UserRole>]
    [-UseLocalVirtualHardDisk]
    [-UseDiffDiskOptimization]
    [-DelayStartSeconds <Int32>]
    [-MemoryMB <Int32>]
    [-DynamicMemoryMaximumMB <Int32>]
    [-DynamicMemoryBufferPercentage <Int32>]
    [-MemoryWeight <Int32>]
    [-MonitorMaximumCount <Int32>]
    [-MonitorMaximumResolution <String>]
    [-CPUCount <Byte>]
    [-CPUType <ProcessorType>]
    [-CPURelativeWeight <Int32>]
    [-HardwareProfile <HardwareProfile>]
    [-CPUPerVirtualNumaNodeMaximum <Byte>]
    [-MemoryPerVirtualNumaNodeMaximumMB <Int32>]
    [-VirtualNumaNodesPerSocketMaximum <Byte>]
    [-CPUCyclesReservePercent <UInt16>]
    [-CPUCyclesLimitPercent <UInt16>]
    [-DynamicMemoryMinimumMB <Int32>]
    [-SecureBootTemplate <String>]
    [-JobGroup <Guid>]
    [-SkipInstallVirtualizationGuestServices]
    [-ReturnImmediately]
    [-LinuxDomainName <String>]
    [-LinuxAdministratorSSHKey <SSHKey>]
    [-RunAsynchronously]
    [-PROTipID <Guid>]
    [-JobVariable <String>]
    [-OnBehalfOfUser <String>]
    [-OnBehalfOfUserRole <UserRole>]
    [<CommonParameters>]

Description

The New-SCVirtualMachine cmdlet creates a virtual machine that Virtual Machine Manager (VMM) manages. You can create a virtual machine from the following sources:

  • A stopped virtual machine deployed on a host.
  • A virtual machine stored in the VMM library.
  • A virtual machine template.
  • A virtual hard disk that already contains an operating system. You can create a virtual machine from an existing hard disk that contains a third-party operating system, such as Linux.
  • A blank virtual hard disk.

In System Center, you can create a virtual machine by using a differencing disk. For more information about differencing disks, see New-SCVirtualDiskDrive.

When you deploy a new virtual machine to a Hyper-V host, you can specify a location for the virtual machine files, or use the default path: <C>:\ProgramData\Microsoft\Windows\Hyper-V. When you deploy a virtual machine on a VMware ESX host or Citrix XenServer host, there is no default path. Specify a path.

As an alternative to the current cmdlet, you can create a virtual machine by using the following cmdlet:

  • New-SCV2V creates a virtual machine from an existing virtual machine, such as a virtual machine created in VMware. This is called a V2V conversion. For more information, type: Get-Help New-SCV2V.

Examples

Example 1: Create a virtual machine from a virtual hard disk and deploy it on a host

PS C:\> $VHD = Get-SCVirtualHardDisk -Name "Blank Disk - Large"
PS C:\> $VMHost = Get-SCVMHost -ComputerName "VMHost01.Contoso.com"
PS C:\> New-SCVirtualMachine -Name "VM01" -VirtualHardDisk $VHD -VMHost $VMHost -Path "C:\VirtualMachinePath" -RunAsynchronously

The first command gets the virtual hard disk object named Blank Disk - Large from the VMM library, and stores that object in the $VHD variable.

The second command gets the host object named VMHost01, and stores that object in the $VMHost variable.

The last command creates a virtual machine named VM01 from the virtual hard disk stored in $VHD. The command deploys the new virtual machine in C:\VirtualMachinePath on the host named VMHost01. The command specifies the RunAsynchronously parameter. The command returns control to the shell immediately, before the command finishes.

Example 2: Create a virtual machine from a virtual machine template and deploy it on a host

PS C:\> $VMTemplate = Get-SCVMTemplate -VMMServer "VMMServer01.Contoso.com" | where {$_.Name -eq "WindowsServer2008R2"}
PS C:\> $VMHost = Get-SCVMHost -ComputerName "VMHost02.Contoso.com"
PS C:\> New-SCVirtualMachine -VMTemplate $VMTemplate -Name "VM02" -VMHost $VMHost -Path "C:\VirtualMachinePath" -RunAsynchronously -ComputerName "Server01" -FullName "Elisa Daugherty" -OrgName "Contoso" -ProductKey "XXXXX-XXXXX-XXXXX-XXXXX-XXXXX"

The first command gets the virtual machine template object named WindowsServer2008R2, and stores that object in the $Template variable.

The second command gets the host object named VMHost02, and stores that object in the $VMHost variable.

The final command creates a virtual machine from the virtual machine template stored in $Template. The command names the virtual machine VM02. It deploys the virtual machine on host VMHost02 and stores the virtual machine files at C:\VirtualMachinePath. The final command customizes the following properties: the computer name for the virtual machine, the name of the person to whom the virtual machine is registered, the organization name, and the product key. The command specifies the RunAsynchronously parameter. The command returns control to the shell immediately, before the command finishes.

Example 3: Create a virtual machine by cloning an existing virtual machine

PS C:\> $VM = Get-SCVirtualMachine -Name "VM01"
PS C:\> $VMHost = Get-SCVMHost -ComputerName "VMHost01.Contoso.com"
PS C:\> if($VM.Status -eq "PowerOff"){New-SCVirtualMachine -Name "VM03" -VM $VM -VMHost $VMHost -Path "C:\VirtualMachinePath" -RunAsynchronously}

The first command gets the virtual machine object named VM03, and stores that object in the $VM variable.

The second command gets the host object named VMHost03, and stores that object in the $VMHost variable.

The final command checks whether virtual machine VM01 is in a powered off state. If the virtual machine is powered off, the command creates a virtual machine named VM03 from VM01 and deploys the new virtual machine on VMHost03 in C:\VirtualMachinePath.

Example 4: Create a virtual machine from a virtual machine stored in the library

PS C:\> $VMHost = Get-SCVMHost -ComputerName "VMHost04"
PS C:\> $VM = Get-SCVirtualMachine -Name "StoredVM01" | where {$_.LibraryServer.Name -eq "LibServer01.Contoso.com"} | where {$_.Location -eq "\\LibServer01.Consoso.com\MSSCVMMLibrary\StoredVM01"}
PS C:\> New-SCVirtualMachine -VM $VM -Name "VM04" -Description "New virtual machine from virtual machine stored in Library" -Owner "Contoso\ElisaDaugherty" -VMHost $VMHost -Path "C:\VirtualMachinePath" -RunAsynchronously -StartAction NeverAutoTurnOnVM -StopAction SaveVM -MemoryMB 1024

The first command gets the host object named VMHost04, and stores that object in the $VMHost variable.

The second command gets the virtual machine object named StoredVM01 from the specified path on library server LibServer01, and stores the virtual machine object in the $VM variable.

The last command creates a virtual machine named VM04 from StoredVM01 that has 1024 MB of memory. The command deploys it at the specified path. The command also specifies a description and owner, and specifies that the start action for the virtual machine is set to never turn on automatically and that the stop action is to save the virtual machine.

Example 5: Create a highly available virtual machine

PS C:\> $JobGuid = [System.Guid]::NewGuid().ToString()
PS C:\> $VMName = "HAVM01"
PS C:\> New-SCVirtualNetworkAdapter -JobGroup $JobGuid -PhysicalAddressType Dynamic -VLANEnabled $False
PS C:\> New-SCVirtualDVDDrive -JobGroup $JobGuid -Bus 1 -LUN 0
PS C:\> New-SCHardwareProfile -Owner "Contoso\ElisaDaugherty" -Name "HWProfile02" -CPUCount 1 -MemoryMB 512 -HighlyAvailable $True -NumLock $False -BootOrder "CD", "IdeHardDrive", "PxeBoot", "Floppy" -LimitCPUFunctionality $False -JobGroup $JobGuid
PS C:\> New-SCVirtualDiskDrive -IDE -Bus 0 -LUN 0 -JobGroup $JobGuid -Size 40960 -Dynamic -Filename "HAVM01_disk_1.vhd"
PS C:\> $VMHost = Get-SCVMHost | where {$_.Name -eq "VMMHANode02.Contoso.com"}
PS C:\> $HardwareProfile = Get-SCHardwareProfile | where {$_.Name -eq "HWProfile02"}
PS C:\> $OperatingSystem = Get-SCOperatingSystem | where {$_.Name -eq "64-bit edition of Windows Server 2008 R2 Datacenter"}
PS C:\> New-SCVirtualMachine -Name $VMName -Description "" -VMMServer "VMMServer01.Contoso.com" -Owner "Contoso\ElisaDaugherty" -VMHost $VMHost -Path "R:\" -HardwareProfile $HardwareProfile -JobGroup $JobGuid -OperatingSystem $OperatingSystem -RunAsynchronously -StartAction NeverAutoTurnOnVM -StopAction SaveVM

The first command creates a GUID string, and stores it in the $VMGuid variable. This GUID is a job group ID that functions as an identifier that groups subsequent commands that include this identifier into a single job group.

The second command stores the string HAVM01 in the $VMName variable. This string is the name of the new virtual machine.

The third command creates a virtual network adapter that has a dynamic MAC address and has VLAN disabled. Because the command specifies the JobGroup parameter, the network adapter is not created until just before the current cmdlet runs.

The fourth command creates an IDE virtual DVD drive connected to the second channel and the first slot. Because the command specifies the JobGroup parameter, the virtual DVD drive is not created until just before the current cmdlet runs.

The fifth command creates a hardware profile and specifies values for the profile name, owner, CPU count, memory, and bootorder. The command disables NumLock, and also limited CPU functionality. Limited CPU is not needed because this is virtual machine doesl not run an older operating system. This command designates the virtual machine as highly available. Because the command specifies the JobGroup parameter, the hardware profile is not created until just before the current cmdlet runs..

The sixth command creates an IDE virtual disk drive with a storage capacity of 4 GB on the first channel and first slot. Because the command specifies the JobGroup parameter, the new virtual disk drive is not created until just before the current cmdlet runs.

The seventh command gets a virtual machine host object named VMMHANode02, and stores that object in the $VMHost variable. This host is one node of a host cluster that is managed by VMM.

The eighth command gets the hardware profile object named HWProfile02, which was created in the fifth command, and stores that object in the $HardwareProfile variable.

The ninth command gets an operating system object by name, and stores the object in the $OperatingSystem variable.

The final command creates a new highly available virtual machine named HAVM01 by using the objects created and obtained in the previous commands. The command also specifies the Path parameter to specify the location to store the virtual machine. This location must be a cluster-migratable LUN. Additionally, the command specifies that the virtual machine is not started automatically when the host starts and that the virtual machine is put into a saved state when the virtualization service stops.

Example 6: Use an existing VHD file on the destination host to create a new virtual machine from a template

PS C:\> $JobGroupID = [Guid]::NewGuid().ToString()
PS C:\> $VMTemplate = Get-SCVMTemplate | where {$_.Name -eq "VMTemplate01"}
PS C:\> $VMHost = Get-SCVMHost -ComputerName "VMHost06.Contoso.com"
PS C:\> Move-SCVirtualHardDisk -IDE -BUS 0 -LUN 0 -Path "L:\OS.VHD" -JobGroup $JobGroupID
PS C:\> New-SCVirtualMachine -Name "VM06" -Path "L:\" -VMTemplate $VMTemplate -VMHost $VMHost -JobGroup $JobGroupID -UseLocalVirtualHardDisk

The first command generates a GUID, and stores it in the $JobGroupID variable.

The second command gets the virtual machine template object named VMTemplate01, and stores that object in the $Template variable. In this example, VMTemplate01 has a virtual disk drive on IDE Bus 0 LUN 0 that contains a virtual hard disk.

The third command gets the host object named VMHost06, and stores that object in the $VMHost variable.

The fourth command connects the specified virtual hard disk to the first slot (0) of the primary channel (0) on the virtual IDE controller on the virtual machine instead of the default virtual hard disk in the template. The virtual hard disk stored at L:\OS.VHD contains the operating system that runs on the virtual machine. Additionally, this command uses the JobGroup parameter to specify that it will not run until the New-SCVirtualMachine cmdlet triggers the commands in the JobGroup parameter to run.

The final command triggers all commands that contain the $JobGroupID variable to run. The command creates the new virtual machine named VM06 from the template stored in $VMTemplate. The command deploys the virtual machine on the host in $VMHost. The command stores the virtual machine in the root directory of the L: drive. The UseLocalVirtualHardDisk parameter specifies that the command uses an existing hard disk on the host instead of copying a VHD from the library. Therefore, the virtual hard disk associated with the virtual disk drive on the template is replaced with the virtual hard disk drive that exists on the host, L:\OS.VHD. As a result, both the virtual machine and its operating system are stored on the L: drive on the host.

Example 7: Use an existing VHD on the destination host to create a virtual machine from a template, and move another VHD to the new virtual machine

PS C:\> $JobGroupID = [guid]::NewGuid()
PS C:\> $VMTemplate = Get-SCVMTemplate | where {$_.Name -eq "VMTemplate01"}
PS C:\> $VMHost = Get-SCVMHost -ComputerName "VMHost07.Contoso.com"
PS C:\> $VHD = Get-SCVirtualHardDisk -All | where {$_.Name -eq "Other.Vhd"}
PS C:\> Move-SCVirtualHardDisk -IDE -BUS 0 -LUN 0 -Path "L:\OS.VHD" -JobGroup $JobGroupID
PS C:\> New-SCVirtualDiskDrive -VirtualHardDisk $VHD -IDE -BUS 0 -LUN 1 -Path "R:\" -Filename "Other.Vhd" -JobGroup $JobGroupID
PS C:\> New-SCVirtualMachine -Name "VM07" -Path "D:\VirtualMachinePath" -VMTemplate $VMTemplate -VMHost $VMHost -JobGroup $JobGroupID -UseLocalVirtualHardDisk

The first three commands are identical to the first three commands in the previous example. In this example, VMTemplate01 has a virtual disk drive on IDE Bus 0 and LUN 0 that contains a virtual hard disk.

The fourth command gets the virtual hard disk object named Other.VHD. The Get-SCVirtualHardDisk cmdlet can retrieve virtual hard disk objects from a virtual machine, from a template, or from a stand-alone file stored in the VMM library. Specifying the All parameter retrieves a full list of all the subordinate objects independent of the parent object. In this case, the command retrieves all the available virtual hard disk objects, and then selects Other.VHD.

The fifth command connects the specified virtual hard disk to the first slot (0) of the primary channel (0) on the virtual IDE controller on the virtual machine instead of the default virtual hard disk in the template. The virtual hard disk stored at L:\OS.VHD contains the operating system that will start on the virtual machine. Additionally, this command specifies the JobGroup parameter to specify that it does not run until the current cmdlet triggers the commands in the JobGroup list to run.

The sixth command creates a virtual disk drive object and attaches the virtual hard disk object stored in $VHD to IDE Bus 0 and LUN 1 on the new drive. The command specifies the Path parameter to store the virtual hard disk object in $VHD in the root directory of the R drive on the virtual machine, and it specifies that its name is Other.VHD. Additionally, this command uses the JobGroup parameter to specify that it will not run until the last command triggers the commands in the JobGroup list to run.

The last command triggers all commands that contain the $JobGroupID variable to run. The command creates the virtual machine named VM07 from the template stored in $VMTemplate. The command deploys the virtual machine on the host specified in $VMHost. The command stores the virtual machine in the D:\VirtualMachinePath folder. The UseLocalVirtualHarddisk parameter specifies that the commmand uses an existing hard disk on the host instead of copying a VHD from the library. Therefore, the virtual hard disk associated with the virtual disk drive on the template is replaced with the virtual hard disk drive that exists on the host, L:\OS.VHD. As a result, the path of the virtual machine is D:\VirtualMachinePath\VM07, the path of the operating system is L:\OS.VHD, and the path of the other virtual hard disk is R:\Other.VHD.

Example 8: Create a Linux-based virtual machine from a virtual machine template and deploy it on a host

Caution

This article references CentOS, a Linux distribution that has reached End Of Life (EOL) status. Please consider your use and planning accordingly. For more information, see the CentOS End Of Life guidance.

PS C:\> $VMTemplate = Get-SCVMTemplate -VMMServer "VMMServer01.Contoso.com" | Where-Object {$_.Name -eq "CentOSConfigurable"}
PS C:\> $VMHost = Get-SCVMHost -ComputerName "VMHost02.Contoso.com"
PS C:\> $Cred = Get-Credential
PS C:\> New-SCVirtualMachine -VMTemplate $VMTemplate -Name "MyCentOSVM" -RunAsynchronously -ComputerName "MyCentOSVM" -LinuxDomainName "Contoso.com" -LocalAdministratorCredential $Cred -VMHost $VMhost -Path "C:\VirtualMachinePath"

The first command gets the virtual machine template object named CentOSConfigurable, and stores that object in the $Template variable.

The second command gets the host named VMHost02, and stores that object in the $VMHost variable.

The third command gets a credential, and stores that object in the $Cred variable. This credential is for the root account.

The final command creates a virtual machine from the virtual machine template stored in $Template. The command name the virtual machine MyCentOSVM. It deploys the virtual machine on the host named VMHost02 and stores its files at C:\VirtualMachinePath. The final command customizes the following properties: the computer name for the virtual machine, the Linux dnsdomainname, and the root account password.

Parameters

-AnswerFile

Specifies a script object stored in the VMM library to use as an answer file. The name of the answer file script depends on the operating system that you want to install on a virtual machine:

  • Sysprep.inf. Windows XP, Windows Server 2000, or Windows Server 2003
  • Unattend.xml. Windows Vista, Windows 7, or Windows Server 2008

Parameter properties

Type:Script
Default value:None
Supports wildcards:False
DontShow:False
Aliases:SysPrepFile

Parameter sets

NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

-AutomaticCriticalErrorAction

Specifies the action to take when the VM encounters a critical error, and exceeds the timeout duration specified by the AutomaticCriticalErrorActionTimeout parameter. The acceptable values for this parameter are: Pause and None.

Parameter properties

Type:UInt16
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromHWProfile
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVirtualDisk
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-AutomaticCriticalErrorActionTimeout

Specifies the amount of time, in minutes, to wait in critical pause before powering off the virtual machine.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromHWProfile
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVirtualDisk
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-BlockDynamicOptimization

Indicates whether dynamic optimization is blocked for a virtual machine.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:ExcludeFromPRO

Parameter sets

NewVmFromHWProfile
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVirtualDisk
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-CapabilityProfile

Specifies a capability profile object.

Parameter properties

Type:CapabilityProfile
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromVmCloud
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-CheckpointType

Specifies the checkpoint type. The acceptable values for this parameter are:

  • Disabled
  • Production
  • ProductionOnly
  • Standard

Parameter properties

Type:CheckpointType
Default value:None
Accepted values:Disabled, Production, ProductionOnly, Standard
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromHWProfile
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVirtualDisk
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Cloud

Specifies a private cloud object.

Parameter properties

Type:Cloud
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromVmCloud
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-ComputerName

Specifies the name of a computer that VMM can uniquely identify on your network. Valid formats are:

  • FQDN (fully qualified domain name)
  • IPv4 or IPv6 address
  • NetBIOS name

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromComputerTierScaleOut
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-ComputerTier

Specifies a computer tier object.

Parameter properties

Type:ComputerTier
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromComputerTierScaleOut
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-CPUCount

Specifies the number of CPUs on the virtual machine. The following hosts support the following number of processors:

  • Hyper-V. Up to four CPUs per virtual machine, depending on guest operating system.
  • VMware ESX. Up to four CPUs per virtual machine for any supported guest operating system, except one CPU on a virtual machine that runs Windows NT 4.0.
  • Citrix XenServer. Up to eight CPUs per virtual machine, depending on guest operating system.

Parameter properties

Type:Byte
Default value:None
Supports wildcards:False
DontShow:False
Aliases:ProcessorCount

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-CPUCyclesLimitPercent

Specifies the limit of CPU cycles as a percentage.

Parameter properties

Type:UInt16
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-CPUCyclesReservePercent

Specifies the reserve CPU cycles as a percentage.

Parameter properties

Type:UInt16
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-CPULimitForMigration

Indicates whether to limit processor features for the specified virtual machine in order to enable migration to a physical computer that has a different version of the same processor as the source computer. VMM does not support migrating virtual machines between physical computers that have processors from different manufacturers.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:LimitCPUForMigration

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-CPULimitFunctionality

Indicates whether to provide limited CPU functionality for the virtual machine. Specify a value of $True to support an older operating system, such as Windows NT 4.0, on a virtual machine deployed on a Hyper-V host or on a VMware ESX host.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False
Aliases:LimitCPUFunctionality

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-CPUPerVirtualNumaNodeMaximum

Specifies the maximum number of CPUs allowed for each virtual NUMA node.

Parameter properties

Type:Byte
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-CPURelativeWeight

Specifies the amount of CPU resources on a host that this virtual machine can use relative to other virtual machines on the same host. A virtual machine with a higher weight value is allocated more CPU resources than a virtual machine with a lower weight value. The VMware term for these values is shares. Types of hosts support the following relative values:

  • Hyper-V. 1 to 10000.
  • VMware ESX. High. 2000.
  • VMware ESX. Above Normal. 1500.
  • VMware ESX. Normal (default). 1000.
  • VMware ESX. Below Normal. 750.
  • VMware ESX. Low. 500.
  • VMware ESX. Custom 1 to 1000000.
  • Citrix XenServer. 1 to 65536, normal is 256.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False
Aliases:RelativeWeight

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-CPUType

Specifies the type of CPU for a virtual machine. To retrieve a list of all CPU types that are available for use in virtual machines in a VMM environment, see the Get-SCCPUType cmdlet.

Parameter properties

Type:ProcessorType
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-DelayStartSeconds

Specifies the number of seconds to wait after the virtualization service starts before automatically starting a virtual machine. This delay staggers the startup time of multiple virtual machines to help reduce the demand on physical computer resources. A typical setting might be 30 to 60 seconds. The maximum configurable delay for hosts is as follows:

  • Hyper-V. 1000000000 seconds (277777 hours)
  • VMware ESX. 65535 seconds (18 hours)

This parameter does not apply to XenServer virtual machines.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False
Aliases:DelayStart

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Description

Specifies a description for the virtual machine.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Domain

Specifies an FQDN for an Active Directory domain.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False
Aliases:JoinDomain

Parameter sets

NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-DomainJoinCredential

Specifies the user name and password of an account that has permission to join a computer to the domain. We recommend that you use a limited rights account joining computers to the domain. This includes both virtual and physical computers.

You can use the current parameter to specify credentials on a VMHostProfile for joining a physical host computer to the domain, or to specify credentials, on a new or existing template, on a new or existing guest operating system profile, or on a new virtual machine, for joining a virtual machine to the domain.

Parameter properties

Type:VMMCredential
Default value:None
Supports wildcards:False
DontShow:False
Aliases:JoinDomainCredential

Parameter sets

NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-DRProtectionRequired

This parameter is reserved for future use.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromHWProfile
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVirtualDisk
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-DynamicMemoryBufferPercentage

Specifies the percentage of memory above the current memory allocation of a virtual machine which the host should try to reserve as a buffer. The default value is 20.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-DynamicMemoryEnabled

Indicates whether to enable dynamic memory for virtual machines. You can enable dynamic memory directly on a virtual machine, or on a template or hardware profile that is used to create virtual machines. The default value is $False.

You can enable dynamic memory for a virtual machine only if that virtual machine is deployed on a host that runs Windows Server 2008 SP1 or a later version or if the virtual machine is stored in a library in a stopped state. Hardware changes to a stored virtual machine can only be made if the virtual machine does not have snapshots. Enabling dynamic memory on a virtual machine stored in a library limits placement of that machine to hosts that run Windows Server 2008 SP1 or a later version.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-DynamicMemoryMaximumMB

Specifies the maximum amount of memory that a host can allocate to a virtual machine, if dynamic memory is enabled. The default value is 65536.

You can enable dynamic memory for a virtual machine only if that virtual machine is deployed on a host that runs Windows Server 2008 SP1 or a later version or if the virtual machine is stored in a library in a stopped state. Hardware changes to a stored virtual machine can only be made if the virtual machine does not have snapshots. Enabling dynamic memory on a virtual machine stored in a library limits placement of that machine to hosts that run Windows Server 2008 SP1 or a later version.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-DynamicMemoryMinimumMB

Specifies the minimum amount of memory that the host can allocate to a virtual machine if dynamic memory is enabled. The default value is 65536.

You can enable dynamic memory for a virtual machine only if that virtual machine is deployed on a host that runs Windows Server 2008 SP1 or a later version or if the virtual machine is stored in a library in a stopped state. Hardware changes to a stored virtual machine can only be made if the virtual machine does not have snapshots. Enabling dynamic memory on a virtual machine stored in a library limits placement of that machine to hosts that run Windows Server 2008 SP1 or a later version.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-EnableNestedVirtualization

Enables the nested virtualization.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-FullName

Specifies the name of the person in whose name this cmdlet registers a virtual machine.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Generation

Specifies a value for the generation of the new virtual machine.

Parameter properties

Type:Int32
Default value:1
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromHWProfile
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVirtualDisk
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewStoredVmFromVirtualDisk
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewStoredVmFromHardwareProfile
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-GuestOSProfile

Specifies a guest operating system profile object.

Parameter properties

Type:GuestOSProfile
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

-GuiRunOnceCommands

Specifies an array of commands to add to the [GuiRunOnce] section of an unattended answer file. Use single quotation marks around each string enclosed in double quotation marks.

Example format: -GuiRunOnceCommands '"C:\APF\APFPostSysPrepCopy.cmd PARAMS1"', '"C:\APF\APFPostSysPrepCopy.cmd PARAMS1"'

For information about how Windows PowerShell uses quotation marks, type Get-Help about_Quoting_Rules.

Parameter properties

Type:

String[]

Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-HardwareProfile

Specifies a hardware profile object.

Parameter properties

Type:HardwareProfile
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

-HighlyAvailable

Indicates whether to place a virtual machine on a Hyper-V host that is part of a host cluster. Configure this setting on a virtual machine, or on a template or hardware profile that is used to create virtual machines.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromHWProfile
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVirtualDisk
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-JobGroup

Specifies an identifier for a series of commands that run as a set just before the final command that includes the same job group identifier runs.

Parameter properties

Type:Guid
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-JobVariable

Specifies the name of a variable for job progress.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-LibraryServer

Specifies a VMM library server object.

Parameter properties

Type:LibraryServer
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewStoredVmFromVirtualDisk
Position:Named
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False
NewStoredVmFromVm
Position:Named
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False
NewStoredVmFromHardwareProfile
Position:Named
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

-LinuxAdministratorSSHKey

Specifies the public key file for a Linux SSH Key.

Parameter properties

Type:SSHKey
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-LinuxAdministratorSSHKeyString

Specifies a Linux administrator SSH key as a string.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-LinuxDomainName

Specifies an FQDN for Linux operating system specialization.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-LocalAdministratorCredential

Specifies the user name and password for the Local Administrator account or Linux root account for a Linux-compatible Guest Operating System profile).

This cmdlet specifies these credentials on a new or existing template, on a new or existing guest operating system profile, or on a new virtual machine overrides any existing Administrator password.

Parameter properties

Type:VMMCredential
Default value:None
Supports wildcards:False
DontShow:False
Aliases:AdminPasswordCredential

Parameter sets

NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-MemoryMB

Specifies the amount of random access memory (RAM), in megabytes (MB), on the host that is allocated to a virtual machine. The default value is 512 MB. For a virtual machine on which dynamic memory is enabled, specify the startup memory value. The maximum assignable host memory is as follows:

  • Hyper-V. Up to 65536 MB RAM per virtual machine
  • VMware ESX Server 3.0.x Up to 16384 MB RAM per virtual machine
  • VMware ESX Server 3.5.x. Up to 65532 MB RAM per virtual machine
  • Citrix XenServer. Up to 32265 MB RAM per virtual machine

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-MemoryPerVirtualNumaNodeMaximumMB

Specifies the maximum amount of memory, in megabytes, that the host allows each virtual NUMA node.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-MemoryWeight

Specifies the priority for allocating memory to a virtual machine, relative to other virtual machines on the same host. The host allocates more memory to a virtual machine that has a higher value than a virtual machine with a lower setting. For a host that runs Windows Server 2008 R2 SP1 or a later version, the following are defaults:

  • Low. 0
  • Normal. 5000
  • High. 10,000
  • Custom. 10,000

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-MergeAnswerFile

Indicates whether this cmdlet merges the answer file together with guest operating system settings. The default value is $True. VMM console uses this parameter. Do not specify this parameter.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-MonitorMaximumCount

Specifies the maximum number of monitors that a virtual video adapter supports.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-MonitorMaximumResolution

Specifies a value, as a string, that represents the maximum possible monitor resolution of a virtual video adapter. Valid values are:

  • 1024x768
  • 1280x1024
  • 1600x1200
  • 1920x1200

The default value is 1280x1024.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False
Aliases:MonitorResolutionMaximum

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Name

Specifies the name of the new virtual machine.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:0
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-NumaIsolationRequired

Indicates whether NUMA isolation is required.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-OnBehalfOfUser

Specifies a user name. This cmdlet operates on behalf of the user that this parameter specifies.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-OnBehalfOfUserRole

Specifies a user role. To obtain a user role, use the Get-SCUserRole cmdlet. This cmdlet operates on behalf of the user role that this parameter specifies.

Parameter properties

Type:UserRole
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-OperatingSystem

Specifies the type of operating system for a virtual machine. To list the names of all available operating systems in VMM, use the Get-SCOperatingSystem cmdlet.

Parameter properties

Type:OperatingSystem
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-OrganizationName

Specifies the name of the organization for the person in whose name this cmdlet registers the virtual machine.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False
Aliases:OrgName

Parameter sets

NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Owner

Specifies the owner of a virtual machine as a valid domain user account.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-Path

Specifies the destination path for the new virtual machine.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromHWProfile
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromTemplate
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVm
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVirtualDisk
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-ProductKey

Specifies a product key. The product key is a 25-digit number that identifies the product license. A product key can be used to register VMM or an operating system to be installed on a virtual machine or host.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-ProtectionProvider

Specifies a protection provider.

Parameter properties

Type:ProtectionProvider
Default value:None
Accepted values:None, HVR8, HVRBlue, HVRAzure, DiskReplication, SANReplication
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromHWProfile
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVirtualDisk
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-PROTipID

Specifies the ID of the Performance and Resource Optimization tip (PRO tip) that triggered this action. This parameter lets you audit PRO tips.

Parameter properties

Type:Guid
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-RecoveryPointObjective

Specifies the maximum period for which it is tolerable to lose data from an IT service due to a major incident.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromHWProfile
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVirtualDisk
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-ReplicationGroup

Specifies a replication group.

Parameter properties

Type:ReplicationGroup
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromHWProfile
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVirtualDisk
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-ReturnImmediately

Indicates that control is returned to the calling process immediately, before the job is created.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-RunAsynchronously

Indicates that the job runs asynchronously so that control returns to the command shell immediately.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-SecureBootEnabled

The New-SCVirtualMachine cmdlet creates a virtual machine that Virtual Machine Manager (VMM) manages. You can create a virtual machine from the following sources:

  • A stopped virtual machine deployed on a host.
  • A virtual machine stored in the VMM library.
  • A virtual machine template.
  • A virtual hard disk that already contains an operating system. You can create a virtual machine from an existing hard disk that contains a third-party operating system, such as Linux.
  • A blank virtual hard disk.

In System Center, you can create a virtual machine by using a differencing disk. For more information about differencing disks, see New-SCVirtualDiskDrive.

When you deploy a new virtual machine to a Hyper-V host, you can specify a location for the virtual machine files, or use the default path: <C>:\ProgramData\Microsoft\Windows\Hyper-V. When you deploy a virtual machine on a VMware ESX host or Citrix XenServer host, there is no default path. Specify a path.

As an alternative to the current cmdlet, you can create a virtual machine by using the following cmdlet:

  • New-SCV2V creates a virtual machine from an existing virtual machine, such as a virtual machine created in VMware. This is called a V2V conversion. For more information, type: Get-Help New-SCV2V.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-SecureBootTemplate

The New-SCVirtualMachine cmdlet creates a virtual machine that Virtual Machine Manager (VMM) manages. You can create a virtual machine from the following sources:

  • A stopped virtual machine deployed on a host.
  • A virtual machine stored in the VMM library.
  • A virtual machine template.
  • A virtual hard disk that already contains an operating system. You can create a virtual machine from an existing hard disk that contains a third-party operating system, such as Linux.
  • A blank virtual hard disk.

In System Center, you can create a virtual machine by using a differencing disk. For more information about differencing disks, see New-SCVirtualDiskDrive.

When you deploy a new virtual machine to a Hyper-V host, you can specify a location for the virtual machine files, or use the default path: <C>:\ProgramData\Microsoft\Windows\Hyper-V. When you deploy a virtual machine on a VMware ESX host or Citrix XenServer host, there is no default path. Specify a path.

As an alternative to the current cmdlet, you can create a virtual machine by using the following cmdlet:

  • New-SCV2V creates a virtual machine from an existing virtual machine, such as a virtual machine created in VMware. This is called a V2V conversion. For more information, type: Get-Help New-SCV2V.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-SelfServiceRole

Specifies the self-service role that has permission to access the virtual machine.

Parameter properties

Type:SelfServiceUserRole
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromVmCloud
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-SharePath

Specifies a path of a valid library share on an existing library server that uses a Universal Naming Convention (UNC) path.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewStoredVmFromVirtualDisk
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewStoredVmFromVm
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewStoredVmFromHardwareProfile
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-SkipInstallVirtualizationGuestServices

Indicates that this cmdlet does not install virtualization guest services on the virtual machine. The default value is $False, and VMM installs the appropriate virtualization guest service automatically.

For a virtual machine on a Hyper-V host, the virtualization guest service is called Integration Components or VMGuest.iso. For a virtual machine on a XenServer host, the virtualization guest service is called Citrix Tools for Virtual Machines or xs-tools.iso. Virtual machines on a VMware ESX host do not use a virtualization guest service.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-StartAction

Specifies the behavior of a virtual machine when the virtualization service starts. Valid values are:

  • AlwaysAutoTurnOnVM
  • NeverAutoTurnOnVM
  • TurnOnVMIfRunningWhenVSStopped

Parameter properties

Type:VMStartAction
Default value:None
Accepted values:NeverAutoTurnOnVM, AlwaysAutoTurnOnVM, TurnOnVMIfRunningWhenVSStopped
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-StartVM

Indicates that the virtual machine starts when it arrives at the destination host.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromHWProfile
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmCloud
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVm
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVirtualDisk
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-StopAction

Specifies the behavior of the virtual machine when the virtualization service stops. Valid values are:

  • SaveVM
  • TurnOffVM
  • ShutdownGuestOS.

Parameter properties

Type:VMStopAction
Default value:None
Accepted values:SaveVM, TurnOffVM, ShutdownGuestOS
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-StoreToLibrary

Indicates that this cmdlet stores the virtual machine in the VMM library.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromVmCloud
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-TimeZone

Specifies a number that identifies a geographical region that shares the same standard time. For a list of time zone indexes, see Microsoft Time Zone Index Values (http://go.microsoft.com/fwlink/?LinkId=120935) on the Microsoft Developer Network. If you do not specify a time zone, the default time zone is the same time zone setting that is on the virtual machine host.

Parameter properties

Type:Int32
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-UseDiffDiskOptimization

Indicates that this cmdlet uses differencing disk optimization.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-UseLocalVirtualHardDisk

Indicates that this cmdlet verifies that the VHD files that this cmdlet must have to create the virtual machine exist and are stored on the destination host.

Parameter properties

Type:SwitchParameter
Default value:None
Supports wildcards:False
DontShow:False
Aliases:UseLocalVirtualHardDisks

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-UserRole

Specifies a user role object.

Parameter properties

Type:UserRole
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-VirtualHardDisk

Specifies a virtual hard disk object.

Parameter properties

Type:StandaloneVirtualHardDisk
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromVirtualDisk
Position:Named
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False
NewStoredVmFromVirtualDisk
Position:Named
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

-VirtualNumaNodesPerSocketMaximum

Specifies the maximum number of NUMA nodes allowed for each socket.

Parameter properties

Type:Byte
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-VirtualVideoAdapterEnabled

Indicates whether to enable the Microsoft Synthetic 3D Virtual Video Adapter for the virtual machine. You can enable the Virtual Video Adapter directly on a virtual machine, or on a template or hardware profile that is used to create virtual machines.

You can enable the Microsoft Synthetic 3D Virtual Video Adapter for a virtual machine only if that virtual machine is deployed on a host that runs Windows Server 2008 R2 SP1, or a later version, that have the Remote Desktop Services role and Remote Desktop Virtual Graphics role service installed, or if the virtual machine is stored in a library in a stopped state. Hardware changes to a stored virtual machine can only be made if the virtual machine does not have snapshots. Enabling the Microsoft Synthetic 3D Virtual Video Adapter on a virtual machine stored in a library limits placement of that machine to hosts that run Windows Server 2008 R2 SP1, or a later version, that have the Remote Desktop Services role and Remote Desktop Virtual Graphics role service installed.

Parameter properties

Type:Boolean
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-VM

Specifies a virtual machine object.

Parameter properties

Type:VM
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromVmCloud
Position:Named
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVm
Position:Named
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False
NewStoredVmFromVm
Position:Named
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

-VMConfiguration

Specifies a virtual machine configuration object.

Parameter properties

Type:BaseVMConfiguration
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromVmConfig
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-VMConfigurationScaleOut

Specifies a virtual machine configuration object that is used when scaling out a service.

Parameter properties

Type:BaseVMConfiguration
Default value:None
Supports wildcards:False
DontShow:False
Aliases:ScaleOutVMConfiguration

Parameter sets

NewVmFromVmConfigScaleOut
Position:Named
Mandatory:True
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-VMHost

Specifies a virtual machine host object. VMM supports Hyper-V hosts, VMware ESX hosts, and Citrix XenServer hosts. For more information about each type of host, see the Add-SCVMHost cmdlet.

Parameter properties

Type:Host
Default value:None
Supports wildcards:False
DontShow:False
Aliases:Host

Parameter sets

NewVmFromHWProfile
Position:Named
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromTemplate
Position:Named
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVm
Position:Named
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVirtualDisk
Position:Named
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

-VMMServer

Specifies a VMM server object.

Parameter properties

Type:ServerConnection
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

(All)
Position:Named
Mandatory:False
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

-VMShieldingData

Specifies a VMShieldingData object.

Parameter properties

Type:KeyFile
Default value:None
Supports wildcards:False
DontShow:False

Parameter sets

NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

-VMTemplate

Specifies a VMM template object that this cmdlet uses to create virtual machines.

Parameter properties

Type:Template
Default value:None
Supports wildcards:False
DontShow:False
Aliases:Template

Parameter sets

NewVmFromTemplate
Position:Named
Mandatory:True
Value from pipeline:True
Value from pipeline by property name:False
Value from remaining arguments:False

-Workgroup

Specifies the name of the workgroup to which to join the virtual machine. You can use this parameter to override the existing value on a template or on a guest operating system profile.

Parameter properties

Type:String
Default value:None
Supports wildcards:False
DontShow:False
Aliases:JoinWorkgroup

Parameter sets

NewVmFromTemplate
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False
NewVmFromVmConfig
Position:Named
Mandatory:False
Value from pipeline:False
Value from pipeline by property name:False
Value from remaining arguments:False

CommonParameters

This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutBuffer, -OutVariable, -PipelineVariable, -ProgressAction, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters.

Outputs

VirtualMachine

This cmdlet returns a VirtualMachine object.

Notes

  • This cmdlet requires a VMM virtual hard disk object, virtual machine template object, or virtual machine object. To obtain such an object, use the Get-SCVirtualHardDisk, Get-SCVMTemplate, or Get-SCVirtualMachine cmdlet.