Add-SCVirtualizationManager
Adds a VMware vCenter Server to VMM.
Syntax
Default (Default)
Add-SCVirtualizationManager
[-VMMServer <ServerConnection>]
[-ComputerName] <String>
[-Description <String>]
-Credential <VMMCredential>
[-TCPPort <UInt32>]
[-Certificate <ClientCertificate>]
[-EnableSecureMode <Boolean>]
[-RunAsynchronously]
[-PROTipID <Guid>]
[-JobVariable <String>]
[<CommonParameters>]
Description
The Add-SCVirtualizationManager cmdlet adds a VMware vCenter Server to your Virtual Machine Manager (VMM) environment so that VMM can connect to the vCenter Server and import its data. After you add the vCenter Server to VMM, you need to add the VMware ESX hosts associated with the vCenter Server before VMM can manage the virtual machines deployed on those hosts.
The default port used to connect to a VMware VirtualCenter Server computer is TCP port 443.
Examples
Example 1: Add a VMware vCenter Server to VMM
PS C:\> $RunAsAccount = Get-SCRunAsAccount -Name "RunAsAccount03"
PS C:\> $Cert = Get-SCCertificate -ComputerName "vCenterServer01.Contoso.com"
PS C:\> Add-SCVirtualizationManager -ComputerName "vCenterServer01.Contoso.com" -Certificate $Cert -TCPPort 443 -Credential $RunAsAccount
The first command gets the Run As account object named RunAsAccount03 and stores the object in the $RunAsAccount variable. The required credentials for this operation are either a local Administrator account or a domain account with administrator rights on the vCenter Server that you want to add as a virtualization manager to VMM.
The second command obtains the security certificate from vCenterrServer01 and stores it in the $Cert variable.
The last command adds the virtualization manager object named vCenterServer01 to the VMM database, imports the security certificate object, and specifies that VMM will use TCP port 443 (the default port) to connect to that server. As the last command is processed, $Credential provides your Run As credentials to Add-SCVirtualizationManager.
Example 2: Add multiple VMware vCenter Servers to VMM
PS C:\> $Credential = Get-SCRunAsAccount -Name "RunAsAccount03"
PS C:\> $Servers = "vCenterServer01.Contoso.com", "vCenterServer02.Contoso.com"
PS C:\> ForEach ($Server in $Servers) {$Cert = Get-SCCertificate -ComputerName $Server; Add-SCVirtualizationManager -ComputerName $Server -Certificate $Cert -TCPPort 443 -Credential $Credential}
The first command gets the Run As account object named RunAsAccount03 and stores the object in the $RunAsAccount variable. The required credentials for this operation are either a local Administrator account or a domain account with administrator rights on the vCenter Server that you want to add as a virtualization manager to VMM.
The second command stores the strings "vCenterServer01.Contoso.com" and "vCenterServer02.Contoso.com", which are the names of two VMware vCenter Servers, in the $Servers variable.
The last command adds the two servers to VMM and specifies that VMM will import the security certificates and use TCP port 443 (the default port) to connect to the virtualization manager service on vCenterServer01 and vCenterServer02. As this command is processed, $Credential provides your Run As credentials to Add-SCVirtualizationManager.
For more information about the standard Windows PowerShell ForEach loop statement, type Get-Help about_ForEach
.
Parameters
-Certificate
Specifies a security certificate object.
Parameter properties
Type: | ClientCertificate |
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 |
-ComputerName
Specifies the name of a computer that VMM can uniquely identify on your network. The acceptable values for this parameter are:
- FQDN
- IPv4 or IPv6 address
- NetBIOS name
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 |
-Credential
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
.
Parameter properties
Type: | VMMCredential |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Parameter sets
(All)
Position: | Named |
Mandatory: | True |
Value from pipeline: | True |
Value from pipeline by property name: | False |
Value from remaining arguments: | False |
-Description
Specifies a description for the vCenter Server.
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 |
-EnableSecureMode
Indicates whether VMM communicates with VMware ESX hosts and Citrix XenServer hosts in secure mode. The default value is $True.
Parameter properties
Type: | Boolean |
Default value: | None |
Supports wildcards: | False |
DontShow: | False |
Aliases: | SecureMode |
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 that job progress is tracked and stored in the variable named by this parameter.
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 |
-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 |
-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 |
-TCPPort
Specifies a numeric value that represents a TCP port.
Parameter properties
Type: | UInt32 |
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 |
-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 |
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
VirtualizationManager
This cmdlet returns a VirtualizationManager object.