Return-Path: X-Original-To: apmail-db-derby-dev-archive@www.apache.org Delivered-To: apmail-db-derby-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id AAD92909D for ; Fri, 21 Oct 2011 18:34:56 +0000 (UTC) Received: (qmail 54370 invoked by uid 500); 21 Oct 2011 18:34:56 -0000 Delivered-To: apmail-db-derby-dev-archive@db.apache.org Received: (qmail 54349 invoked by uid 500); 21 Oct 2011 18:34:56 -0000 Mailing-List: contact derby-dev-help@db.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: Delivered-To: mailing list derby-dev@db.apache.org Received: (qmail 54342 invoked by uid 99); 21 Oct 2011 18:34:56 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 21 Oct 2011 18:34:56 +0000 X-ASF-Spam-Status: No, hits=-2000.5 required=5.0 tests=ALL_TRUSTED,RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 21 Oct 2011 18:34:53 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 3EEEE315AD5 for ; Fri, 21 Oct 2011 18:32:32 +0000 (UTC) Date: Fri, 21 Oct 2011 18:32:32 +0000 (UTC) From: "Kathey Marsden (Commented) (JIRA)" To: derby-dev@db.apache.org Message-ID: <1082380340.2345.1319221952259.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <1624219376.13293.1317057326340.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Commented] (DERBY-5430) Embedded nstest shows ERROR 40001: A lock could not be obtained due to a deadlock, in nstest MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/DERBY-5430?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13132905#comment-13132905 ] Kathey Marsden commented on DERBY-5430: --------------------------------------- I think I lost track. I had thought the deadlock reported in this issue (as well as the NPE DERBY-5422) had been resolved in 10.8 by backing out DERBY-4437 and then a different pre-existing deadlock showed in the test. > Embedded nstest shows ERROR 40001: A lock could not be obtained due to a deadlock, in nstest > --------------------------------------------------------------------------------------------- > > Key: DERBY-5430 > URL: https://issues.apache.org/jira/browse/DERBY-5430 > Project: Derby > Issue Type: Bug > Affects Versions: 10.8.2.1 > Environment: Windows XP, Suse Linux, NsTest Embedded, ibm 1.6 SR9 FP1. > Reporter: Myrna van Lunteren > > When running the nstest system test with Embedded with the 10.8.2.1 release candidate, or a build sync-ed to the top of the 10.8 tree (at level: version: 10.8.2.2 - (1174879M) - the M is to add checks (only do if not null) to number of PreparedStatement.close() calls), I now see a number of deadlock errors if I capture the output to a file. > The test run with network server did not show this problem. > 10.7.1.1 and 10.8.1.2 did not show this problem. > There's nothing in derby.log, but this is an example of the error to the console as captured in a file: > Thread 37 is now running > ==========> Tester2Thread 37 THREAD starting <====== > Tester2Thread 37 is getting a connection to the database... > -->Thread Tester2Thread 37 starting with url jdbc:derby:nstestdb;create=true;boo > tPassword=12345678 <-- > Connection number: 44 > Tester2Thread 37 dbutil.pick_one() -> Obtained row from the table 35979 > Tester2Thread 37 attempting to delete a row with serialkey = 35979 > Tester2Thread 37 deleted row with serialkey 35979 *** SUCCESS *** > Tester2Thread 37 dbutil.pick_one() -> Obtained row from the table 35978 > java.sql.SQLTransactionRollbackException: A lock could not be obtained due to a > deadlock, cycle of locks and waiters is: > Lock : ROW, SYSCOLUMNS, (5,16) > Waiting XID : {1174407, S} , NSTEST, insert into nstesttab (id, t_char, t_dat > e, t_decimal, t_decimal_nn, t_double, t_float, t_int, t_longint, t_numeric_larg > e, t_real, t_smallint, t_time, t_timestamp, t_varchar,t_clob,t_blob) values ( ?, > ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,cast('00000000000000000000000000000000 > 031' as clob(1K)),cast(X'0000000000000000000000000000000000000000000000000000000 > 00000000000000000000000000000000000000000000000000000000000000000000000000000000 > 000000000000000000000000000000000000000000000000000000031' as blob(10K))) > Granted XID : {61356, S} , {75588, S} , {147655, S} , {204335, S} , {460963, S > } , {511711, S} , {565264, S} , {727656, S} , {791364, S} , {1133117, S} > Lock : ROW, SYSCOLUMNS, (5,16) > Waiting XID : {1133117, X} , NSTEST, insert into nstesttab (id, t_char, t_dat > e, t_decimal, t_decimal_nn, t_double, t_float, t_int, t_longint, t_numeric_larg > e, t_real, t_smallint, t_time, t_timestamp, t_varchar,t_clob,t_blob) values ( ?, > ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,cast('00000000000000000000000000000000 > 031' as clob(1K)),cast(X'0000000000000000000000000000000000000000000000000000000 > 00000000000000000000000000000000000000000000000000000000000000000000000000000000 > 000000000000000000000000000000000000000000000000000000031' as blob(10K))) > Lock : ROW, SYSCOLUMNS, (5,16) > Waiting XID : {147655, X} , NSTEST, insert into nstesttab (id, t_char, t_date > , t_decimal, t_decimal_nn, t_double, t_float, t_int, t_longint, t_numeric_large > , t_real, t_smallint, t_time, t_timestamp, t_varchar,t_clob,t_blob) values ( ?, > ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,cast('000000000000000000000000000000000 > 31' as clob(1K)),cast(X'00000000000000000000000000000000000000000000000000000000 > 00000000000000000000000000000000000000000000000000000000000000000000000000000000 > 00000000000000000000000000000000000000000000000000000031' as blob(10K))) > Lock : ROW, SYSCOLUMNS, (5,16) > Waiting XID : {61356, X} , NSTEST, insert into nstesttab (id, t_char, t_date, > t_decimal, t_decimal_nn, t_double, t_float, t_int, t_longint, t_numeric_large, > t_real, t_smallint, t_time, t_timestamp, t_varchar,t_clob,t_blob) values ( ?, ? > , ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,cast('0000000000000000000000000000000003 > 1' as clob(1K)),cast(X'000000000000000000000000000000000000000000000000000000000 > 00000000000000000000000000000000000000000000000000000000000000000000000000000000 > 0000000000000000000000000000000000000000000000000000031' as blob(10K))) > . The selected victim is XID : 1174407. > at org.apache.derby.impl.jdbc.SQLExceptionFactory40.getSQLException(Unkn > own Source) > at org.apache.derby.impl.jdbc.Util.generateCsSQLException(Unknown Source > ) > at org.apache.derby.impl.jdbc.TransactionResourceImpl.wrapInSQLException > (Unknown Source) > at org.apache.derby.impl.jdbc.TransactionResourceImpl.handleException(Un > known Source) > at org.apache.derby.impl.jdbc.EmbedConnection.handleException(Unknown So > urce) > at org.apache.derby.impl.jdbc.ConnectionChild.handleException(Unknown So > urce) > at org.apache.derby.impl.jdbc.EmbedStatement.executeStatement(Unknown So > urce) > at org.apache.derby.impl.jdbc.EmbedPreparedStatement.executeStatement(Un > known Source) > at org.apache.derby.impl.jdbc.EmbedPreparedStatement.executeUpdate(Unkno > wn Source) > at org.apache.derbyTesting.system.nstest.utils.DbUtil.add_one_row(DbUtil > .java:201) > at org.apache.derbyTesting.system.nstest.tester.TesterObject.doIUDOperat > ion(TesterObject.java:148) > at org.apache.derbyTesting.system.nstest.tester.Tester1.startTesting(Tes > ter1.java:118) > at org.apache.derbyTesting.system.nstest.NsTest.run(NsTest.java:551) > Caused by: java.sql.SQLException: A lock could not be obtained due to a deadlock > , cycle of locks and waiters is: > Lock : ROW, SYSCOLUMNS, (5,16) > Waiting XID : {1174407, S} , NSTEST, insert into nstesttab (id, t_char, t_dat > e, t_decimal, t_decimal_nn, t_double, t_float, t_int, t_longint, t_numeric_larg > e, t_real, t_smallint, t_time, t_timestamp, t_varchar,t_clob,t_blob) values ( ?, > ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,cast('00000000000000000000000000000000 > 031' as clob(1K)),cast(X'0000000000000000000000000000000000000000000000000000000 > 00000000000000000000000000000000000000000000000000000000000000000000000000000000 > 000000000000000000000000000000000000000000000000000000031' as blob(10K))) > Granted XID : {61356, S} , {75588, S} , {147655, S} , {204335, S} , {460963, S > } , {511711, S} , {565264, S} , {727656, S} , {791364, S} , {1133117, S} > Lock : ROW, SYSCOLUMNS, (5,16) > Waiting XID : {1133117, X} , NSTEST, insert into nstesttab (id, t_char, t_dat > e, t_decimal, t_decimal_nn, t_double, t_float, t_int, t_longint, t_numeric_larg > e, t_real, t_smallint, t_time, t_timestamp, t_varchar,t_clob,t_blob) values ( ?, > ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,cast('00000000000000000000000000000000 > 031' as clob(1K)),cast(X'0000000000000000000000000000000000000000000000000000000 > 00000000000000000000000000000000000000000000000000000000000000000000000000000000 > 000000000000000000000000000000000000000000000000000000031' as blob(10K))) > Lock : ROW, SYSCOLUMNS, (5,16) > Waiting XID : {147655, X} , NSTEST, insert into nstesttab (id, t_char, t_date > , t_decimal, t_decimal_nn, t_double, t_float, t_int, t_longint, t_numeric_large > , t_real, t_smallint, t_time, t_timestamp, t_varchar,t_clob,t_blob) values ( ?, > ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,cast('000000000000000000000000000000000 > 31' as clob(1K)),cast(X'00000000000000000000000000000000000000000000000000000000 > 00000000000000000000000000000000000000000000000000000000000000000000000000000000 > 00000000000000000000000000000000000000000000000000000031' as blob(10K))) > Lock : ROW, SYSCOLUMNS, (5,16) > Waiting XID : {61356, X} , NSTEST, insert into nstesttab (id, t_char, t_date, > t_decimal, t_decimal_nn, t_double, t_float, t_int, t_longint, t_numeric_large, > t_real, t_smallint, t_time, t_timestamp, t_varchar,t_clob,t_blob) values ( ?, ? > , ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?,cast('0000000000000000000000000000000003 > 1' as clob(1K)),cast(X'000000000000000000000000000000000000000000000000000000000 > 00000000000000000000000000000000000000000000000000000000000000000000000000000000 > 0000000000000000000000000000000000000000000000000000031' as blob(10K))) > . The selected victim is XID : 1174407. > at org.apache.derby.impl.jdbc.SQLExceptionFactory.getSQLException(Unknow > n Source) > at org.apache.derby.impl.jdbc.SQLExceptionFactory40.wrapArgsForTransport > AcrossDRDA(Unknown Source) > ... 13 more -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira