Add-VMFibreChannelHba

Add-VMFibreChannelHba

Adds a virtual Fibre Channel host bus adapter to a virtual machine.

Syntax

Parameter Set: VMName and GenerateWwn
Add-VMFibreChannelHba [-VMName] <String> [-SanName] <String> [-ComputerName <String[]> ] [-GenerateWwn] [-Passthru] [-Confirm] [-WhatIf] [ <CommonParameters>]

Parameter Set: VM object and GenerateWwn
Add-VMFibreChannelHba [-VM] <VirtualMachine[]> [-SanName] <String> [-GenerateWwn] [-Passthru] [-Confirm] [-WhatIf] [ <CommonParameters>]

Parameter Set: VM Object and manual WWN
Add-VMFibreChannelHba [-VM] <VirtualMachine[]> [-SanName] <String> -WorldWideNodeNameSetA <String> -WorldWideNodeNameSetB <String> -WorldWidePortNameSetA <String> -WorldWidePortNameSetB <String> [-Passthru] [-Confirm] [-WhatIf] [ <CommonParameters>]

Parameter Set: VMName and manual WWN
Add-VMFibreChannelHba [-VMName] <String> [-SanName] <String> -WorldWideNodeNameSetA <String> -WorldWideNodeNameSetB <String> -WorldWidePortNameSetA <String> -WorldWidePortNameSetB <String> [-ComputerName <String[]> ] [-Passthru] [-Confirm] [-WhatIf] [ <CommonParameters>]

Detailed Description

The Add-VMFibreChannelHba cmdlet adds a virtual Fibre Channel host bus adapter to a virtual machine.

Parameters

-ComputerName<String[]>

Specifies one or more Hyper-V hosts on which a virtual Fibre Channel host bus adapter is to be added. NetBIOS names, IP addresses, and fully-qualified domain names are allowable. The default is the local computer — use “localhost” or a dot (“.”) to specify the local computer explicitly.

Aliases

none

Required?

false

Position?

named

Default Value

.

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Passthru

Specifies that an object representing the virtual machine to which the virtual Fibre Channel host bus adapter being added is to be passed through to the pipeline.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-SanName<String>

Specifies the virtual storage area network (SAN) name to associate with this virtual Fibre Channel host bus adapter. Use the Get-VMSan cmdlet to get a list of all virtual SANs on the host.

Aliases

none

Required?

true

Position?

2

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-VM<VirtualMachine[]>

Specifies the virtual machine to which the virtual Fibre Channel host bus adapter is to be added.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

True (ByValue)

Accept Wildcard Characters?

false

-VMName<String>

Specifies the name of the virtual machine to which the virtual Fibre Channel host bus adapter is to be added.

Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

True (ByValue)

Accept Wildcard Characters?

false

-WorldWideNodeNameSetA<String>

Specifies the world wide node name of address A associated with the Fibre Channel host bus adapter to be added.

Aliases

Wwnn1

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-WorldWideNodeNameSetB<String>

Specifies the world wide node name of address B associated with the Fibre Channel host bus adapter to be added.

Aliases

Wwnn2

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-WorldWidePortNameSetA<String>

Specifies the world wide port name of address A associated with the Fibre Channel host bus adapter to be added.

Aliases

Wwpn1

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-WorldWidePortNameSetB<String>

Specifies the world wide port name of address B associated with the Fibre Channel host bus adapter to be added.

Aliases

Wwpn2

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-GenerateWwn

Specifies that the world wide names for the Fibre Channel host bus adapter are to be generated automatically. When specified, the WorldWideNodeNameSetA, WorldWideNodeNameSetB, WorldWidePortNameSetA, and WorldWidePortNameSetB parameters cannot be used.

Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Confirm

Prompts you for confirmation before running the cmdlet.

Required?

false

Position?

named

Default Value

false

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-WhatIf

Shows what would happen if the cmdlet runs. The cmdlet is not run.

Required?

false

Position?

named

Default Value

false

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

<CommonParameters>

This cmdlet supports the common parameters: -Verbose, -Debug, -ErrorAction, -ErrorVariable, -OutBuffer, and -OutVariable. For more information, see    about_CommonParameters (https://go.microsoft.com/fwlink/p/?LinkID=113216).

Inputs

The input type is the type of the objects that you can pipe to the cmdlet.

  • None

Outputs

The output type is the type of the objects that the cmdlet emits.

  • None by default; Microsoft.Virtualization.Powershell.VirtualMachine if –PassThru is specified.

Examples

Example 1

This example adds the virtual Fibre Channel host bus adapter associated with virtual storage area network Production to a virtual machine named MyVM.

PS C:\> Add-VMFibreChannelHba –VMName MyVM –SanName Production