Set-SCPhysicalComputerProfile

Modifies a physical computer profile object.

Syntax

Set-SCPhysicalComputerProfile [[-Name] <String>] [-AnswerFile <Script>] [-Baseline <Baseline[]>]
 [-BypassVHDConversion <Boolean>] [-CodeIntegrityPolicy <CodeIntegrityPolicy>]
 [-ComputerAccessRunAsAccount <RunAsAccount>] [-Description <String>] [-DiskConfiguration <String>]
 [-Domain <String>] [-DomainJoinRunAsAccount <RunAsAccount>]
 [-DriverMatchingTag <System.Collections.Generic.List`1[System.String]>] [-FullName <String>]
 [-GuiRunOnceCommands <String[]>] [-IsGuarded <Boolean>] [-JobGroup <Guid>] [-JobVariable <String>]
 [-LocalAdministratorCredential <VMMCredential>] [-OrganizationName <String>] [-Owner <String>]
 [-PROTipID <Guid>] [-PhysicalComputerNetworkAdapterProfile <PhysicalComputerNetworkAdapterProfile[]>]
 -PhysicalComputerProfile <PhysicalComputerProfile> [-ProductKey <String>] [-RemoveAnswerFile]
 [-RemoveGuiRunOnceCommands] [-RunAsynchronously] [-TimeZone <Int32>] [-VMMServer <ServerConnection>]
 [-VMPaths <String>] [-VirtualHardDisk <VirtualHardDisk>] [<CommonParameters>]

Description

The Set-SCPhysicalComputerProfile cmdlet modifies a physical computer profile object.

Examples

Example 1: Modify a physical computer profile

PS C:\> $PhysicalComputerProfile = Get-SCPhysicalComputerProfile -ID "d1ce0773-4f50-4f12-a244-38a5a35c5326" 
PS C:\> Set-SCPhysicalComputerProfile -PhysicalComputerProfile $PhysicalComputerProfile -RunAsynchronously -Name "Windows Server 2016"

The first command stores the physical computer profile that has the specified ID in the $PhysicalComputerProfile variable.

The second command modifies the name of the physical computer profile to be Windows Server 2016.

Parameters

-AnswerFile

Specifies a script object stored in the Virtual Machine Manager (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

Type:Script
Required:False
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-Baseline

Specifies an array of Baseline objects.

Type:Baseline[]
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-BypassVHDConversion

Indicates whether a dynamic VHD attached to a host profile is converted to a fixed type during deployment.

Type:Boolean
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-CodeIntegrityPolicy

Specifies a code integrity policy.

Type:CodeIntegrityPolicy
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-ComputerAccessRunAsAccount

Specifies the computer access Run As account to use to deploy the computer. This run as account is added to the machine as a local administrator and used to manage the machine.

Type:RunAsAccount
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Description

Specifies a description for the computer profile.

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-DiskConfiguration

Specifies the disk and partition configuration for the physical computer that is to be deployed with Windows Hyper-V.

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Domain

Specifies a fully qualified domain name (FQDN) for an Active Directory domain.

Example format: -Domain "Domain01.Corp.Contoso.com"

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-DomainJoinRunAsAccount

Specifies a Run As account that has permission to join the specified domain.

Type:RunAsAccount
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-DriverMatchingTag

Specifies the custom tags to match with driver properties during deployment. When tags are specified, the deployment process matches the tags specified in the host profile with the tags in the drivers in order to download matching drivers and install them in the target image.

Type:System.Collections.Generic.List`1[System.String]
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-FullName

Specifies the name of the person in whose name a virtual machine is registered.

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters: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.

Type:String[]
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-IsGuarded

Indicates that the host needs to be a Guarded Host.

Type:Boolean
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-JobGroup

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

Type:Guid
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-JobVariable

Specifies that job progress is tracked and stored in the variable named by this parameter.

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-LocalAdministratorCredential

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

Specifying 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.

Type:VMMCredential
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Name

Specifies the name of a VMM object.

Type:String
Required:False
Position:0
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-OrganizationName

Specifies the name of the organization for the person in whose name a virtual machine is registered.

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-Owner

Specifies the owner of a VMM object in the form of a valid domain user account.

- Example format: -Owner "Contoso\PattiFuller"

  • Example format: -Owner "PattiFuller@Contoso"

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters: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.

Type:Guid
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-PhysicalComputerNetworkAdapterProfile

Specifies an array of physical computer network adapter profile objects.

Type:PhysicalComputerNetworkAdapterProfile[]
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-PhysicalComputerProfile

Specifies a profile that is used to deploy an operating system to a computer.

Type:PhysicalComputerProfile
Required:True
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters: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.

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-RemoveAnswerFile

Removes the answer file from the host profile.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-RemoveGuiRunOnceCommands

Removes the GUI Run Once Commands property from the host profile.

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-RunAsynchronously

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

Type:SwitchParameter
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-TimeZone

Specifies a number (an index) that identifies a geographical region that shares the same standard time. For a list of time zone indexes, see Microsoft Time Zone Index Values at http://go.microsoft.com/fwlink/?LinkId=120935. If no time zone is specified, the default time zone used for a virtual machine is the same time zone setting that is on the virtual machine host.

Example format to specify the GMT Standard Time zone: -TimeZone 085

Type:Int32
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-VMMServer

Specifies a VMM server object.

Type:ServerConnection
Required:False
Position:Named
Default value:None
Accept pipeline input:True (ByValue)
Accept wildcard characters:False
-VMPaths

Specifies a set of default paths (as strings separated by the pipeline operator) on a host where virtual machine files can be stored.

Example format: -VMPaths "C:\Folder1|C:\Folder2|C:\Folder3"

Type:String
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False
-VirtualHardDisk

Specifies a virtual hard disk object.

Type:VirtualHardDisk
Required:False
Position:Named
Default value:None
Accept pipeline input:False
Accept wildcard characters:False

Outputs

PhysicalComputerProfile

This cmdlet returns a **PhysicalComputerProfile** object.