doc-exports/docs/bms/api-ref/en-us_topic_0053158658.html
guoyanyan c311ecafe3 bms_api_0510
Reviewed-by: Pristromskaia, Margarita <margarita.pristromskaia@t-systems.com>
Co-authored-by: guoyanyan <guoyanyan3@huawei.com>
Co-committed-by: guoyanyan <guoyanyan3@huawei.com>
2023-10-11 08:28:11 +00:00

151 lines
14 KiB
HTML

<a name="EN-US_TOPIC_0053158658"></a><a name="EN-US_TOPIC_0053158658"></a>
<h1 class="topictitle1">Querying Information About the Disks Attached to a <span id="text93761115448">BMS</span><span id="text132783143316"></span><span id="text8624834164819"></span> (Native OpenStack API)</h1>
<div id="body1686169"><div class="section" id="EN-US_TOPIC_0053158658__section61843920"><h4 class="sectiontitle">Function</h4><p id="EN-US_TOPIC_0053158658__p2362032">This API is used to query information about the EVS disks attached to a <span id="EN-US_TOPIC_0053158658__text452213345338">BMS</span><span id="EN-US_TOPIC_0053158658__text1947382572"></span><span id="EN-US_TOPIC_0053158658__text14635838114818"></span>.</p>
</div>
<div class="section" id="EN-US_TOPIC_0053158658__section19724370"><h4 class="sectiontitle">URI</h4><p id="EN-US_TOPIC_0053158658__p8793907163032">GET /v2.1/{project_id}/servers/{server_id}/os-volume_attachments</p>
<p id="EN-US_TOPIC_0053158658__p53528314915"><a href="#EN-US_TOPIC_0053158658__table98221910184910">Table 1</a> lists the parameters.</p>
<div class="tablenoborder"><a name="EN-US_TOPIC_0053158658__table98221910184910"></a><a name="table98221910184910"></a><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0053158658__table98221910184910" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="EN-US_TOPIC_0053158658__row198228100493"><th align="left" class="cellrowborder" valign="top" width="33.33333333333333%" id="mcps1.3.2.4.2.4.1.1"><p id="EN-US_TOPIC_0053158658__p37105578">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="33.33333333333333%" id="mcps1.3.2.4.2.4.1.2"><p id="EN-US_TOPIC_0053158658__p52761866">Mandatory</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="33.33333333333333%" id="mcps1.3.2.4.2.4.1.3"><p id="EN-US_TOPIC_0053158658__p45852771">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="EN-US_TOPIC_0053158658__row482218108494"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.2.4.2.4.1.1 "><p id="EN-US_TOPIC_0053158658__p58102813">project_id</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.2.4.2.4.1.2 "><p id="EN-US_TOPIC_0053158658__p8707407">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.2.4.2.4.1.3 "><p id="EN-US_TOPIC_0053158658__p34211353">Specifies the project ID.</p>
<p id="EN-US_TOPIC_0053158658__p9141450142010">For how to obtain the project ID, see <a href="https://docs.otc.t-systems.com/en-us/api/apiug/apig-en-api-180328009.html" target="_blank" rel="noopener noreferrer">Obtaining Required Information</a>.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0053158658__row082212108498"><td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.2.4.2.4.1.1 "><p id="EN-US_TOPIC_0053158658__p42688329">server_id</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.2.4.2.4.1.2 "><p id="EN-US_TOPIC_0053158658__p35202648">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="33.33333333333333%" headers="mcps1.3.2.4.2.4.1.3 "><p id="EN-US_TOPIC_0053158658__p32842235">Specifies the <span id="EN-US_TOPIC_0053158658__text8345838143314">BMS</span><span id="EN-US_TOPIC_0053158658__text14345738113312"></span><span id="EN-US_TOPIC_0053158658__text20698164734815"></span> ID.</p>
<p id="EN-US_TOPIC_0053158658__p29791113277">You can obtain the BMS ID from the <span id="EN-US_TOPIC_0053158658__en-us_topic_0113746489_text013014803615">BMS</span><span id="EN-US_TOPIC_0053158658__en-us_topic_0113746489_text10131448133612"></span> console or by calling the <a href="en-us_topic_0053158693.html">Querying BMSs (Native OpenStack API)</a>.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="EN-US_TOPIC_0053158658__section43301605"><h4 class="sectiontitle">Request</h4><ul id="EN-US_TOPIC_0053158658__ul5341654455"><li id="EN-US_TOPIC_0053158658__li124556216718">Request parameters<p id="EN-US_TOPIC_0053158658__p6746145179"><a name="EN-US_TOPIC_0053158658__li124556216718"></a><a name="li124556216718"></a>None</p>
</li><li id="EN-US_TOPIC_0053158658__li11346574513">Example request<div class="codecoloring" codetype="Java" id="EN-US_TOPIC_0053158658__screen697510127457"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span></pre></div></td><td class="code"><div><pre><span></span><span class="n">GET</span><span class="w"> </span><span class="n">https</span><span class="p">:</span><span class="c1">//{ECS Endpoint}/v2.1/c685484a8cc2416b97260938705deb65/servers/95bf2490-5428-432c-ad9b-5e3406f869dd/os-volume_attachments</span>
</pre></div></td></tr></table></div>
</div>
</li></ul>
</div>
<div class="section" id="EN-US_TOPIC_0053158658__section54170131"><h4 class="sectiontitle">Response</h4><ul id="EN-US_TOPIC_0053158658__ul56326682"><li id="EN-US_TOPIC_0053158658__li58635765">Response parameters
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0053158658__table57959838" frame="border" border="1" rules="all"><thead align="left"><tr id="EN-US_TOPIC_0053158658__row39710134"><th align="left" class="cellrowborder" valign="top" width="26.08%" id="mcps1.3.4.2.1.1.1.4.1.1"><p id="EN-US_TOPIC_0053158658__p59978491115233">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="25.64%" id="mcps1.3.4.2.1.1.1.4.1.2"><p id="EN-US_TOPIC_0053158658__p26419641115233">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="48.28%" id="mcps1.3.4.2.1.1.1.4.1.3"><p id="EN-US_TOPIC_0053158658__p64181866115233">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="EN-US_TOPIC_0053158658__row62961510"><td class="cellrowborder" valign="top" width="26.08%" headers="mcps1.3.4.2.1.1.1.4.1.1 "><p id="EN-US_TOPIC_0053158658__p66717520">volumeAttachments</p>
</td>
<td class="cellrowborder" valign="top" width="25.64%" headers="mcps1.3.4.2.1.1.1.4.1.2 "><p id="EN-US_TOPIC_0053158658__p49639570">Object</p>
</td>
<td class="cellrowborder" valign="top" width="48.28%" headers="mcps1.3.4.2.1.1.1.4.1.3 "><p id="EN-US_TOPIC_0053158658__p15568903">Specifies information about the disks attached to the <span id="EN-US_TOPIC_0053158658__text10651144263320">BMS</span><span id="EN-US_TOPIC_0053158658__text165113429334"></span><span id="EN-US_TOPIC_0053158658__text4616155354819"></span>. For details, see <a href="#EN-US_TOPIC_0053158658__table7886611">Table 2</a>.</p>
</td>
</tr>
</tbody>
</table>
</div>
<div class="tablenoborder"><a name="EN-US_TOPIC_0053158658__table7886611"></a><a name="table7886611"></a><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0053158658__table7886611" frame="border" border="1" rules="all"><caption><b>Table 2 </b><strong id="EN-US_TOPIC_0053158658__b42501615577">volumeAttachments</strong> field data structure description</caption><thead align="left"><tr id="EN-US_TOPIC_0053158658__row60727582"><th align="left" class="cellrowborder" valign="top" width="26.437356264373562%" id="mcps1.3.4.2.1.2.2.4.1.1"><p id="EN-US_TOPIC_0053158658__p19987085">Parameter</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="25.42745725427458%" id="mcps1.3.4.2.1.2.2.4.1.2"><p id="EN-US_TOPIC_0053158658__p4546697">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="48.135186481351866%" id="mcps1.3.4.2.1.2.2.4.1.3"><p id="EN-US_TOPIC_0053158658__p32738149">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="EN-US_TOPIC_0053158658__row34544438"><td class="cellrowborder" valign="top" width="26.437356264373562%" headers="mcps1.3.4.2.1.2.2.4.1.1 "><p id="EN-US_TOPIC_0053158658__p46636132">device</p>
</td>
<td class="cellrowborder" valign="top" width="25.42745725427458%" headers="mcps1.3.4.2.1.2.2.4.1.2 "><p id="EN-US_TOPIC_0053158658__p30355189">String</p>
</td>
<td class="cellrowborder" valign="top" width="48.135186481351866%" headers="mcps1.3.4.2.1.2.2.4.1.3 "><p id="EN-US_TOPIC_0053158658__p50116845">Specifies the mount directory, for example, <strong id="EN-US_TOPIC_0053158658__b236312145244">/dev/vdb</strong>.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0053158658__row48398424"><td class="cellrowborder" valign="top" width="26.437356264373562%" headers="mcps1.3.4.2.1.2.2.4.1.1 "><p id="EN-US_TOPIC_0053158658__p27958252">id</p>
</td>
<td class="cellrowborder" valign="top" width="25.42745725427458%" headers="mcps1.3.4.2.1.2.2.4.1.2 "><p id="EN-US_TOPIC_0053158658__p25568738">String</p>
</td>
<td class="cellrowborder" valign="top" width="48.135186481351866%" headers="mcps1.3.4.2.1.2.2.4.1.3 "><p id="EN-US_TOPIC_0053158658__p50454834">Specifies the ID of the attached resource.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0053158658__row51440330"><td class="cellrowborder" valign="top" width="26.437356264373562%" headers="mcps1.3.4.2.1.2.2.4.1.1 "><p id="EN-US_TOPIC_0053158658__p5917164">serverId</p>
</td>
<td class="cellrowborder" valign="top" width="25.42745725427458%" headers="mcps1.3.4.2.1.2.2.4.1.2 "><p id="EN-US_TOPIC_0053158658__p33594135">String</p>
</td>
<td class="cellrowborder" valign="top" width="48.135186481351866%" headers="mcps1.3.4.2.1.2.2.4.1.3 "><p id="EN-US_TOPIC_0053158658__p62498284">Specifies the ID of the <span id="EN-US_TOPIC_0053158658__text194132454338">BMS</span><span id="EN-US_TOPIC_0053158658__text641384517333"></span><span id="EN-US_TOPIC_0053158658__text164261359124819"></span> to which the disks are attached.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0053158658__row25613652"><td class="cellrowborder" valign="top" width="26.437356264373562%" headers="mcps1.3.4.2.1.2.2.4.1.1 "><p id="EN-US_TOPIC_0053158658__p61439917">volumeId</p>
</td>
<td class="cellrowborder" valign="top" width="25.42745725427458%" headers="mcps1.3.4.2.1.2.2.4.1.2 "><p id="EN-US_TOPIC_0053158658__p51461341">String</p>
</td>
<td class="cellrowborder" valign="top" width="48.135186481351866%" headers="mcps1.3.4.2.1.2.2.4.1.3 "><p id="EN-US_TOPIC_0053158658__p1462819">Specifies the IDs of the EVS disks attached to the BMS.</p>
</td>
</tr>
</tbody>
</table>
</div>
</li></ul>
<ul id="EN-US_TOPIC_0053158658__ul20126322103640"><li id="EN-US_TOPIC_0053158658__li46919170103640">Example response<div class="codecoloring" codetype="Java" id="EN-US_TOPIC_0053158658__screen34284862202756"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span>
<span class="normal">2</span>
<span class="normal">3</span>
<span class="normal">4</span>
<span class="normal">5</span>
<span class="normal">6</span>
<span class="normal">7</span>
<span class="normal">8</span></pre></div></td><td class="code"><div><pre><span></span><span class="p">{</span>
<span class="w"> </span><span class="s">&quot;volumeAttachments&quot;</span><span class="p">:</span><span class="w"> </span><span class="p">{</span>
<span class="w"> </span><span class="s">&quot;device&quot;</span><span class="p">:</span><span class="w"> </span><span class="s">&quot;/dev/vdb&quot;</span><span class="p">,</span>
<span class="w"> </span><span class="s">&quot;serverId&quot;</span><span class="p">:</span><span class="w"> </span><span class="s">&quot;820abbd0-2d8e-4bc5-ae46-69cacfd4fbaa&quot;</span><span class="p">,</span>
<span class="w"> </span><span class="s">&quot;id&quot;</span><span class="p">:</span><span class="w"> </span><span class="s">&quot;b53f23bd-ee8f-49ec-9420-d1acfeaf91d6&quot;</span><span class="p">,</span>
<span class="w"> </span><span class="s">&quot;volumeId&quot;</span><span class="p">:</span><span class="w"> </span><span class="s">&quot;b53f23bd-ee8f-49ec-9420-d1acfeaf91d6&quot;</span>
<span class="w"> </span><span class="p">}</span>
<span class="p">}</span>
</pre></div></td></tr></table></div>
</div>
</li></ul>
</div>
<div class="section" id="EN-US_TOPIC_0053158658__section7610951"><h4 class="sectiontitle">Returned Values</h4><div class="p" id="EN-US_TOPIC_0053158658__en-us_topic_0106040941_p193201622141412">Normal values
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0053158658__en-us_topic_0106040941_table753804619176" frame="border" border="1" rules="all"><thead align="left"><tr id="EN-US_TOPIC_0053158658__en-us_topic_0106040941_row10735134615172"><th align="left" class="cellrowborder" valign="top" width="42.42%" id="mcps1.3.5.2.1.1.3.1.1"><p id="EN-US_TOPIC_0053158658__en-us_topic_0106040941_p19735204616177">Returned Values</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="57.58%" id="mcps1.3.5.2.1.1.3.1.2"><p id="EN-US_TOPIC_0053158658__en-us_topic_0106040941_p207355465176">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="EN-US_TOPIC_0053158658__en-us_topic_0106040941_row1473514621713"><td class="cellrowborder" valign="top" width="42.42%" headers="mcps1.3.5.2.1.1.3.1.1 "><p id="EN-US_TOPIC_0053158658__en-us_topic_0106040941_p13735144611178">200</p>
</td>
<td class="cellrowborder" valign="top" width="57.58%" headers="mcps1.3.5.2.1.1.3.1.2 "><p id="EN-US_TOPIC_0053158658__en-us_topic_0106040941_p207351246161711">The request has been successfully processed.</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<p id="EN-US_TOPIC_0053158658__en-us_topic_0106040941_p47633965">For details about other returned values, see <a href="en-us_topic_0053158690.html">Status Codes</a>.</p>
</div>
<div class="section" id="EN-US_TOPIC_0053158658__section14752650154917"><h4 class="sectiontitle">Error Codes</h4><p id="EN-US_TOPIC_0053158658__en-us_topic_0106040941_p10243161417491">See <a href="en-us_topic_0107541808.html">Error Codes</a>.</p>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="en-us_topic_0053158703.html">BMS Disk Management</a></div>
</div>
</div>