Add-SCNetworkService
Adds a network service to VMM.
Syntax
Add-SCNetworkService
[-ProvisionSelfSignedCertificatesForNetworkService <Boolean>]
[-VMMServer <ServerConnection>]
[-ConnectionString] <String>
-Manufacturer <String>
-Model <String>
[-Version <String>]
-RunAsAccount <RunAsAccount>
-VMHostGroup <HostGroup[]>
-Name <String>
[-Description <String>]
[-BandwidthCapacityKBps <UInt64>]
[-Certificate <ClientCertificate[]>]
[-LogicalNetworkVIP <LogicalNetwork[]>]
[-LogicalNetworkDedicatedIP <LogicalNetwork[]>]
[-RunAsynchronously]
[-PROTipID <Guid>]
[-JobVariable <String>]
[<CommonParameters>]
Add-SCNetworkService
[-ProvisionSelfSignedCertificatesForNetworkService <Boolean>]
[-VMMServer <ServerConnection>]
[-ConnectionString] <String>
[-Version <String>]
-RunAsAccount <RunAsAccount>
-VMHostGroup <HostGroup[]>
-Name <String>
[-Description <String>]
-ConfigurationProvider <ConfigurationProvider>
[-BandwidthCapacityKBps <UInt64>]
[-Certificate <ClientCertificate[]>]
[-LogicalNetworkVIP <LogicalNetwork[]>]
[-LogicalNetworkDedicatedIP <LogicalNetwork[]>]
[-RunAsynchronously]
[-PROTipID <Guid>]
[-JobVariable <String>]
[<CommonParameters>]
Description
The Add-SCNetworkService cmdlet adds a network service to Virtual Machine Manager (VMM).
Examples
Example 1: Add a network service for a network controller to VMM
PS C:\> $RunAsAccount = Get-SCRunAsAccount -ID "dc90a558-c402-4a70-9f6b-e50bc2fad540"
PS C:\> $ConfigurationProvider = Get-SCConfigurationProvider -Name "Microsoft Network Controller"
PS C:\> $VmHostGroup = @()
PS C:\> $VmHostGroup += Get-SCVMHostGroup -Name "All Hosts"
PS C:\> $Certificates = @()
PS C:\> $Certificates += Get-SCCertificate -ComputerName "networkcontroller.contoso.com" -TCPPort 443
PS C:\> Add-SCNetworkService -Name "NetworkController" -RunAsAccount $runAsAccount -ConfigurationProvider $ConfigurationProvider -VMHostGroup $vmHostGroup -ConnectionString "serverUrl=https://networkcontroller.contoso.com;serviceName=NC_Service" -Certificate $Certificates -ProvisionSelfSignedCertificatesForNetworkService $True
The first command gets the run as account that is used by VMM to communicate with network service. The command stores it in the $RunAsAccount variable.
The second command gets the configuration provider for network controller.
The third command creates an array variable named $VmHostGroup. The fourth command adds a host group to which the network service is accessible to $VmHostGroup.
The fifth command creates an array variable named $Certificates. The sixth command adds the certificated available for the network controller to $Certificates.
The final command adds network service for a network controller to VMM. The command specifies the values created in previous commands. Because this example uses self-signed certificates for the network controller, the ProvisionSelfSignedCertificatesForNetworkService has a value of $True.
Parameters
-BandwidthCapacityKBps
Specifies the bandwidth capacity, in kilobytes per second (KBps), of a network service.
Type: | UInt64 |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Certificate
Specifies an array of security certificate objects.
Type: | ClientCertificate[] |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ConfigurationProvider
Specifies a configuration provider object.
A configuration provider is a plug-in to VMM that translates VMM PowerShell commands to API calls that are specific to a type of load balancer. If no configuration provider is specified, VMM uses the Manufacturer and Model information to choose an available configuration provider. If no configuration provider is found, the load balancer is not added.
Type: | ConfigurationProvider |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ConnectionString
Specifies the information required to connect to the virtual switch extension manager.
Type: | String |
Position: | 0 |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Description
Specifies a description for the network service.
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
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 |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-LogicalNetworkDedicatedIP
Specifies an array of logical network objects.
Type: | LogicalNetwork[] |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-LogicalNetworkVIP
Specifies an array of logical network objects.
Type: | LogicalNetwork[] |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Manufacturer
Specifies the name of the company that manufactured a physical device. The acceptable values for this parameter are:
- Letters (a-z)
- Numbers (0-9)
- Underscore (_)
- Hyphen (-)
- Dot (.)
- Single quote (')
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Model
Specifies the model of a physical device.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Name
Specifies the name of a network object.
Type: | String |
Position: | Named |
Default value: | None |
Required: | True |
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 |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-ProvisionSelfSignedCertificatesForNetworkService
Type: | Boolean |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-RunAsAccount
Specifies a Run As account that contains credentials with permission to perform this action.
Type: | RunAsAccount |
Position: | Named |
Default value: | None |
Required: | True |
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 |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-Version
Specifies a version.
Type: | String |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-VMHostGroup
Specifies a virtual machine host group object or an array of host group objects.
Type: | HostGroup[] |
Position: | Named |
Default value: | None |
Required: | True |
Accept pipeline input: | False |
Accept wildcard characters: | False |
-VMMServer
Specifies a VMM server object.
Type: | ServerConnection |
Position: | Named |
Default value: | None |
Required: | False |
Accept pipeline input: | True |
Accept wildcard characters: | False |