forked from docs/doc-exports
Reviewed-by: Hajba, László Antal <laszlo-antal.hajba@t-systems.com> Co-authored-by: Hongwei, King Wang <king.wanghongwei@huawei.com> Co-committed-by: Hongwei, King Wang <king.wanghongwei@huawei.com>
119 lines
12 KiB
HTML
119 lines
12 KiB
HTML
<a name="EN-US_TOPIC_0000002343850520"></a><a name="EN-US_TOPIC_0000002343850520"></a>
|
|
|
|
<h1 class="topictitle1">Querying VPN Connection Logs</h1>
|
|
<div id="body8662426"><div class="section" id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_section20114008"><h4 class="sectiontitle">Function</h4><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p142661254167">This API is used to query logs of a VPN connection with a specified connection ID.</p>
|
|
</div>
|
|
<div class="section" id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_section18104173342818"><h4 class="sectiontitle">Calling Method</h4><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p141046483329">For details, see <a href="vpn_api_0008.html#EN-US_TOPIC_0000001807530276">Calling APIs</a>.</p>
|
|
</div>
|
|
<div class="section" id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_section46808346"><h4 class="sectiontitle">URI</h4><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p1352174255110">GET /v5/{project_id}/vpn-connection/{vpn_connection_id}/log</p>
|
|
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_table3672032" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Parameter description</caption><thead align="left"><tr id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_row10026740"><th align="left" class="cellrowborder" valign="top" width="20.61793820617938%" id="mcps1.3.3.3.2.5.1.1"><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p6859639">Parameter</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="19.02809719028097%" id="mcps1.3.3.3.2.5.1.2"><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p179611479215">Type</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="11.798820117988202%" id="mcps1.3.3.3.2.5.1.3"><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p18759866">Mandatory</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="48.555144485551445%" id="mcps1.3.3.3.2.5.1.4"><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p43154149">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_row5825185"><td class="cellrowborder" valign="top" width="20.61793820617938%" headers="mcps1.3.3.3.2.5.1.1 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p2077973">project_id</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="19.02809719028097%" headers="mcps1.3.3.3.2.5.1.2 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p177965479212">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="11.798820117988202%" headers="mcps1.3.3.3.2.5.1.3 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p34098154">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="48.555144485551445%" headers="mcps1.3.3.3.2.5.1.4 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p199639252285">Specifies a project ID. You can obtain the project ID by referring to <a href="vpn_api_0051.html#EN-US_TOPIC_0000001807530332">Obtaining the Project ID</a>.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_row2011282117553"><td class="cellrowborder" valign="top" width="20.61793820617938%" headers="mcps1.3.3.3.2.5.1.1 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p172701540610">vpn_connection_id</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="19.02809719028097%" headers="mcps1.3.3.3.2.5.1.2 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p6270354061">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="11.798820117988202%" headers="mcps1.3.3.3.2.5.1.3 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p1027015542613">Yes</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="48.555144485551445%" headers="mcps1.3.3.3.2.5.1.4 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p82710544610">Specifies a VPN connection ID.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<div class="section" id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_section18621933"><h4 class="sectiontitle">Request</h4><ul id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_ul5992193374713"><li id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_li154271011149">Request parameters<p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p1855835810719"><a name="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_li154271011149"></a><a name="en-us_topic_0000002163291185_li154271011149"></a>None</p>
|
|
</li><li id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_li18143155715912">Example request<pre class="screen" id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_screen1778465375316">GET https://{Endpoint}/v5/{project_id}/vpn-connection/{vpn_connection_id}/log</pre>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_section33379675"><h4 class="sectiontitle">Response</h4><ul id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_ul2144514204819"><li id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_li61441714114816">Response parameters<p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p13276175413613"><a name="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_li61441714114816"></a><a name="en-us_topic_0000002163291185_li61441714114816"></a>Returned status code 200: successful operation</p>
|
|
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_table92829" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Parameters in the response body</caption><thead align="left"><tr id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_row104417415155"><th align="left" class="cellrowborder" valign="top" width="22.220000000000002%" id="mcps1.3.5.2.1.2.2.4.1.1"><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p164454151512">Parameter</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="22.220000000000002%" id="mcps1.3.5.2.1.2.2.4.1.2"><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p1945154201519">Type</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="55.559999999999995%" id="mcps1.3.5.2.1.2.2.4.1.3"><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p1445746158">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_row104419461517"><td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.2.2.4.1.1 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p1458461511">logs</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.2.2.4.1.2 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p12111852152819">Array of <a href="#EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_table92830">Log</a> objects</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="55.559999999999995%" headers="mcps1.3.5.2.1.2.2.4.1.3 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p124616461512">Specifies the log object.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_row644194131510"><td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.2.2.4.1.1 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p64644111514">request_id</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.2.2.4.1.2 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p64615411159">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="55.559999999999995%" headers="mcps1.3.5.2.1.2.2.4.1.3 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p154611418155">Specifies a request ID.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
<div class="tablenoborder"><a name="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_table92830"></a><a name="en-us_topic_0000002163291185_table92830"></a><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_table92830" frame="border" border="1" rules="all"><caption><b>Table 3 </b>Log</caption><thead align="left"><tr id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_row144774101515"><th align="left" class="cellrowborder" valign="top" width="22.220000000000002%" id="mcps1.3.5.2.1.3.2.4.1.1"><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p174814101518">Parameter</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="22.2%" id="mcps1.3.5.2.1.3.2.4.1.2"><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p44814410153">Type</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="55.58%" id="mcps1.3.5.2.1.3.2.4.1.3"><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p134818417159">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_row74719421510"><td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.3.2.4.1.1 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p18473132910519">time</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="22.2%" headers="mcps1.3.5.2.1.3.2.4.1.2 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p847317291758">Integer</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="55.58%" headers="mcps1.3.5.2.1.3.2.4.1.3 "><ul id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_ul1064673414438"><li id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_li4646123404312">Specifies the timestamp.</li></ul>
|
|
</td>
|
|
</tr>
|
|
<tr id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_row184718411512"><td class="cellrowborder" valign="top" width="22.220000000000002%" headers="mcps1.3.5.2.1.3.2.4.1.1 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p9473329351">raw_message</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="22.2%" headers="mcps1.3.5.2.1.3.2.4.1.2 "><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p147316291953">String</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="55.58%" headers="mcps1.3.5.2.1.3.2.4.1.3 "><ul id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_ul1257530132415"><li id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_li984125514435">Specifies log information.</li></ul>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</li><li id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_li8669132111017">Example response<pre class="screen" id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_screen678017232489">{
|
|
"logs": [
|
|
{
|
|
"time": 1735024112,
|
|
"raw_message": "2024-12-24T07:08:32.730275+00:00 host-xx-xx-xx-xx ipsec_ike[30085]: [xx.xx.xx.xx] IPSec tunnel negotiation fails. (IfIndex=[207], PolicyName=[], SeqNum=[0], PeerAddress=[xx.xx.xx.xx], PeerPort=[500], Reason=[version mismatch])"
|
|
}
|
|
],
|
|
"request_id": "f15d2c621593f2018c23eb1d49e3605e"
|
|
}</pre>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_section31981619"><h4 class="sectiontitle">Status Codes</h4><p id="EN-US_TOPIC_0000002343850520__en-us_topic_0000002163291185_p18112112662914">For details, see <a href="vpn_api_0052.html#EN-US_TOPIC_0000001807370508">Status Codes</a>.</p>
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<div class="familylinks">
|
|
<div class="parentlink"><strong>Parent topic:</strong> <a href="vpn_api_0026.html">VPN Connection</a></div>
|
|
</div>
|
|
</div>
|
|
|