Menu
Elastic Load Balancing
API Reference (API Version 2012-06-01)

EnableAvailabilityZonesForLoadBalancer

Adds the specified Availability Zones to the set of Availability Zones for the specified load balancer.

The load balancer evenly distributes requests across all its registered Availability Zones that contain instances.

For more information, see Add or Remove Availability Zones in the Classic Load Balancer Guide.

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.

AvailabilityZones.member.N

The Availability Zones. These must be in the same region as the load balancer.

Type: Array of strings

Required: Yes

LoadBalancerName

The name of the load balancer.

Type: String

Required: Yes

Response Elements

The following element is returned by the service.

AvailabilityZones.member.N

The updated list of Availability Zones for the load balancer.

Type: Array of strings

Errors

For information about the errors that are common to all actions, see Common Errors.

LoadBalancerNotFound

The specified load balancer does not exist.

HTTP Status Code: 400

Example

Enable Availability Zones

This example enables the specified Availability Zone for the specified load balancer.

Sample Request

Copy
https://elasticloadbalancing.amazonaws.com/?Action=EnableAvailabilityZonesForLoadBalancer &LoadBalancerName=my-loadbalancer &AvailabilityZones.member.1=us-east-1c &Version=2012-06-01 &AUTHPARAMS

Sample Response

Copy
<EnableAvailabilityZonesForLoadBalancerResponse xmlns="http://elasticloadbalancing.amazonaws.com/doc/2012-06-01/"> <EnableAvailabilityZonesForLoadBalancerResult> <AvailabilityZones> <member>us-east-1a</member> <member>us-east-1c</member> </AvailabilityZones> </EnableAvailabilityZonesForLoadBalancerResult> <ResponseMetadata> <RequestId>83c88b9d-12b7-11e3-8b82-87b12EXAMPLE</RequestId> </ResponseMetadata> </EnableAvailabilityZonesForLoadBalancerResponse>

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: