forked from docs/doc-exports
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>
139 lines
16 KiB
HTML
139 lines
16 KiB
HTML
<a name="rds_19_0005"></a><a name="rds_19_0005"></a>
|
|
|
|
<h1 class="topictitle1">Upgrading a Major Version of a DB Instance (RDS for PostgreSQL)</h1>
|
|
<div id="body0000001990113109"><div class="section" id="rds_19_0005__en-us_topic_0000001718281414_section38100002311"><h4 class="sectiontitle">Function</h4><p id="rds_19_0005__en-us_topic_0000001718281414_p129381803237">This API is used to upgrade a major version.</p>
|
|
<ul id="rds_19_0005__ul16405173211918"><li id="rds_19_0005__en-us_topic_0240111818_li836513175363">Before calling an API, you need to understand the API in <a href="rds_03_0001.html">Authentication</a>.</li><li id="rds_19_0005__en-us_topic_0240111818_li1991981933613">Before calling this API, obtain the required <a href="https://docs.otc.t-systems.com/en-us/endpoint/index.html" target="_blank" rel="noopener noreferrer">region and endpoint</a>.</li></ul>
|
|
</div>
|
|
<div class="section" id="rds_19_0005__en-us_topic_0000001718281414_section13811160182315"><h4 class="sectiontitle">Constraints</h4><ul id="rds_19_0005__en-us_topic_0000001718281414_ul159389082312"><li id="rds_19_0005__en-us_topic_0000001718281414_li493816018235">This API is available to RDS for PostgreSQL only.</li><li id="rds_19_0005__en-us_topic_0000001718281414_li89380016233">This operation cannot be performed when the DB instance is in any of the following statuses: creating, changing instance specifications, changing port, frozen, or abnormal.</li><li id="rds_19_0005__en-us_topic_0000001718281414_li7938190172317">Before an upgrade, ensure that a valid upgrade check report is available. In the check report, the source version is the current instance version, the target version is the one contained in the request body, the check is performed within seven days, and the check result is successful.</li><li id="rds_19_0005__li1347961715304">Major version upgrades are available to the following versions:<ul id="rds_19_0005__ul14404121863013"><li id="rds_19_0005__li14269152120307">RDS for PostgreSQL 12: 12.7 or later</li><li id="rds_19_0005__li07831119142918">RDS for PostgreSQL 13: 13.3 or later</li><li id="rds_19_0005__li121051520124511">RDS for PostgreSQL 14: 14.4 or later</li><li id="rds_19_0005__li733653516126">Major version upgrades are unavailable to RDS for PostgreSQL 11.</li></ul>
|
|
</li><li id="rds_19_0005__li11311326143212">Due to OS restrictions, some instances do not support major version upgrades. To learn which versions your instance can be upgraded to, see the list of available versions on the <a href="rds_19_0001.html">Querying the Target Version to Which a DB Instance Can Be Upgraded (RDS for PostgreSQL)</a>.</li><li id="rds_19_0005__en-us_topic_0000001551538538_li778431917297">Before a major version upgrade, perform an upgrade check. If there is no successful upgrade check in the validity period, a major version upgrade is not allowed.</li></ul>
|
|
</div>
|
|
<div class="section" id="rds_19_0005__en-us_topic_0000001718281414_section1281312013237"><h4 class="sectiontitle">URI</h4><ul id="rds_19_0005__en-us_topic_0000001718281414_ul119384018234"><li id="rds_19_0005__en-us_topic_0000001718281414_li10938160202315">URI format<p id="rds_19_0005__en-us_topic_0000001718281414_p1493820142317"><a name="rds_19_0005__en-us_topic_0000001718281414_li10938160202315"></a><a name="en-us_topic_0000001718281414_li10938160202315"></a>POST /v3/{project_id}/instances/{instance_id}/major-version/upgrade</p>
|
|
</li><li id="rds_19_0005__en-us_topic_0000001718281414_li179399012316">Parameter description
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="rds_19_0005__en-us_topic_0000001718281414_table148151103238" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="rds_19_0005__en-us_topic_0000001718281414_row14939505237"><th align="left" class="cellrowborder" valign="top" width="21.48%" id="mcps1.3.3.2.2.1.2.5.1.1"><p id="rds_19_0005__en-us_topic_0000001718281414_p19391709237"><strong id="rds_19_0005__b842352706102328_3">Name</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="13.41%" id="mcps1.3.3.2.2.1.2.5.1.2"><p id="rds_19_0005__en-us_topic_0000001718281414_p19196593203"><strong id="rds_19_0005__b842352706164541_1">Type</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="18.4%" id="mcps1.3.3.2.2.1.2.5.1.3"><p id="rds_19_0005__en-us_topic_0000001718281414_p493950112318"><strong id="rds_19_0005__b19977305176">Mandatory</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="46.71%" id="mcps1.3.3.2.2.1.2.5.1.4"><p id="rds_19_0005__en-us_topic_0000001718281414_p59391503233"><strong id="rds_19_0005__b842352706163417_3">Description</strong></p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="rds_19_0005__en-us_topic_0000001718281414_row49390052311"><td class="cellrowborder" valign="top" width="21.48%" headers="mcps1.3.3.2.2.1.2.5.1.1 "><p id="rds_19_0005__en-us_topic_0000001718281414_p1493917010238">project_id</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="13.41%" headers="mcps1.3.3.2.2.1.2.5.1.2 "><p id="rds_19_0005__en-us_topic_0000001718281414_p619459102017">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="18.4%" headers="mcps1.3.3.2.2.1.2.5.1.3 "><p id="rds_19_0005__en-us_topic_0000001718281414_p119391105237">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="46.71%" headers="mcps1.3.3.2.2.1.2.5.1.4 "><p id="rds_19_0005__p1434580163733">Project ID of a tenant in a region.</p>
|
|
<p id="rds_19_0005__en-us_topic_0000001718281414_p9939160102319">To obtain it, refer to <a href="rds_03_0002.html">Obtaining a Project ID</a>.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="rds_19_0005__en-us_topic_0000001718281414_row1993970192315"><td class="cellrowborder" valign="top" width="21.48%" headers="mcps1.3.3.2.2.1.2.5.1.1 "><p id="rds_19_0005__en-us_topic_0000001718281414_p16939140192311">instance_id</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="13.41%" headers="mcps1.3.3.2.2.1.2.5.1.2 "><p id="rds_19_0005__en-us_topic_0000001718281414_p191920593201">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="18.4%" headers="mcps1.3.3.2.2.1.2.5.1.3 "><p id="rds_19_0005__en-us_topic_0000001718281414_p1193950192316">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="46.71%" headers="mcps1.3.3.2.2.1.2.5.1.4 "><p id="rds_19_0005__en-us_topic_0000001718281414_p149391107232">Instance ID.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="rds_19_0005__en-us_topic_0000001718281414_section98239012235"><h4 class="sectiontitle">Request</h4><ul id="rds_19_0005__en-us_topic_0000001718281414_ul294013014238"><li id="rds_19_0005__en-us_topic_0000001718281414_li09401107233">Request parameters
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="rds_19_0005__en-us_topic_0000001718281414_table118262072319" frame="border" border="1" rules="all"><thead align="left"><tr id="rds_19_0005__en-us_topic_0000001718281414_row1494019062316"><th align="left" class="cellrowborder" valign="top" width="28.57%" id="mcps1.3.4.2.1.1.1.5.1.1"><p id="rds_19_0005__en-us_topic_0000001718281414_p1894010192311"><strong id="rds_19_0005__b1870035177">Name</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="14.29%" id="mcps1.3.4.2.1.1.1.5.1.2"><p id="rds_19_0005__en-us_topic_0000001718281414_p49409020239"><strong id="rds_19_0005__b1871891960">Type</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="12.24%" id="mcps1.3.4.2.1.1.1.5.1.3"><p id="rds_19_0005__en-us_topic_0000001718281414_p79404042316"><strong id="rds_19_0005__b2781840121717">Mandatory</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="44.9%" id="mcps1.3.4.2.1.1.1.5.1.4"><p id="rds_19_0005__en-us_topic_0000001718281414_p1694012032318"><strong id="rds_19_0005__b439995096">Description</strong></p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="rds_19_0005__en-us_topic_0000001718281414_row1894014011238"><td class="cellrowborder" valign="top" width="28.57%" headers="mcps1.3.4.2.1.1.1.5.1.1 "><p id="rds_19_0005__en-us_topic_0000001718281414_p494010019239">target_version</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="14.29%" headers="mcps1.3.4.2.1.1.1.5.1.2 "><p id="rds_19_0005__en-us_topic_0000001718281414_p1594013022317">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="12.24%" headers="mcps1.3.4.2.1.1.1.5.1.3 "><p id="rds_19_0005__en-us_topic_0000001718281414_p79401409235">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="44.9%" headers="mcps1.3.4.2.1.1.1.5.1.4 "><p id="rds_19_0005__en-us_topic_0000001718281414_p10940160152314">Target version.</p>
|
|
<p id="rds_19_0005__en-us_topic_0000001718281414_p1894011017233">It must be later than the current major version of the instance. For example, if the current major version is 12, the target version must be 13 or 14.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="rds_19_0005__en-us_topic_0000001718281414_row209406015233"><td class="cellrowborder" valign="top" width="28.57%" headers="mcps1.3.4.2.1.1.1.5.1.1 "><p id="rds_19_0005__en-us_topic_0000001718281414_p3940206236">is_change_private_ip</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="14.29%" headers="mcps1.3.4.2.1.1.1.5.1.2 "><p id="rds_19_0005__p15391341615">Boolean</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="12.24%" headers="mcps1.3.4.2.1.1.1.5.1.3 "><p id="rds_19_0005__en-us_topic_0000001718281414_p7940140112312">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="44.9%" headers="mcps1.3.4.2.1.1.1.5.1.4 "><p id="rds_19_0005__en-us_topic_0000001718281414_p59407042310">Whether to switch the floating IP address of the source instance to the target instance.</p>
|
|
<ul id="rds_19_0005__en-us_topic_0000001718281414_ul179402016235"><li id="rds_19_0005__en-us_topic_0000001718281414_li79403012235"><strong id="rds_19_0005__b166918146211">true</strong>: After the upgrade, the floating IP address is switched to the target instance.</li><li id="rds_19_0005__en-us_topic_0000001718281414_li199411607236"><strong id="rds_19_0005__b14266115482515">false</strong>: After the upgrade, the floating IP address of the source instance remains unchanged, and the target instance uses a new floating IP address.</li></ul>
|
|
</td>
|
|
</tr>
|
|
<tr id="rds_19_0005__en-us_topic_0000001718281414_row5941701235"><td class="cellrowborder" valign="top" width="28.57%" headers="mcps1.3.4.2.1.1.1.5.1.1 "><p id="rds_19_0005__en-us_topic_0000001718281414_p8941110122310">statistics_collection_mode</p>
|
|
<p id="rds_19_0005__en-us_topic_0000001718281414_p494119015232"></p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="14.29%" headers="mcps1.3.4.2.1.1.1.5.1.2 "><p id="rds_19_0005__en-us_topic_0000001718281414_p69411002236">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="12.24%" headers="mcps1.3.4.2.1.1.1.5.1.3 "><p id="rds_19_0005__en-us_topic_0000001718281414_p794113032316">No</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="44.9%" headers="mcps1.3.4.2.1.1.1.5.1.4 "><p id="rds_19_0005__en-us_topic_0000001718281414_p1394116042313">Mode of collecting statistics. It is mandatory if <strong id="rds_19_0005__b1955455642617">is_change_private_ip</strong> is set to <strong id="rds_19_0005__b855420562266">true</strong>.</p>
|
|
<ul id="rds_19_0005__en-us_topic_0000001718281414_ul129411607231"><li id="rds_19_0005__en-us_topic_0000001718281414_li1794113052319"><strong id="rds_19_0005__b1756112632715">before_change_private_ip</strong>: Statistics are collected before the floating IP address of the source instance is switched to the target instance.</li><li id="rds_19_0005__en-us_topic_0000001718281414_li594180112314"><strong id="rds_19_0005__b6842125314270">after_change_private_ip</strong>: Statistics are collected after the floating IP address of the source instance is switched to the target instance.</li></ul>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</li><li id="rds_19_0005__en-us_topic_0000001718281414_li194113052310">Example request<pre class="screen" id="rds_19_0005__en-us_topic_0000001718281414_screen29281930173219">https://<em id="rds_19_0005__en-us_topic_0000001718281414_i19387715163316">{Endpoint}</em>/v3/0483b6b16e954cb88930a360d2c4e663/instances/3aa441c4c98a4b36b100a7e3e87d17cein03/major-version/upgrade
|
|
{
|
|
"target_version": "14.6.1",
|
|
"is_change_private_ip": true,
|
|
"statistics_collection_mode": "before_change_private_ip"
|
|
}</pre>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="rds_19_0005__en-us_topic_0000001718281414_section20849202236"><h4 class="sectiontitle">Response</h4><ul id="rds_19_0005__en-us_topic_0000001718281414_ul1894280192311"><li id="rds_19_0005__en-us_topic_0000001718281414_li89428017232">Normal response
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="rds_19_0005__en-us_topic_0000001718281414_table685213062320" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Parameter description</caption><thead align="left"><tr id="rds_19_0005__en-us_topic_0000001718281414_row494230192310"><th align="left" class="cellrowborder" valign="top" width="33.33333333333333%" id="mcps1.3.5.2.1.1.2.4.1.1"><p id="rds_19_0005__en-us_topic_0000001718281414_p894211019239"><strong id="rds_19_0005__b204761372">Name</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="27.27272727272727%" id="mcps1.3.5.2.1.1.2.4.1.2"><p id="rds_19_0005__en-us_topic_0000001718281414_p494210062313"><strong id="rds_19_0005__b1356460421">Type</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="39.39393939393939%" id="mcps1.3.5.2.1.1.2.4.1.3"><p id="rds_19_0005__en-us_topic_0000001718281414_p09421014235"><strong id="rds_19_0005__b2003011714">Description</strong></p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="rds_19_0005__en-us_topic_0000001718281414_row494290122312"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.5.2.1.1.2.4.1.1 "><p id="rds_19_0005__en-us_topic_0000001718281414_p3942200231">job_id</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="27.27272727272727%" headers="mcps1.3.5.2.1.1.2.4.1.2 "><p id="rds_19_0005__en-us_topic_0000001718281414_p19421006233">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="39.39393939393939%" headers="mcps1.3.5.2.1.1.2.4.1.3 "><p id="rds_19_0005__en-us_topic_0000001718281414_p1994214015232">Task ID.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</li></ul>
|
|
<ul id="rds_19_0005__en-us_topic_0000001718281414_ul2942190132317"><li id="rds_19_0005__en-us_topic_0000001718281414_li89424022312">Example normal response<pre class="screen" id="rds_19_0005__en-us_topic_0000001718281414_screen39381046173314">{
|
|
"job_id": "3afe25b7-4523-4d3b-8236-7121be922691"
|
|
}</pre>
|
|
</li></ul>
|
|
<ul id="rds_19_0005__en-us_topic_0000001718281414_ul1094270152310"><li id="rds_19_0005__en-us_topic_0000001718281414_li13942190132317">Abnormal response<p id="rds_19_0005__en-us_topic_0000001718281414_p1994217010231"><a name="rds_19_0005__en-us_topic_0000001718281414_li13942190132317"></a><a name="en-us_topic_0000001718281414_li13942190132317"></a>For details, see <a href="en-us_topic_0032488197.html">Abnormal Request Results</a>.</p>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="rds_19_0005__section4778540915440"><h4 class="sectiontitle">Status Code</h4><ul id="rds_19_0005__en-us_topic_0032347778_ul7858132212142"><li id="rds_19_0005__en-us_topic_0032347778_li58581622171411">Normal<p id="rds_19_0005__en-us_topic_0032347778_p1040982941020"><a name="rds_19_0005__en-us_topic_0032347778_li58581622171411"></a><a name="en-us_topic_0032347778_li58581622171411"></a>200</p>
|
|
</li><li id="rds_19_0005__en-us_topic_0032347778_li11583183218149">Abnormal<p id="rds_19_0005__en-us_topic_0032347778_p0723374409"><a name="rds_19_0005__en-us_topic_0032347778_li11583183218149"></a><a name="en-us_topic_0032347778_li11583183218149"></a>For details, see <a href="en-us_topic_0032488240.html">Status Codes</a>.</p>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="rds_19_0005__section1183074220016"><h4 class="sectiontitle">Error Code</h4><p id="rds_19_0005__en-us_topic_0032347778_p19357163913406">For details, see <a href="en-us_topic_0032488241.html">Error Codes</a>.</p>
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<div class="familylinks">
|
|
<div class="parentlink"><strong>Parent topic:</strong> <a href="rds_19_0000.html">Upgrading a Major Version</a></div>
|
|
</div>
|
|
</div>
|
|
|