doc-exports/docs/dws/dev/dws_04_0696.html
Lu, Huayi e6fa411af0 DWS DEV 830.201 version
Reviewed-by: Pruthi, Vineet <vineet.pruthi@t-systems.com>
Co-authored-by: Lu, Huayi <luhuayi@huawei.com>
Co-committed-by: Lu, Huayi <luhuayi@huawei.com>
2024-05-16 07:24:04 +00:00

91 lines
11 KiB
HTML

<a name="EN-US_TOPIC_0000001188482296"></a><a name="EN-US_TOPIC_0000001188482296"></a>
<h1 class="topictitle1">GS_WAIT_EVENTS</h1>
<div id="body0000001083440660"><p id="EN-US_TOPIC_0000001188482296__p10370101818101"><strong id="EN-US_TOPIC_0000001188482296__b15914193912354">GS_WAIT_EVENTS</strong> displays statistics about waiting status and events on the current node.</p>
<p id="EN-US_TOPIC_0000001188482296__p3939311131911">The values of statistical columns in this view are accumulated only when the <strong id="EN-US_TOPIC_0000001188482296__b8889175164111">enable_track_wait_event</strong> GUC parameter is set to <strong id="EN-US_TOPIC_0000001188482296__b136131000423">on</strong>. If <strong id="EN-US_TOPIC_0000001188482296__b1942577124214">enable_track_wait_event</strong> is set to <strong id="EN-US_TOPIC_0000001188482296__b19395191244218">off</strong> during statistics measurement, the statistics will no longer be accumulated, but the existing values are not affected. If <strong id="EN-US_TOPIC_0000001188482296__b793534817434">enable_track_wait_event</strong> is <strong id="EN-US_TOPIC_0000001188482296__b311419515435">off</strong>, 0 row is returned when this view is queried.</p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000001188482296__table1890982764520" width="100%" frame="border" border="1" rules="all"><caption><b>Table 1 </b>GS_WAIT_EVENTS columns</caption><thead align="left"><tr id="EN-US_TOPIC_0000001188482296__row1094912711450"><th align="left" class="cellrowborder" valign="top" width="26.090000000000003%" id="mcps1.3.3.2.4.1.1"><p id="EN-US_TOPIC_0000001188482296__p4949027124515">Name</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="23.11%" id="mcps1.3.3.2.4.1.2"><p id="EN-US_TOPIC_0000001188482296__p1949927124516">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="50.8%" id="mcps1.3.3.2.4.1.3"><p id="EN-US_TOPIC_0000001188482296__p17949172784516">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="EN-US_TOPIC_0000001188482296__row994912273453"><td class="cellrowborder" valign="top" width="26.090000000000003%" headers="mcps1.3.3.2.4.1.1 "><p id="EN-US_TOPIC_0000001188482296__p311175391913">nodename</p>
</td>
<td class="cellrowborder" valign="top" width="23.11%" headers="mcps1.3.3.2.4.1.2 "><p id="EN-US_TOPIC_0000001188482296__p121145361911">name</p>
</td>
<td class="cellrowborder" valign="top" width="50.8%" headers="mcps1.3.3.2.4.1.3 "><p id="EN-US_TOPIC_0000001188482296__p911125318199">Node name</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188482296__row17949527164513"><td class="cellrowborder" valign="top" width="26.090000000000003%" headers="mcps1.3.3.2.4.1.1 "><p id="EN-US_TOPIC_0000001188482296__p181111534191">type</p>
</td>
<td class="cellrowborder" valign="top" width="23.11%" headers="mcps1.3.3.2.4.1.2 "><p id="EN-US_TOPIC_0000001188482296__p2111353191916">text</p>
</td>
<td class="cellrowborder" valign="top" width="50.8%" headers="mcps1.3.3.2.4.1.3 "><p id="EN-US_TOPIC_0000001188482296__p161115318194">Event type, which can be <strong id="EN-US_TOPIC_0000001188482296__b1843122810368">STATUS</strong>, <strong id="EN-US_TOPIC_0000001188482296__b883116306363">LOCK_EVENT</strong>, <strong id="EN-US_TOPIC_0000001188482296__b1573116323361">LWLOCK_EVENT</strong>, or <strong id="EN-US_TOPIC_0000001188482296__b95479346369">IO_EVENT</strong></p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188482296__row1795072794515"><td class="cellrowborder" valign="top" width="26.090000000000003%" headers="mcps1.3.3.2.4.1.1 "><p id="EN-US_TOPIC_0000001188482296__p1812115381913">event</p>
</td>
<td class="cellrowborder" valign="top" width="23.11%" headers="mcps1.3.3.2.4.1.2 "><p id="EN-US_TOPIC_0000001188482296__p912653131913">text</p>
</td>
<td class="cellrowborder" valign="top" width="50.8%" headers="mcps1.3.3.2.4.1.3 "><p id="EN-US_TOPIC_0000001188482296__p1112453181918">Event name. For details, see <a href="dws_04_0783.html">PG_THREAD_WAIT_STATUS</a>.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188482296__row595012279452"><td class="cellrowborder" valign="top" width="26.090000000000003%" headers="mcps1.3.3.2.4.1.1 "><p id="EN-US_TOPIC_0000001188482296__p81225320196">wait</p>
</td>
<td class="cellrowborder" valign="top" width="23.11%" headers="mcps1.3.3.2.4.1.2 "><p id="EN-US_TOPIC_0000001188482296__p16121253161912">bigint</p>
</td>
<td class="cellrowborder" valign="top" width="50.8%" headers="mcps1.3.3.2.4.1.3 "><p id="EN-US_TOPIC_0000001188482296__p112115391919">Number of times an event occurs. This column and all the columns below are values accumulated during process running.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188482296__row1950927134512"><td class="cellrowborder" valign="top" width="26.090000000000003%" headers="mcps1.3.3.2.4.1.1 "><p id="EN-US_TOPIC_0000001188482296__p131245316191">failed_wait</p>
</td>
<td class="cellrowborder" valign="top" width="23.11%" headers="mcps1.3.3.2.4.1.2 "><p id="EN-US_TOPIC_0000001188482296__p1612165320199">bigint</p>
</td>
<td class="cellrowborder" valign="top" width="50.8%" headers="mcps1.3.3.2.4.1.3 "><p id="EN-US_TOPIC_0000001188482296__p312165316196">Number of waiting failures. In the current version, this column is used only for counting timeout errors and waiting failures of locks such as <strong id="EN-US_TOPIC_0000001188482296__b18293118153817">LOCK</strong> and <strong id="EN-US_TOPIC_0000001188482296__b139074913383">LWLOCK</strong>.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188482296__row2950192713459"><td class="cellrowborder" valign="top" width="26.090000000000003%" headers="mcps1.3.3.2.4.1.1 "><p id="EN-US_TOPIC_0000001188482296__p101285301910">total_wait_time</p>
</td>
<td class="cellrowborder" valign="top" width="23.11%" headers="mcps1.3.3.2.4.1.2 "><p id="EN-US_TOPIC_0000001188482296__p1312145321916">bigint</p>
</td>
<td class="cellrowborder" valign="top" width="50.8%" headers="mcps1.3.3.2.4.1.3 "><p id="EN-US_TOPIC_0000001188482296__p10121353101913">Total duration of the event</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188482296__row1495042718451"><td class="cellrowborder" valign="top" width="26.090000000000003%" headers="mcps1.3.3.2.4.1.1 "><p id="EN-US_TOPIC_0000001188482296__p612165311915">avg_wait_time</p>
</td>
<td class="cellrowborder" valign="top" width="23.11%" headers="mcps1.3.3.2.4.1.2 "><p id="EN-US_TOPIC_0000001188482296__p101365316197">bigint</p>
</td>
<td class="cellrowborder" valign="top" width="50.8%" headers="mcps1.3.3.2.4.1.3 "><p id="EN-US_TOPIC_0000001188482296__p16131553181911">Average duration of the event</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188482296__row119500273457"><td class="cellrowborder" valign="top" width="26.090000000000003%" headers="mcps1.3.3.2.4.1.1 "><p id="EN-US_TOPIC_0000001188482296__p111317535194">max_wait_time</p>
</td>
<td class="cellrowborder" valign="top" width="23.11%" headers="mcps1.3.3.2.4.1.2 "><p id="EN-US_TOPIC_0000001188482296__p91385351919">bigint</p>
</td>
<td class="cellrowborder" valign="top" width="50.8%" headers="mcps1.3.3.2.4.1.3 "><p id="EN-US_TOPIC_0000001188482296__p9131253141918">Maximum wait time of the event</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188482296__row12950142719457"><td class="cellrowborder" valign="top" width="26.090000000000003%" headers="mcps1.3.3.2.4.1.1 "><p id="EN-US_TOPIC_0000001188482296__p81395301912">min_wait_time</p>
</td>
<td class="cellrowborder" valign="top" width="23.11%" headers="mcps1.3.3.2.4.1.2 "><p id="EN-US_TOPIC_0000001188482296__p7131353161916">bigint</p>
</td>
<td class="cellrowborder" valign="top" width="50.8%" headers="mcps1.3.3.2.4.1.3 "><p id="EN-US_TOPIC_0000001188482296__p171355371914">Minimum wait time of the event</p>
</td>
</tr>
</tbody>
</table>
</div>
<p id="EN-US_TOPIC_0000001188482296__p20498142211274">In the current version, for events whose <strong id="EN-US_TOPIC_0000001188482296__b594643103917">type</strong> is <strong id="EN-US_TOPIC_0000001188482296__b1975974483910">LOCK_EVENT</strong>, <strong id="EN-US_TOPIC_0000001188482296__b17463195283913">LWLOCK_EVENT</strong>, or <strong id="EN-US_TOPIC_0000001188482296__b2312555396">IO_EVENT</strong>, the display scope of <strong id="EN-US_TOPIC_0000001188482296__b1727187104018">GS_WAIT_EVENTS</strong> is the same as that of the corresponding events in the <a href="dws_04_0783.html">PG_THREAD_WAIT_STATUS</a> view.</p>
<p id="EN-US_TOPIC_0000001188482296__p18134153742611">For events whose <strong id="EN-US_TOPIC_0000001188482296__b1366383511403">type</strong> is <strong id="EN-US_TOPIC_0000001188482296__b33061139104012">STATUS</strong>, <strong id="EN-US_TOPIC_0000001188482296__b1767044212407">GS_WAIT_EVENTS</strong> displays the following waiting status columns. For details, see the <a href="dws_04_0783.html">PG_THREAD_WAIT_STATUS</a> view.</p>
<ul id="EN-US_TOPIC_0000001188482296__ul39341218172212"><li id="EN-US_TOPIC_0000001188482296__li23077263262">acquire lwlock</li><li id="EN-US_TOPIC_0000001188482296__li13934618172210">acquire lock</li><li id="EN-US_TOPIC_0000001188482296__li13935141842211">wait io</li><li id="EN-US_TOPIC_0000001188482296__li20935161813223">wait pooler get conn</li><li id="EN-US_TOPIC_0000001188482296__li79353183221">wait pooler abort conn</li><li id="EN-US_TOPIC_0000001188482296__li593521817221">wait pooler clean conn</li><li id="EN-US_TOPIC_0000001188482296__li17935121892215">wait transaction sync</li><li id="EN-US_TOPIC_0000001188482296__li8935111842217">wait wal sync</li><li id="EN-US_TOPIC_0000001188482296__li8935818122215">wait data sync</li><li id="EN-US_TOPIC_0000001188482296__li1993641816222">wait producer ready</li><li id="EN-US_TOPIC_0000001188482296__li20936181812222">create index</li><li id="EN-US_TOPIC_0000001188482296__li189361018122216">analyze</li><li id="EN-US_TOPIC_0000001188482296__li1936318182214">vacuum</li><li id="EN-US_TOPIC_0000001188482296__li2936131816228">vacuum full</li><li id="EN-US_TOPIC_0000001188482296__li2936191819224">gtm connect</li><li id="EN-US_TOPIC_0000001188482296__li69361518132218">gtm begin trans</li><li id="EN-US_TOPIC_0000001188482296__li193771811229">gtm commit trans</li><li id="EN-US_TOPIC_0000001188482296__li159375184228">gtm rollback trans</li><li id="EN-US_TOPIC_0000001188482296__li1937141812219">gtm create sequence</li><li id="EN-US_TOPIC_0000001188482296__li7937161862218">gtm alter sequence</li><li id="EN-US_TOPIC_0000001188482296__li1093771862214">gtm get sequence val</li><li id="EN-US_TOPIC_0000001188482296__li1937181817225">gtm set sequence val</li><li id="EN-US_TOPIC_0000001188482296__li199377182229">gtm drop sequence</li><li id="EN-US_TOPIC_0000001188482296__li139392018202214">gtm rename sequence</li></ul>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="dws_04_0639.html">System Views</a></div>
</div>
</div>