forked from docs/doc-exports
Reviewed-by: Hasko, Vladimir <vladimir.hasko@t-systems.com> Co-authored-by: Wang , Deng Ke <wangdengke2@huawei.com> Co-committed-by: Wang , Deng Ke <wangdengke2@huawei.com>
155 lines
13 KiB
HTML
155 lines
13 KiB
HTML
<a name="en-us_topic_0037147510"></a><a name="en-us_topic_0037147510"></a>
|
|
|
|
<h1 class="topictitle1">Querying Database Error Logs</h1>
|
|
<div id="body1473069794004"><div class="section" id="en-us_topic_0037147510__section61759636"><h4 class="sectiontitle">Function</h4><p id="en-us_topic_0037147510__p33831530">This API is used to query database error logs.</p>
|
|
</div>
|
|
<div class="section" id="en-us_topic_0037147510__section18965813"><h4 class="sectiontitle">URI</h4><ul id="en-us_topic_0037147510__ul55999443"><li id="en-us_topic_0037147510__li34232944">URI format<p id="en-us_topic_0037147510__p39661040"><a name="en-us_topic_0037147510__li34232944"></a><a name="li34232944"></a>PATH: /rds/v1/{project_id}/instances/{instanceId}/errorlog</p>
|
|
<p id="en-us_topic_0037147510__p26041291154942">Method: GET</p>
|
|
</li><li id="en-us_topic_0037147510__li21405046">Parameter description
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="en-us_topic_0037147510__table58427690" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="en-us_topic_0037147510__row1482002"><th align="left" class="cellrowborder" valign="top" width="20.93%" id="mcps1.3.2.2.2.1.2.4.1.1"><p id="en-us_topic_0037147510__p52933326"><strong id="en-us_topic_0037147510__b842352706102328_1">Name</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="28.449999999999996%" id="mcps1.3.2.2.2.1.2.4.1.2"><p id="en-us_topic_0037147510__p59740974"><strong id="en-us_topic_0037147510__b842352706102346_1">Mandatory</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="50.62%" id="mcps1.3.2.2.2.1.2.4.1.3"><p id="en-us_topic_0037147510__p7180698"><strong id="en-us_topic_0037147510__b842352706163417_1">Description</strong></p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="en-us_topic_0037147510__row44765691"><td class="cellrowborder" valign="top" width="20.93%" headers="mcps1.3.2.2.2.1.2.4.1.1 "><p id="en-us_topic_0037147510__p2142393">project_id</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="28.449999999999996%" headers="mcps1.3.2.2.2.1.2.4.1.2 "><p id="en-us_topic_0037147510__p39316155">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50.62%" headers="mcps1.3.2.2.2.1.2.4.1.3 "><p id="en-us_topic_0037147510__p30492010">Specifies the project ID of a tenant in a region.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="en-us_topic_0037147510__row5992637"><td class="cellrowborder" valign="top" width="20.93%" headers="mcps1.3.2.2.2.1.2.4.1.1 "><p id="en-us_topic_0037147510__p15641626">instanceId</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="28.449999999999996%" headers="mcps1.3.2.2.2.1.2.4.1.2 "><p id="en-us_topic_0037147510__p59012183">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50.62%" headers="mcps1.3.2.2.2.1.2.4.1.3 "><p id="en-us_topic_0037147510__p7417132564016">Specifies the primary node ID of the DB instance.</p>
|
|
<div class="note" id="en-us_topic_0037147510__note18250133224019"><span class="notetitle"> NOTE: </span><div class="notebody"><p id="en-us_topic_0037147510__p142501332164011">This field is not the DB instance ID. You are advised to use API v3 and the DB instance ID to perform related operations.</p>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="en-us_topic_0037147510__section36474591"><h4 class="sectiontitle">Request</h4><ul id="en-us_topic_0037147510__ul22002111164532"><li id="en-us_topic_0037147510__li3275754184319">Parameter description
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="en-us_topic_0037147510__table22478116" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Parameter description</caption><thead align="left"><tr id="en-us_topic_0037147510__row12299945"><th align="left" class="cellrowborder" valign="top" width="21.490000000000002%" id="mcps1.3.3.2.1.1.2.4.1.1"><p id="en-us_topic_0037147510__p56771492"><strong id="en-us_topic_0037147510__b842352706102328_3">Name</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="28.08%" id="mcps1.3.3.2.1.1.2.4.1.2"><p id="en-us_topic_0037147510__p35088115"><strong id="en-us_topic_0037147510__b842352706102346_5">Mandatory</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="50.43%" id="mcps1.3.3.2.1.1.2.4.1.3"><p id="en-us_topic_0037147510__p23565055"><strong id="en-us_topic_0037147510__b842352706163417_5">Description</strong></p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="en-us_topic_0037147510__row35621668174547"><td class="cellrowborder" valign="top" width="21.490000000000002%" headers="mcps1.3.3.2.1.1.2.4.1.1 "><p id="en-us_topic_0037147510__p24007821174547">startDate</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="28.08%" headers="mcps1.3.3.2.1.1.2.4.1.2 "><p id="en-us_topic_0037147510__p65585369174547">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50.43%" headers="mcps1.3.3.2.1.1.2.4.1.3 "><p id="en-us_topic_0037147510__p10814706174547">Specifies the start time following a specified time translation rule. For example, time "2016-08-29+06:35" is translated into "2016-08-29+06%3A35", where "%3A" is translated from ":" and other digits and characters remain unchanged.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="en-us_topic_0037147510__row56153746174547"><td class="cellrowborder" valign="top" width="21.490000000000002%" headers="mcps1.3.3.2.1.1.2.4.1.1 "><p id="en-us_topic_0037147510__p32183997174547">endDate</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="28.08%" headers="mcps1.3.3.2.1.1.2.4.1.2 "><p id="en-us_topic_0037147510__p56766964174547">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50.43%" headers="mcps1.3.3.2.1.1.2.4.1.3 "><p id="en-us_topic_0037147510__p185070539196">Specifies the end time following a specified time translation rule. For example, time "2016-08-29+06:35" is translated into "2016-08-29+06%3A35", where "%3A" is translated from ":" and other digits and characters remain unchanged.</p>
|
|
<p id="en-us_topic_0037147510__p34721363174547">You can only query error logs generated within a month.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="en-us_topic_0037147510__row50978547174547"><td class="cellrowborder" valign="top" width="21.490000000000002%" headers="mcps1.3.3.2.1.1.2.4.1.1 "><p id="en-us_topic_0037147510__p11832481174547">curPage</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="28.08%" headers="mcps1.3.3.2.1.1.2.4.1.2 "><p id="en-us_topic_0037147510__p18906893174547">No</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50.43%" headers="mcps1.3.3.2.1.1.2.4.1.3 "><p id="en-us_topic_0037147510__p55063325174547">Specifies the current page number, such as 1, 2, 3, or 4. The parameter value is <strong id="en-us_topic_0037147510__b842352706164811">1</strong> by default if it is not specified.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="en-us_topic_0037147510__row28033904174547"><td class="cellrowborder" valign="top" width="21.490000000000002%" headers="mcps1.3.3.2.1.1.2.4.1.1 "><p id="en-us_topic_0037147510__p10063368174547">perPage</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="28.08%" headers="mcps1.3.3.2.1.1.2.4.1.2 "><p id="en-us_topic_0037147510__p9826466174547">No</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50.43%" headers="mcps1.3.3.2.1.1.2.4.1.3 "><p id="en-us_topic_0037147510__p57746301174547">Specifies the number of records on a page. Its value range is from 1 to 100. The parameter value is <strong id="en-us_topic_0037147510__b842352706164925">10</strong> by default if it is not specified.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</li><li id="en-us_topic_0037147510__li57455697143540">Request example<pre class="codeblock" id="en-us_topic_0037147510__codeblock5836437294513">/rds/v1/68e3010955d748099f62a0df726fe09b/instances/02cf1fd7-24ae-4fec-a621-329ec732e4f6/errorlog?startDate=2016-08-29+06%3A35&endDate=2016-09-05+06%3A35&curPage=1&perPage=10</pre>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="en-us_topic_0037147510__section59835867"><h4 class="sectiontitle">Normal Response</h4><ul id="en-us_topic_0037147510__ul66273227"><li id="en-us_topic_0037147510__li59588135">Parameter description
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="en-us_topic_0037147510__table29752153" frame="border" border="1" rules="all"><caption><b>Table 3 </b>Parameter description</caption><thead align="left"><tr id="en-us_topic_0037147510__row62070345"><th align="left" class="cellrowborder" valign="top" width="22.05%" id="mcps1.3.4.2.1.1.2.4.1.1"><p id="en-us_topic_0037147510__p61642077"><strong id="en-us_topic_0037147510__b842352706102328_5">Name</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="27.889999999999997%" id="mcps1.3.4.2.1.1.2.4.1.2"><p id="en-us_topic_0037147510__p26952341"><strong id="en-us_topic_0037147510__b842352706164541_1">Type</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="50.06%" id="mcps1.3.4.2.1.1.2.4.1.3"><p id="en-us_topic_0037147510__p35656026"><strong id="en-us_topic_0037147510__b842352706163417_7">Description</strong></p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="en-us_topic_0037147510__row49943891183823"><td class="cellrowborder" valign="top" width="22.05%" headers="mcps1.3.4.2.1.1.2.4.1.1 "><p id="en-us_topic_0037147510__p17747976183823">errorLogList</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="27.889999999999997%" headers="mcps1.3.4.2.1.1.2.4.1.2 "><p id="en-us_topic_0037147510__p28299952183823">List data structure. For details, see <a href="#en-us_topic_0037147510__table66531170">Table 4</a>.</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50.06%" headers="mcps1.3.4.2.1.1.2.4.1.3 "><p id="en-us_topic_0037147510__p10594789183823">Indicates detailed information.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="en-us_topic_0037147510__row29657875143522"><td class="cellrowborder" valign="top" width="22.05%" headers="mcps1.3.4.2.1.1.2.4.1.1 "><p id="en-us_topic_0037147510__p56278588143531">totalRecord</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="27.889999999999997%" headers="mcps1.3.4.2.1.1.2.4.1.2 "><p id="en-us_topic_0037147510__p62271785143531">Int</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="50.06%" headers="mcps1.3.4.2.1.1.2.4.1.3 "><p id="en-us_topic_0037147510__p10849843143531">Indicates the total number of records.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<div class="tablenoborder"><a name="en-us_topic_0037147510__table66531170"></a><a name="table66531170"></a><table cellpadding="4" cellspacing="0" summary="" id="en-us_topic_0037147510__table66531170" frame="border" border="1" rules="all"><caption><b>Table 4 </b>errorLogList field data structure description</caption><thead align="left"><tr id="en-us_topic_0037147510__row12984378"><th align="left" class="cellrowborder" valign="top" width="22.05%" id="mcps1.3.4.2.1.2.2.4.1.1"><p id="en-us_topic_0037147510__p45101667"><strong id="en-us_topic_0037147510__b842352706102328_7">Name</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="28.07%" id="mcps1.3.4.2.1.2.2.4.1.2"><p id="en-us_topic_0037147510__p29356372"><strong id="en-us_topic_0037147510__b842352706164541_3">Type</strong></p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="49.88%" id="mcps1.3.4.2.1.2.2.4.1.3"><p id="en-us_topic_0037147510__p29055926"><strong id="en-us_topic_0037147510__b842352706163417_9">Description</strong></p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="en-us_topic_0037147510__row4719792"><td class="cellrowborder" valign="top" width="22.05%" headers="mcps1.3.4.2.1.2.2.4.1.1 "><p id="en-us_topic_0037147510__p46758891">datetime</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="28.07%" headers="mcps1.3.4.2.1.2.2.4.1.2 "><p id="en-us_topic_0037147510__p29373839">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="49.88%" headers="mcps1.3.4.2.1.2.2.4.1.3 "><p id="en-us_topic_0037147510__p30470722">Indicates the date and time.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="en-us_topic_0037147510__row5801050"><td class="cellrowborder" valign="top" width="22.05%" headers="mcps1.3.4.2.1.2.2.4.1.1 "><p id="en-us_topic_0037147510__p123050">content</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="28.07%" headers="mcps1.3.4.2.1.2.2.4.1.2 "><p id="en-us_topic_0037147510__p9967070">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="49.88%" headers="mcps1.3.4.2.1.2.2.4.1.3 "><p id="en-us_topic_0037147510__p2026335">Indicates the log content.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</li></ul>
|
|
<ul id="en-us_topic_0037147510__ul26818564"><li id="en-us_topic_0037147510__li40040492">Response example<pre class="codeblock" id="en-us_topic_0037147510__codeblock7093949143442">{
|
|
"errorLogList": [
|
|
{
|
|
"datetime": "2016-08-30 09:55:39",
|
|
"content": "[Warning] 'proxies_priv' entry '@ root@rds-bf83' ignored in --skip-name-resolve mode."
|
|
}
|
|
],
|
|
"totalRecord":1
|
|
}</pre>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="en-us_topic_0037147510__section1651899"><h4 class="sectiontitle">Abnormal Response</h4><p id="en-us_topic_0037147510__p46896054">For details, see <a href="en-us_topic_0032488197.html">Abnormal Request Results</a>.</p>
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<div class="familylinks">
|
|
<div class="parentlink"><strong>Parent topic:</strong> <a href="rds_06_0019.html">Log Information Queries</a></div>
|
|
</div>
|
|
</div>
|
|
|