EN
此内容没有您的语言版本,但有英语版本。
1(共 1)对本文的评价是有帮助 - 评价此主题

Add-AzureEndpoint

[This topic is pre-release documentation and is subject to change in future releases. Blank topics are included as placeholders.]

Add-AzureEndpoint

Adds a new endpoint to a Windows Azure virtual machine.

 

Parameter Set: NoLB
Add-AzureEndpoint [-Name] <String> [-Protocol] <String> [-LocalPort] <Int32> -VM <IPersistentVM> [-PublicPort <Int32> ] [ <CommonParameters>]

Parameter Set: LoadBalanced
Add-AzureEndpoint [-Name] <String> [-Protocol] <String> [-LocalPort] <Int32> -LBSetName <String> -ProbePort <Int32> -ProbeProtocol <String> -VM <IPersistentVM> [-ProbePath <String> ] [-PublicPort <Int32> ] [ <CommonParameters>]




 

The Add-AzureEndpoint cmdlet adds a new input endpoint to a virtual machine. You can specify a new endpoint that is not load balanced, which will be used only by this virtual machine, or you can specify a load-balanced endpoint, which other virtual machines running in the same cloud service can share to load-balance traffic.

When adding a load-balanced endpoint, you can also specify parameters for an endpoint probe. The probe will be used to check the health of endpoints and endpoint resources, probing for response every 15 seconds, and taking a resource out of rotation if no response is received within 31 seconds.

 

-LBSetName<String>

Specifies the name of a load-balanced endpoint. Multiple virtual machines in the cloud service can use a load-balanced endpoint.


Aliases

LoadBalancedEndpointSetName

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-LocalPort<Int32>

Specifies the local (private) port that will be used for the endpoint. Applications within the virtual machine listen to this port to service input requests over the endpoint.


Aliases

none

Required?

true

Position?

3

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Name<String>

Specifies the name of the endpoint.


Aliases

none

Required?

true

Position?

1

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ProbePath<String>

Required if ProbeProtocol is set to "http". Omit otherwise. Specifies the URI whose health will be probed.


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ProbePort<Int32>

Required. Specifies the public port that the probe will use.


Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-ProbeProtocol<String>

Specifies the protocol of the endpoint to be probed. Acceptable values are "http" or "tcp". If "tcp" is specified, a received ACK is required for the probe to be successful. If "http" is specified, a 200 OK response from the ProbePath URI is required.


Aliases

none

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-Protocol<String>

Specifies the protocol of the endpoint. Acceptable values are "udp" or "tcp".


Aliases

none

Required?

true

Position?

2

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-PublicPort<Int32>

Specifies the public port that the endpoint will use.


Aliases

none

Required?

false

Position?

named

Default Value

none

Accept Pipeline Input?

false

Accept Wildcard Characters?

false

-VM<IPersistentVM>

Specifies the virtual machine object for which the endpoint will be created.


Aliases

InputObject

Required?

true

Position?

named

Default Value

none

Accept Pipeline Input?

True (ByValue)

Accept Wildcard Characters?

false

<CommonParameters>

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

Inputs

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

Outputs

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

 

-------------- Example 1 --------------

This command retrieves the configuration of a virtual machine and adds a new endpoint named "HttpIn" configured with public port 80 and local port 8080. The changed configuration is pipelined to Update-AzureVM to update the virtual machine.


C:\PS>Get-AzureVM -ServiceName "mySvc" -Name "MyVM1" | Add-AzureEndpoint -Name "HttpIn" -Protocol "tcp" -PublicPort 80 -LocalPort 8080 | Update-AzureVM

-------------- Example 2 --------------

This command retrieves the configuration of a virtual machine and adds a new endpoint named "HttpIn" configured with public port 80 and local port 8080. The endpoint belongs to the shared load balanced group named "WebFarm" and its availability is monitored by an HTTP probe on port 80, path '/'. The changed configuration is pipelined to Update-AzureVM to update the virtual machine.


C:\PS>Get-AzureVM -ServiceName "myLBSvc" -Name "MyVM2" | Add-AzureEndpoint -Name "HttpIn" -Protocol "http" -PublicPort 80 -LocalPort 8080 -LBSetName "WebFarm" -ProbePort 80 -ProbeProtocol "http" -ProbePath '/' | Update-AzureVM

Related topics

本文是否对您有所帮助?
(1500 个剩余字符)
© 2013 Microsoft. 版权所有。
facebook page visit twitter rss feed newsletter