forked from docs/doc-exports
Reviewed-by: Hasko, Vladimir <vladimir.hasko@t-systems.com> Co-authored-by: Zaoxu, Li <lizaoxu@huawei.com> Co-committed-by: Zaoxu, Li <lizaoxu@huawei.com>
98 lines
7.4 KiB
HTML
98 lines
7.4 KiB
HTML
<a name="evs_03_0004"></a><a name="evs_03_0004"></a>
|
|
|
|
<h1 class="topictitle1">Expanding the Capacity of an EVS Disk</h1>
|
|
<div id="body1540266269122"><div class="section" id="evs_03_0004__section1063418559011"><h4 class="sectiontitle">Scenarios</h4><p id="evs_03_0004__p138433244712">For an EVS disk that has been created, you can call this API to expand the disk capacity if the disk space is insufficient.</p>
|
|
</div>
|
|
<div class="section" id="evs_03_0004__section28146133118"><h4 class="sectiontitle">Constraints</h4><ul id="evs_03_0004__ul18925162319491"><li id="evs_03_0004__en-us_topic_0058626625_li31392702164213">If the status of the to-be-expanded disk is <strong id="evs_03_0004__en-us_topic_0058626625_b1612977365174554">available</strong>, there are no restrictions.</li><li id="evs_03_0004__en-us_topic_0058626625_li60094846164251">If the status of the to-be-expanded disk is <strong id="evs_03_0004__en-us_topic_0058626625_b355915787">in-use</strong>, the restrictions are as follows:<ul id="evs_03_0004__en-us_topic_0058626625_ul580664716433"><li id="evs_03_0004__en-us_topic_0058626625_li2791020816439">A shared disk cannot be expanded, that is, the value of parameter <strong id="evs_03_0004__en-us_topic_0058626625_b842352706174734">multiattach</strong> must be <strong id="evs_03_0004__en-us_topic_0058626625_b842352706174753">false</strong>.</li><li id="evs_03_0004__en-us_topic_0058626625_li24297666164211">The status of the server to which the disk attached must be <strong id="evs_03_0004__en-us_topic_0058626625_b9663175212282">ACTIVE</strong>, <strong id="evs_03_0004__en-us_topic_0058626625_b1066318520283">PAUSED</strong>, <strong id="evs_03_0004__en-us_topic_0058626625_b56641752192815">SUSPENDED</strong>, or <strong id="evs_03_0004__en-us_topic_0058626625_b1066418527281">SHUTOFF</strong>.</li></ul>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="evs_03_0004__section1531361811311"><h4 class="sectiontitle">Involved APIs</h4><p id="evs_03_0004__p33281854345">Query the disk list, obtain the ID of the target disk, and then expand the disk capacity.</p>
|
|
<p id="evs_03_0004__p73251180314">To meet the preceding requirements, call the following APIs:</p>
|
|
</div>
|
|
<ul id="evs_03_0004__ul1325151816318"><li id="evs_03_0004__li1259991315119">Query EVS disks.</li><li id="evs_03_0004__li1959910131510">Expand the capacity of a disk.</li></ul>
|
|
<div class="section" id="evs_03_0004__section16886203916519"><h4 class="sectiontitle">Procedure</h4><ol id="evs_03_0004__ol081544055118"><li id="evs_03_0004__li581684015116">Query EVS disks.<ul id="evs_03_0004__ul118162040125112"><li id="evs_03_0004__li158161740155110">API information<p id="evs_03_0004__p670222213411"><a name="evs_03_0004__li158161740155110"></a><a name="li158161740155110"></a>URI format: GET /v3/{project_id}/volumes</p>
|
|
<p id="evs_03_0004__p116419475511">For details, see <strong id="evs_03_0004__b842352706154153">OpenStack Cinder API v3</strong> > <strong id="evs_03_0004__b84235270615422">EVS Disk</strong> > <strong id="evs_03_0004__b842352706154211">Querying EVS Disks</strong> in the <em id="evs_03_0004__i886446318154217">Elastic Volume Service API Reference</em>.</p>
|
|
</li><li id="evs_03_0004__li17816340125118">Example request<p id="evs_03_0004__p31824912620"><a name="evs_03_0004__li17816340125118"></a><a name="li17816340125118"></a>GET /v3/000efdc5f9064584b718b181df137bd7/volumes</p>
|
|
</li><li id="evs_03_0004__li4816124025117">Example response<pre class="screen" id="evs_03_0004__screen1656613210549">{
|
|
"volumes": [
|
|
{
|
|
"id": "6b604cef-9bd8-4f5a-ae56-45839e6e1f0a",
|
|
"links": [
|
|
{
|
|
"href": "https://volume.localdomain.com:8776/v2/dd14c6ac581f40059e27f5320b60bf2f/volumes/6b604cef-9bd8-4f5a-ae56-45839e6e1f0a",
|
|
"rel": "self"
|
|
},
|
|
{
|
|
"href": "https://volume.localdomain.com:8776/dd14c6ac581f40059e27f5320b60bf2f/volumes/6b604cef-9bd8-4f5a-ae56-45839e6e1f0a",
|
|
"rel": "bookmark"
|
|
}
|
|
],
|
|
"name": "zjb_u25_test"
|
|
},
|
|
{
|
|
"id": "2bce4552-9a7d-48fa-8484-abbbf64b206e",
|
|
"links": [
|
|
{
|
|
"href": "https://volume.localdomain.com:8776/v2/dd14c6ac581f40059e27f5320b60bf2f/volumes/2bce4552-9a7d-48fa-8484-abbbf64b206e",
|
|
"rel": "self"
|
|
},
|
|
{
|
|
"href": "https://volume.localdomain.com:8776/dd14c6ac581f40059e27f5320b60bf2f/volumes/2bce4552-9a7d-48fa-8484-abbbf64b206e",
|
|
"rel": "bookmark"
|
|
}
|
|
],
|
|
"name": "zjb_u25_test"
|
|
},
|
|
{
|
|
"id": "3f1b98ec-a8b5-4e92-a727-88def62d5ad3",
|
|
"links": [
|
|
{
|
|
"href": "https://volume.localdomain.com:8776/v2/dd14c6ac581f40059e27f5320b60bf2f/volumes/3f1b98ec-a8b5-4e92-a727-88def62d5ad3",
|
|
"rel": "self"
|
|
},
|
|
{
|
|
"href": "https://volume.localdomain.com:8776/dd14c6ac581f40059e27f5320b60bf2f/volumes/3f1b98ec-a8b5-4e92-a727-88def62d5ad3",
|
|
"rel": "bookmark"
|
|
}
|
|
],
|
|
"name": "zjb_u25_test"
|
|
}
|
|
],
|
|
"volumes_links": [
|
|
{
|
|
"href": "https://volume.localdomain.com:8776/v2/dd14c6ac581f40059e27f5320b60bf2f/volumes?limit=3&marker=3f1b98ec-a8b5-4e92-a727-88def62d5ad3",
|
|
"rel": "next"
|
|
}
|
|
]
|
|
}</pre>
|
|
</li></ul>
|
|
</li><li id="evs_03_0004__li17817114010516">Expand the capacity of an EVS disk.<ul id="evs_03_0004__ul481784055111"><li id="evs_03_0004__li5817940105111">API information<p id="evs_03_0004__p75101049862"><a name="evs_03_0004__li5817940105111"></a><a name="li5817940105111"></a>URI format: POST /v3/{project_id}/volumes/{volume_id}/action</p>
|
|
<p id="evs_03_0004__p19381155416718">For details, see <strong id="evs_03_0004__b842352706154740">OpenStack Cinder API v3</strong> > <strong id="evs_03_0004__b842352706154751">EVS Disk Actions</strong> > <strong id="evs_03_0004__b842352706154758">Expanding the Capacity of an EVS Disk</strong> in the <em>Elastic Volume Service API Reference</em>.</p>
|
|
</li><li id="evs_03_0004__li18176402515">Example request<p id="evs_03_0004__p08548399814"><a name="evs_03_0004__li18176402515"></a><a name="li18176402515"></a>POST /v3/000efdc5f9064584b718b181df137bd7/ volumes/9ab74d89-61e7-4259-8546-465fdebe4944/ action</p>
|
|
<pre class="screen" id="evs_03_0004__screen1696582791412">{
|
|
"os-extend": {
|
|
"new_size": 100
|
|
}
|
|
}</pre>
|
|
</li><li id="evs_03_0004__li10817124015112">Example response<p id="evs_03_0004__p1581710408519"><a name="evs_03_0004__li10817124015112"></a><a name="li10817124015112"></a>None</p>
|
|
<div class="p" id="evs_03_0004__p723312591897">or<pre class="screen" id="evs_03_0004__screen2699535114213">{
|
|
"error": {
|
|
"message": "XXXX",
|
|
"code": "XXX"
|
|
}
|
|
}</pre>
|
|
</div>
|
|
<div class="p" id="evs_03_0004__p92381159293">In the preceding example, <strong id="evs_03_0004__b842352706143959">error</strong> indicates a general error, for example, <strong id="evs_03_0004__b842352706144438">badRequest</strong> or <strong id="evs_03_0004__b842352706144454">itemNotFound</strong>. An example is provided as follows:<pre class="screen" id="evs_03_0004__screen5305191315435">{
|
|
"badRequest": {
|
|
"message": "XXXX",
|
|
"code": "XXX"
|
|
}
|
|
}</pre>
|
|
</div>
|
|
</li></ul>
|
|
</li></ol>
|
|
</div>
|
|
</div>
|
|
<div></div>
|
|
|