New-SCRunAsAccount

Creates a Run As account.

Description

The New-SCRunAsAccount cmdlet creates a Run As accont in System Center Virtual Machine Manager (VMM).

For more information about New-SCRunAsAccount, type: "Get-Help New-SCRunAsAccount -online".

Parameters

Name

Required? true
Accept Pipeline Input? false
Position? 0
Specifies the name of a VMM object.

Credential

Required? true
Accept Pipeline Input? true (ByValue)
Position? named
Specifies a credential object or, for some cmdlets, a Run As account object that contains the user name and password of an account that has permission to perform this action. Or, in the case of Restart-SCJob, has permission to complete a restarted task. 

For more information about the PSCredential object, type: "Get-Help Get-Credential". 
For more information about Run As accounts, type: "Get-Help New-SCRunAsAccount".

Description

Required? false
Accept Pipeline Input? false
Position? named
States a description for the specified object.

JobGroup

Required? false
Accept Pipeline Input? false
Position? named
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. 

JobVariable

Required? false
Accept Pipeline Input? false
Position? named
Specifies that job progress is tracked and stored in the variable named by this parameter. 

NoValidation

Required? false
Accept Pipeline Input? false
Position? named
Indicates that the Run As account will not validate the provided domain credentials.

Owner

Required? false
Accept Pipeline Input? false
Position? named
Specifies the owner of a VMM object in the form of a valid domain user account.

Example format: -Owner "Contoso\ReneeLo"
Example format: -Owner "ReneeLo@Contoso"

PROTipID

Required? false
Accept Pipeline Input? false
Position? named
Specifies the ID of the PRO tip that triggered this action. This allows for auditing of PRO tips.

RunAsynchronously

Required? false
Accept Pipeline Input? false
Position? named
Indicates that the job runs asynchronously so that control returns to the command shell immediately. 

UserRole

Required? false
Accept Pipeline Input? false
Position? named
Specifies a user role object.

VMMServer

Required? false
Accept Pipeline Input? true (ByValue)
Position? named
Specifies a VMM server object.

Examples

1: Create a Run As account.
PS C:\> $Creds = Get-Credential
PS C:\> $RunAsAccount = New-SCRunAsAccount -Name "RunAsAccount01" -Credential $Creds
The first command uses the Get-Credential cmdlet to prompt you to supply a user name and password and stores the credentials in the $Credential variable. 

The second command creates a Run As account named RunAsAccount01 using the credentials provided in $Creds.

See Also