Exporter (0) Imprimer
Développer tout
EN
Ce contenu n’est pas disponible dans votre langue. Voici la version anglaise.

Get-NlbClusterPortRule

Windows Server 2012 R2 and Windows 8.1

Updated: October 17, 2013

Applies To: Windows 8.1, Windows PowerShell 4.0, Windows Server 2012 R2

Get-NlbClusterPortRule

Retrieves the port rule objects that are queried by the caller.

Syntax

Parameter Set: NonPipeline
Get-NlbClusterPortRule [[-Port] <UInt32> ] [-HostName <String> ] [-InterfaceName <String> ] [-IP <IPAddress> ] [-NodeName <String> ] [ <CommonParameters>]

Parameter Set: Pipeline
Get-NlbClusterPortRule [[-Port] <UInt32> ] -InputObject <PSObject[]> [-IP <IPAddress> ] [ <CommonParameters>]




Detailed Description

The Get-NlbClusterPortRule cmdlet retrieves the port rules in the Network Load Balancing (NLB) cluster. If a port number is not specified, all port rules configured for the cluster are listed.

Parameters

-HostName<String>

Specifies the name of the cluster host against which this cmdlet is run. If this parameter is omitted or a value of . is entered, then the local cluster is assumed.


Aliases

Host,HN,H

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-IP<IPAddress>

Specifies the IP address for the cluster port rule that will be retrieved.


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-InputObject<PSObject[]>

Specifies the cluster or cluster node for which port rules are enumerated.


Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByValue, ByPropertyName)

Accept Wildcard Characters?

false

-InterfaceName<String>

Specifies the interface to which NLB is bound. This is the interface of the cluster against which this cmdlet is run.


Aliases

Interface,IN,I

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-NodeName<String>

Specifies the name of the cluster node for which port rules are enumerated.


Aliases

NN

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Port<UInt32>

Specifies a port number within the port rule to retrieve. The acceptable values for this parameter are: 0 through 65535.


Aliases

none

Required?

false

Position?

1

Default Value

none

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.

Inputs

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

  • Microsoft.NetworkLoadBalancingClusters.PowerShell.Cluster

Outputs

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

  • Microsoft.NetworkLoadBalancingClusters.PowerShell.PortRule

Examples

EXAMPLE 1

This example lists all the port rules on the local cluster.


PS C:\> Get-NlbClusterPortRule
IPAddress State     Start     End       Protocol  Mode      Affinity  Timeout 
--------- -----     -----     ---       --------  ----      --------  ------- 
All       Enabled   0         65535     Both      Multiple  Single    0 

EXAMPLE 2

This example gets the port rule that includes port 80.


PS C:\> Get-NlbClusterPortRule -Port 80
IPAddress State     Start     End       Protocol  Mode      Affinity  Timeout 
--------- -----     -----     ---       --------  ----      --------  ------- 
All       Enabled   0         65535     Both      Multiple  Single    0 

EXAMPLE 3

This example gets the port rule from all cluster nodes. This is especially useful if there are port rules that have Single mode.


PS C:\> Get-NlbClusterNode | Get-NlbClusterPortRule | Format-List –Property *
Cluster          : mycluster 
NodeName         : node1 
VirtualIPAddress : 255.255.255.255 
StartPort        : 0 
EndPort          : 65535 
Affinity         : 
FilteringMode    : Single 
Protocol         : Both 
EqualLoad        : False 
LoadWeight       : 
PortState        : Enabled 
Priority         : 1 
Timeout          : 
 
Cluster          : mycluster 
NodeName         : node2 
VirtualIPAddress : 255.255.255.255 
StartPort        : 0 
EndPort          : 65535 
Affinity         : 
FilteringMode    : Single 
Protocol         : Both 
EqualLoad        : False 
LoadWeight       : 
PortState        : Enabled 
Priority         : 2 
Timeout          : 

Related topics

Cela vous a-t-il été utile ?
(1500 caractères restants)
Merci pour vos suggestions.
Afficher:
© 2014 Microsoft