Details
-
Bug
-
Status: Closed (View Workflow)
-
Blocker
-
Resolution: Fixed
-
6.2.3, 23.02.4
-
Build tested: 6.2.3-1 (#3752), CMAPI 1.6.2 (#600)
Test on a 3-node cluster using Centos 8
This issue was identified when testingMCOL-4954
Tested the follow commands (aliases)
mcsModule
mcsShutdown
mcsStart
mcsReadOnly
mcsReadWrite
After setting the cluster in readonly mode, I tried an insert statement. A DBRM read-only error returned as expected, but it left a table lock in place. After setting the cluster back to readwrite mode, subsequent DML statements also failed because of the table lock.
When the cluster is in readonly, a failed DML state should clear the table lock.
{noformat}
[centos8:root~]# $MCSCLIENT mytest -vvv -e "insert into quicktest values (12, 'readwrite mode')"
--------------
insert into quicktest values (12, 'readwrite mode')
--------------
Query OK, 1 row affected (0.236 sec)
Bye
[centos8:root~]# mcsReadOnly
{
"timestamp": "2022-02-02 20:26:38.826101",
"cluster-mode": "readonly"
}
[centos8:root~]# $MCSCLIENT mytest -vvv -e "insert into quicktest values (12, 'readwrite mode')"
--------------
insert into quicktest values (12, 'readwrite mode')
--------------
ERROR 1815 (HY000) at line 1: Internal error: CAL0001: Insert Failed: a BRM Set hwm error. [BRM error status: DBRM is in READ-ONLY mode]
Bye
[centos8:root~]# viewtablelock
There is 1 table lock
Table LockID Process PID Session Txn CreationTime State DBRoots
mytest.quicktest 7 DMLProc 7782 86 15 Wed Feb 2 20:26:48 2022 LOADING 1,2,3
[centos8:root~]# mcsReadWrite
{
"timestamp": "2022-02-02 20:29:41.277906",
"cluster-mode": "readwrite"
}
[centos8:root~]# $MCSCLIENT mytest -vvv -e "insert into quicktest values (12, 'readwrite mode')"
--------------
insert into quicktest values (12, 'readwrite mode')
--------------
ERROR 1815 (HY000) at line 1: Internal error: CAL0001: Insert Failed: MCS-2009: Unable to perform the insert operation because DMLProc with PID 7782 is currently holding the table lock for session 86.
{noformat}Build tested: 6.2.3-1 (#3752), CMAPI 1.6.2 (#600) Test on a 3-node cluster using Centos 8 This issue was identified when testing MCOL-4954 Tested the follow commands (aliases) mcsModule mcsShutdown mcsStart mcsReadOnly mcsReadWrite After setting the cluster in readonly mode, I tried an insert statement. A DBRM read-only error returned as expected, but it left a table lock in place. After setting the cluster back to readwrite mode, subsequent DML statements also failed because of the table lock. When the cluster is in readonly, a failed DML state should clear the table lock. {noformat} [centos8:root~]# $MCSCLIENT mytest -vvv -e "insert into quicktest values (12, 'readwrite mode')" -------------- insert into quicktest values (12, 'readwrite mode') -------------- Query OK, 1 row affected (0.236 sec) Bye [centos8:root~]# mcsReadOnly { "timestamp": "2022-02-02 20:26:38.826101", "cluster-mode": "readonly" } [centos8:root~]# $MCSCLIENT mytest -vvv -e "insert into quicktest values (12, 'readwrite mode')" -------------- insert into quicktest values (12, 'readwrite mode') -------------- ERROR 1815 (HY000) at line 1: Internal error: CAL0001: Insert Failed: a BRM Set hwm error. [BRM error status: DBRM is in READ-ONLY mode] Bye [centos8:root~]# viewtablelock There is 1 table lock Table LockID Process PID Session Txn CreationTime State DBRoots mytest.quicktest 7 DMLProc 7782 86 15 Wed Feb 2 20:26:48 2022 LOADING 1,2,3 [centos8:root~]# mcsReadWrite { "timestamp": "2022-02-02 20:29:41.277906", "cluster-mode": "readwrite" } [centos8:root~]# $MCSCLIENT mytest -vvv -e "insert into quicktest values (12, 'readwrite mode')" -------------- insert into quicktest values (12, 'readwrite mode') -------------- ERROR 1815 (HY000) at line 1: Internal error: CAL0001: Insert Failed: MCS-2009: Unable to perform the insert operation because DMLProc with PID 7782 is currently holding the table lock for session 86. {noformat}
-
2023-8