Binding/Unbinding an EIP
Function
This API is used to bind an EIP to a node of an instance or unbind an EIP from the node.
Constraints
- This API supports the following instances:
- GeminiDB Cassandra
- GeminiDB Mongo
- GeminiDB Influx
- GeminiDB Redis
- This API is not available to frozen or abnormal instances.
- Multiple EIPs cannot be bound to the same node.
- Unbinding an EIP from a node of a frozen instance is not supported.
- Unbinding an EIP from a node with no EIPs bound is not supported.
Authorization Information
Each account has permissions to call all APIs, but IAM users must have the required permissions specifically assigned.
- If you are using role/policy-based authorization, see the required permissions in Permissions and Supported Actions.
- If you are using identity policy-based authorization, the following identity policy-based permissions are required.
Action
Access Level
Resource Type (*: required)
Condition Key
Alias
Dependencies
gaussdbfornosql:instance:updateEIP
Write
instance *
- g:ResourceTag/<tag-key>
- g:EnterpriseProjectId
- gaussdbfornosql:AssociatePublicIp
- nosql:instance:bindPublicIp
- nosql:instance:unbindPublicIp
-
URI
POST /v3/{project_id}/instances/{instance_id}/nodes/{node_id}/public-ip
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| project_id | Yes | String | Definition Project ID of a tenant in a region. To obtain this value, see Obtaining a Project ID. Constraints N/A Range The value contains 32 characters. Only letters and digits are allowed. Default Value N/A |
| instance_id | Yes | String | Definition Instance ID. To obtain the value, call the API by following Querying Instances and Details. If you do not have an instance, call the API by following Creating an Instance. Constraints N/A Range N/A Default Value N/A |
| node_id | Yes | String | Definition Instance node ID. To obtain the value, call the Querying Instances and Details API. Constraints N/A Range N/A Default Value N/A |
Request Parameters
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| X-Auth-Token | Yes | String | Definition User token You can obtain the token by calling the IAM API by following Obtaining a User Token Through Password Authentication. Constraints N/A Range N/A Default Value N/A |
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| action | Yes | String | Definition Operation identifier. Constraints N/A Range
Default Value N/A |
| public_ip | No | String | Definition EIP. Constraints This parameter is mandatory when an EIP needs to be bound. Range N/A Default Value N/A |
| public_ip_id | No | String | Definition EIP ID. For details about how to obtain the EIP ID, see Querying EIP Details. Constraints This parameter is mandatory when an EIP needs to be bound. Range N/A Default Value N/A |
Response Parameters
Status code: 202
| Parameter | Type | Description |
|---|---|---|
| job_id | String | Definition Task ID. Range N/A |
Example Requests
- Binding an EIP
POST https://{Endpoint}/v3/619d3e78f61b4be68bc5aa0b59edcf7b/instances/61f554065802400c9c33f87e8114f081in10/nodes/1345bb07d1834f8fb0b4acbc26e989aano10/public-ip { "action" : "BIND", "public_ip" : "10.154.218.161", "public_ip_id" : "45da4782-e0c8-4aa4-a290-b8740014f710" } - Unbinding an EIP
POST https://{Endpoint}/v3/619d3e78f61b4be68bc5aa0b59edcf7b/instances/61f554065802400c9c33f87e8114f081in10/nodes/1345bb07d1834f8fb0b4acbc26e989aano10/public-ip { "action" : "UNBIND", "public_ip" : "10.154.218.161" }
Example Responses
Status code: 202
Accepted
{
"job_id" : "f85104b5-4a9c-4e0f-9505-fc5409d8f7ae"
} Status Codes
For details, see Status Codes.
Error Codes
For details, see Error Codes.
What is your overall rating for this page?
Thank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot