doc-exports/docs/dds/api-ref/dds_api_0120.html
Ru, Li Yi a6e39ff5b3 DDS_API
Reviewed-by: Boka, Ladislav <ladislav.boka@t-systems.com>
Co-authored-by: Ru, Li Yi <liyiru7@huawei.com>
Co-committed-by: Ru, Li Yi <liyiru7@huawei.com>
2024-05-27 08:52:30 +00:00

110 lines
9.8 KiB
HTML

<a name="dds_api_0120"></a><a name="dds_api_0120"></a>
<h1 class="topictitle1">Enabling Shard or Config IP Addresses</h1>
<div id="body0000001072787211"><div class="section" id="dds_api_0120__section4850156117316"><h4 class="sectiontitle">Function</h4><p id="dds_api_0120__p3631239417316">This API is used to enable the IP addresses of shard or config nodes.</p>
</div>
<div class="section" id="dds_api_0120__section1239972118494"><h4 class="sectiontitle">Constraints</h4><ul id="dds_api_0120__ul1349153115110"><li id="dds_api_0120__li15447401739">Frozen instances do not support this operation.</li><li id="dds_api_0120__li13778164334514">DB instances associated with the IPv6 subnet do not support this operation.</li><li id="dds_api_0120__li171681511134">If the IP address is enabled, restart the nodes for the setting to take effect.</li><li id="dds_api_0120__li14453318174110">Cluster instances of Community Edition 3.4, 4.0, 4.2 and 4.4 are supported.</li><li id="dds_api_0120__li103765812554">This function cannot be disabled after being enabled.</li></ul>
</div>
<div class="section" id="dds_api_0120__section28961517113719"><h4 class="sectiontitle">URI</h4><ul id="dds_api_0120__ul3084351717316"><li id="dds_api_0120__li915620217316">URI format<p id="dds_api_0120__p912862005412"><a name="dds_api_0120__li915620217316"></a><a name="li915620217316"></a>POST https://{Endpoint}/v3/{project_id}/instances/{instance_id}/create-ip</p>
</li><li id="dds_api_0120__li15430535">Parameter description
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dds_api_0120__table4657088" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="dds_api_0120__row60083059"><th align="left" class="cellrowborder" valign="top" width="24%" id="mcps1.3.3.2.2.1.2.4.1.1"><p id="dds_api_0120__p34889605">Name</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="24.9%" id="mcps1.3.3.2.2.1.2.4.1.2"><p id="dds_api_0120__p7485743">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="51.1%" id="mcps1.3.3.2.2.1.2.4.1.3"><p id="dds_api_0120__p2775334615440">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="dds_api_0120__row57385070"><td class="cellrowborder" valign="top" width="24%" headers="mcps1.3.3.2.2.1.2.4.1.1 "><p id="dds_api_0120__p732920567115">project_id</p>
</td>
<td class="cellrowborder" valign="top" width="24.9%" headers="mcps1.3.3.2.2.1.2.4.1.2 "><p id="dds_api_0120__p532935613116">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="51.1%" headers="mcps1.3.3.2.2.1.2.4.1.3 "><p id="dds_api_0120__p4329756415">Specifies the project ID of a tenant in a region.</p>
</td>
</tr>
<tr id="dds_api_0120__row2864326155157"><td class="cellrowborder" valign="top" width="24%" headers="mcps1.3.3.2.2.1.2.4.1.1 "><p id="dds_api_0120__p963319528116">instance_id</p>
</td>
<td class="cellrowborder" valign="top" width="24.9%" headers="mcps1.3.3.2.2.1.2.4.1.2 "><p id="dds_api_0120__p1032910565114">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="51.1%" headers="mcps1.3.3.2.2.1.2.4.1.3 "><p id="dds_api_0120__p15330656516">Specifies the instance ID, which can be obtained by calling the API for querying instances. If you do not have an instance, you can call the API used for creating an instance.</p>
</td>
</tr>
</tbody>
</table>
</div>
</li></ul>
</div>
<div class="section" id="dds_api_0120__section3074340117316"><h4 class="sectiontitle">Requests</h4><ul id="dds_api_0120__ul5099287616954"><li id="dds_api_0120__li5628270116954">Parameter description
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="dds_api_0120__table3678226816954" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Parameter description</caption><thead align="left"><tr id="dds_api_0120__row1340482316954"><th align="left" class="cellrowborder" valign="top" width="17.169999999999998%" id="mcps1.3.4.2.1.1.2.5.1.1"><p id="dds_api_0120__p1204887716954">Name</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="17.75%" id="mcps1.3.4.2.1.1.2.5.1.2"><p id="dds_api_0120__p15184124818564">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="21.6%" id="mcps1.3.4.2.1.1.2.5.1.3"><p id="dds_api_0120__p3643495116954">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="43.480000000000004%" id="mcps1.3.4.2.1.1.2.5.1.4"><p id="dds_api_0120__p222501215320">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="dds_api_0120__row794180116954"><td class="cellrowborder" valign="top" width="17.169999999999998%" headers="mcps1.3.4.2.1.1.2.5.1.1 "><p id="dds_api_0120__p37323919416">type</p>
</td>
<td class="cellrowborder" valign="top" width="17.75%" headers="mcps1.3.4.2.1.1.2.5.1.2 "><p id="dds_api_0120__p107333911419">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="21.6%" headers="mcps1.3.4.2.1.1.2.5.1.3 "><p id="dds_api_0120__p18748396418">String</p>
</td>
<td class="cellrowborder" valign="top" width="43.480000000000004%" headers="mcps1.3.4.2.1.1.2.5.1.4 "><p id="dds_api_0120__p395118110297">Specifies the type of the object for which the IP address is to be enabled.</p>
<ul id="dds_api_0120__ul1749444819162"><li id="dds_api_0120__li194954486165">To enable IP addresses for shard nodes, set the value to <strong id="dds_api_0120__b106141522192816">shard</strong>.</li><li id="dds_api_0120__li12495154821611">To enable IP addresses for config nodes, set the value to <strong id="dds_api_0120__b16777125364620">config</strong>.</li></ul>
</td>
</tr>
<tr id="dds_api_0120__row375935052813"><td class="cellrowborder" valign="top" width="17.169999999999998%" headers="mcps1.3.4.2.1.1.2.5.1.1 "><p id="dds_api_0120__p276045013289">target_id</p>
</td>
<td class="cellrowborder" valign="top" width="17.75%" headers="mcps1.3.4.2.1.1.2.5.1.2 "><p id="dds_api_0120__p876005042813">No</p>
</td>
<td class="cellrowborder" valign="top" width="21.6%" headers="mcps1.3.4.2.1.1.2.5.1.3 "><p id="dds_api_0120__p157607501285">String</p>
</td>
<td class="cellrowborder" valign="top" width="43.480000000000004%" headers="mcps1.3.4.2.1.1.2.5.1.4 "><p id="dds_api_0120__p464310229295">Specifies the ID of the group whose IP addresses are to be enabled.</p>
<ul id="dds_api_0120__ul1331113227171"><li id="dds_api_0120__li1631152281720">For shard nodes, the value is the shard ID.</li><li id="dds_api_0120__li93111224174">For config nodes, the value is the config ID.</li><li id="dds_api_0120__li1731102231715">If this parameter is left blank, enable all IP addresses of the same node type in the instance.</li></ul>
<div class="caution" id="dds_api_0120__note8782147101710"><span class="cautiontitle"> CAUTION: </span><div class="cautionbody"><ul id="dds_api_0120__ul59769186189"><li id="dds_api_0120__li997651821820">If the IP address is enabled for the first time, leave this parameter empty.</li><li id="dds_api_0120__li119768188186">If the IP address is enabled, this parameter cannot be delivered repeatedly.</li></ul>
</div></div>
</td>
</tr>
<tr id="dds_api_0120__row8551715205814"><td class="cellrowborder" valign="top" width="17.169999999999998%" headers="mcps1.3.4.2.1.1.2.5.1.1 "><p id="dds_api_0120__p18744391445">password</p>
</td>
<td class="cellrowborder" valign="top" width="17.75%" headers="mcps1.3.4.2.1.1.2.5.1.2 "><p id="dds_api_0120__p18743391446">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="21.6%" headers="mcps1.3.4.2.1.1.2.5.1.3 "><p id="dds_api_0120__p374439545">String</p>
</td>
<td class="cellrowborder" valign="top" width="43.480000000000004%" headers="mcps1.3.4.2.1.1.2.5.1.4 "><p id="dds_api_0120__p17749394417">Specifies the password for enabling this function for a cluster.</p>
<ul id="dds_api_0120__ul51929218214"><li id="dds_api_0120__li1119282192113">The value must be 8 to 32 characters in length and contain uppercase letters (A to Z), lowercase letters (a to z), digits (0 to 9), and special characters, such as ~!@#%^*-_=+?</li><li id="dds_api_0120__li685612512115">Enter a strong password to improve security, preventing security risks such as brute force cracking.</li></ul>
<div class="caution" id="dds_api_0120__note442401812195"><span class="cautiontitle"> CAUTION: </span><div class="cautionbody"><p id="dds_api_0120__p11936627141911">This password cannot be changed. Exercise caution when performing this operation.</p>
</div></div>
</td>
</tr>
</tbody>
</table>
</div>
</li></ul>
<ul id="dds_api_0120__ul1041877316954"><li id="dds_api_0120__li2666010016954">Request example<div class="p" id="dds_api_0120__p16231155132115"><a name="dds_api_0120__li2666010016954"></a><a name="li2666010016954"></a>POST https://dds.eu-de.otc.t-systems.com/v3/0549b4a43100d4f32f51c01c2fe4acdb/instances/9136fd2a9fcd405ea4674276ce36dae8in02/create-ip<pre class="codeblock" id="dds_api_0120__codeblock10620175002112">{
"type": "shard",
"target_id": "91bac9f23ead42e19013333e05f44829gr02",
"password": "******"
}</pre>
</div>
</li></ul>
</div>
<div class="section" id="dds_api_0120__section28521534113742"><h4 class="sectiontitle">Responses</h4><ul id="dds_api_0120__ul16665627"><li id="dds_api_0120__li15772917">Response example<pre class="codeblock" id="dds_api_0120__codeblock660937479172">{}
</pre>
</li></ul>
</div>
<div class="section" id="dds_api_0120__section5382712154838"><h4 class="sectiontitle">Status Code</h4><p id="dds_api_0120__en-us_topic_0000001387505349_p16131712193312">Status Code:200.</p>
<p id="dds_api_0120__en-us_topic_0000001387505349_p480617135329">For more information, see <a href="dds_status_code.html">Status Code</a>.</p>
</div>
<div class="section" id="dds_api_0120__section6522193710339"><h4 class="sectiontitle">Error Code</h4><p id="dds_api_0120__dds_api_0018_p20466124120334">For more information, see <a href="dds_error_code.html">Error Code</a>.</p>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="dds_instance_mgmt.html">DB Instance Management</a></div>
</div>
</div>