doc-exports/docs/dws/dev/dws_04_0809.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

145 lines
13 KiB
HTML

<a name="EN-US_TOPIC_0000001188323702"></a><a name="EN-US_TOPIC_0000001188323702"></a>
<h1 class="topictitle1">PGXC_LOCK_CONFLICTS</h1>
<div id="body0000001080817662"><p id="EN-US_TOPIC_0000001188323702__p8060118"><strong id="EN-US_TOPIC_0000001188323702__b18635131161720">PGXC_LOCK_CONFLICTS</strong> displays information about conflicting locks in the cluster.</p>
<p id="EN-US_TOPIC_0000001188323702__p889741265214">When a lock is waiting for another lock or another lock is waiting for this one, a lock conflict occurs.</p>
<p id="EN-US_TOPIC_0000001188323702__p8621720165911">Currently, <strong id="EN-US_TOPIC_0000001188323702__b14976716198">PGXC_LOCK_CONFLICTS</strong> collects only information about locks whose <strong id="EN-US_TOPIC_0000001188323702__b631015116191">locktype</strong> is <strong id="EN-US_TOPIC_0000001188323702__b141516130193">relation</strong>, <strong id="EN-US_TOPIC_0000001188323702__b12183121610190">partition</strong>, <strong id="EN-US_TOPIC_0000001188323702__b1053661717196">page</strong>, <strong id="EN-US_TOPIC_0000001188323702__b697020131918">tuple</strong>, or <strong id="EN-US_TOPIC_0000001188323702__b189293220191">transactionid</strong>.</p>
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="EN-US_TOPIC_0000001188323702__table18928185635412" frame="border" border="1" rules="all"><caption><b>Table 1 </b>PGXC_LOCK_CONFLICTS columns</caption><thead align="left"><tr id="EN-US_TOPIC_0000001188323702__row11928956125419"><th align="left" class="cellrowborder" valign="top" width="20.49204920492049%" id="mcps1.3.4.2.4.1.1"><p id="EN-US_TOPIC_0000001188323702__p49281956135417">Name</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="21.62216221622162%" id="mcps1.3.4.2.4.1.2"><p id="EN-US_TOPIC_0000001188323702__p39293566542">Type</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="57.88578857885789%" id="mcps1.3.4.2.4.1.3"><p id="EN-US_TOPIC_0000001188323702__p8929145613541">Description</p>
</th>
</tr>
</thead>
<tbody><tr id="EN-US_TOPIC_0000001188323702__row1592914567548"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p18929856195419">locktype</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p169291056125416">text</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000001188323702__p4917140134610">Type of the locked object</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188323702__row79290568549"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p29296564540">nodename</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p119291056195414">name</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000001188323702__p69291556175414">Name of the node where the locked object resides</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188323702__row992995612544"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p14929556135419">dbname</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p159291556205411">name</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000001188323702__p592985619547">Name of the database where the locked object resides. The value is <strong id="EN-US_TOPIC_0000001188323702__b3951173082015">NULL</strong> if the locked object is a transaction.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188323702__row39299562542"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p149291456115411">nspname</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p1392995665411">name</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000001188323702__p17917134019469">Name of the namespace of the locked object</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188323702__row1929256165416"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p139291256125416">relname</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p1992915568548">name</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000001188323702__p8929185615413">Name of the relation targeted by the lock. The value is <strong id="EN-US_TOPIC_0000001188323702__b354419342311">NULL</strong> if the object is not a relation or part of a relation.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188323702__row159291056125414"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p18929656175418">partname</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p39291656135410">name</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000001188323702__p1692911560549">Name of the partition targeted by the lock. The value is <strong id="EN-US_TOPIC_0000001188323702__b6735029102512">NULL</strong> if the locked object is not a partition.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188323702__row692935620546"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p1992913564541">page</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p1692919563549">integer</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000001188323702__p179293561549">Number of the page targeted by the lock. The value is <strong id="EN-US_TOPIC_0000001188323702__b14186175318262">NULL</strong> if the locked object is neither a page nor a tuple.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188323702__row16929155617544"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p159291756135412">tuple</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p6929256125416">smallint</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000001188323702__p59291056205413">Number of the tuple targeted by the lock. The value is <strong id="EN-US_TOPIC_0000001188323702__b1959818204273">NULL</strong> if the locked object is not a tuple.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188323702__row9929165613548"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p59292563547">transactionid</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p1393095617543">xid</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000001188323702__p8930165645414">ID of the transaction targeted by the lock. The value is <strong id="EN-US_TOPIC_0000001188323702__b113481823152820">NULL</strong> if the locked object is not a transaction.</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188323702__row5930956145411"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p159301756115411">username</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p1793035612547">name</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000001188323702__p1193011566543">Name of the user who applies for the lock</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188323702__row093015616541"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p1293010567549">gxid</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p8930956165414">xid</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000001188323702__p1793010564548">ID of the transaction that applies for the lock</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188323702__row1993045614547"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p9930756145418">xactstart</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p893010565542">timestamp with time zone</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000001188323702__p79303566543">Start time of the transaction that applies for the lock</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188323702__row2930145605412"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p89301956155419">queryid</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p11930205620543">bigint</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000001188323702__p193015561542">Latest query ID of the thread that applies for the lock</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188323702__row1593075615411"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p17930556205415">query</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p12930856145415">text</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000001188323702__p11930056175416">Latest query statement of the thread that applies for the lock</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188323702__row18930556115418"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p1993055695413">pid</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p159301556105417">bigint</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000001188323702__p39301956175415">ID of the thread that applies for the lock</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188323702__row693055618544"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p1193013565543">mode</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p393055695415">text</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><p id="EN-US_TOPIC_0000001188323702__p20930185615548">Lock mode</p>
</td>
</tr>
<tr id="EN-US_TOPIC_0000001188323702__row169301656125416"><td class="cellrowborder" valign="top" width="20.49204920492049%" headers="mcps1.3.4.2.4.1.1 "><p id="EN-US_TOPIC_0000001188323702__p1293013563542">granted</p>
</td>
<td class="cellrowborder" valign="top" width="21.62216221622162%" headers="mcps1.3.4.2.4.1.2 "><p id="EN-US_TOPIC_0000001188323702__p199301956165417">boolean</p>
</td>
<td class="cellrowborder" valign="top" width="57.88578857885789%" headers="mcps1.3.4.2.4.1.3 "><ul id="EN-US_TOPIC_0000001188323702__ul123958615114"><li id="EN-US_TOPIC_0000001188323702__li18395264119"><strong id="EN-US_TOPIC_0000001188323702__b1975465872916">TRUE</strong> if the lock has been held</li><li id="EN-US_TOPIC_0000001188323702__li2034418171110"><strong id="EN-US_TOPIC_0000001188323702__b14899169143010">FALSE</strong> if the lock is still waiting for another lock</li></ul>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="dws_04_0639.html">System Views</a></div>
</div>
</div>