issue_owner_repo
listlengths
2
2
issue_body
stringlengths
0
261k
issue_title
stringlengths
1
925
issue_comments_url
stringlengths
56
81
issue_comments_count
int64
0
2.5k
issue_created_at
stringlengths
20
20
issue_updated_at
stringlengths
20
20
issue_html_url
stringlengths
37
62
issue_github_id
int64
387k
2.46B
issue_number
int64
1
127k
[ "MonetDB", "MonetDB" ]
Date: 2012-12-17 22:53:48 +0100 From: Percy Wegmann &lt;<percy>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.5 (Oct2012-SP1) CC: @njnes Last updated: 2014-02-20 15:03:01 +0100 ## Comment 18258 Date: 2012-12-17 22:53:48 +0100 From: Percy Wegmann &lt;<percy>&gt; User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_5) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.97 Safari/537.11 Build Identifier: When loading two tables concurrently and at the same time running a COUNT(*) query against one of those tables, one occasionally gets a COMMIT: failed message. The strange thing is that this requires this exact scenario. Concurrent loads into two tables work fine. Concurrent loads while running another aggregate query (like AVG(*)) work fine. Concurrent loads while running a non-aggregate query work fine. I'm able to reproduce this using the JDBC client with multiple threads. Note - I'm only able to reproduce the problem when using prepared statements with batching. Non-batched inserts don't seem to suffer from this problem. I haven't had a chance to dig into it yet, but is it possible that COUNT(*) may be using some cached counts from a system table somewhere, and that both the act of querying for COUNT(*) and INSERTING may side-effect that table and create a concurrency problem? Reproducible: Always ### Steps to Reproduce: I'll attach a JUnit test for this. ### Actual Results: INSERT fails with COMMIT: failed ### Expected Results: All INSERTs succeed. This is problematic for my app as we are continuously loading multiple tables at the same time as users are interactively querying the database, including asking for COUNT(*). ## Comment 18259 Date: 2012-12-17 23:01:44 +0100 From: Percy Wegmann &lt;<percy>&gt; Created attachment 165 JUnit test case for reproducing problem One or the other of these tests fails fairly reliably: testConcurrentLoadsWithCountQuery testConcurrentLoadsWithCountQueryAgain None of the other tests ever fail. Note - this test expects a database on server percy-sandbox named ctest with user/pass monetdb/monetdb. You can edit these values on line 368. > Attached file: [MultiThreadedMonetTest.java](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3210_MultiThreadedMonetTest.java_165) (text/java, 12611 bytes) > Description: JUnit test case for reproducing problem ## Comment 18262 Date: 2012-12-18 21:00:41 +0100 From: Percy Wegmann &lt;<percy>&gt; So, we're getting a commit failure at line 2810 of store.c (inside the validate_tables() function). /* commited write before t's read */ if (c->base.rtime && c->base.rtime < oc->base.wtime) { ## Comment 18264 Date: 2012-12-18 21:25:54 +0100 From: @njnes is the count statement failing with this commit message? ## Comment 18265 Date: 2012-12-18 21:41:55 +0100 From: Percy Wegmann &lt;<percy>&gt; Created attachment 166 Test that shows using setAutoCommit(false) and rolling back the transaction works > Attached file: [MultiThreadedMonetTest.java](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3210_MultiThreadedMonetTest.java_166) (text/java, 6673 bytes) > Description: Test that shows using setAutoCommit(false) and rolling back the transaction works ## Comment 18266 Date: 2012-12-18 21:44:48 +0100 From: Percy Wegmann &lt;<percy>&gt; Niels - it's actually the INSERT statement that's failing on that line. I added some logging and found that the check is failing on column "id" on "table_a". The question is, why would a SELECT be updating the wtime on a column? ## Comment 18315 Date: 2012-12-29 19:14:26 +0100 From: Percy Wegmann &lt;<percy>&gt; I've done a little more digging, and it appears that simply preparing a SELECT query (not even executing it) causes this problem. ## Comment 18337 Date: 2013-01-15 18:47:23 +0100 From: @njnes did you try SP3? ## Comment 18357 Date: 2013-01-21 22:18:11 +0100 From: Percy Wegmann &lt;<percy>&gt; I just tried it with SP3 (11.13.9) on Ubuntu 12 64-bit, and I'm still getting a commit failure. (In reply to comment 7) > did you try SP3? ## Comment 18470 Date: 2013-02-13 13:44:36 +0100 From: @njnes this has been fixed in both the Oct2012 and Feb2013 branches. The Feb2013 is about to be released, ie closing with nextfeaturerelease ## Comment 19618 Date: 2014-02-20 15:03:01 +0100 From: @sjoerdmullender Jan2014 has been released.
Unexpected concurrency conflict when inserting to 2 tables simultaneously and querying one of them
https://api.github.com/repos/MonetDB/MonetDB/issues/3210/comments
0
2020-11-30T12:16:15Z
2024-06-27T11:58:34Z
https://github.com/MonetDB/MonetDB/issues/3210
753,429,443
3,210
[ "MonetDB", "MonetDB" ]
Date: 2012-12-14 16:43:57 +0100 From: @yzchang To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.5 (Oct2012-SP1) CC: @njnes Last updated: 2013-01-22 09:29:10 +0100 ## Comment 18252 Date: 2012-12-14 16:43:57 +0100 From: @yzchang The minimal query to trigger this assertion is: create table t (id int, x int, y int); select * from t as t1, t as t2 where power((t1.x - t2.x),2) < power((t1.y - t2.y),2); The assertion is triggered by the WHERE condition. The problem seems to start in rel_bin.c:554, where 't1.x' is supposed to be found, but it isn't. All subsequent exp_bin returns NULL. ## Comment 18254 Date: 2012-12-15 12:02:25 +0100 From: @yzchang Changeset [93cabca63147](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=93cabca63147) made by Jennie Zhang <y.zhang@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=93cabca63147](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=93cabca63147) Changeset description: Added test for Bug #3209 ## Comment 18255 Date: 2012-12-15 12:29:38 +0100 From: @njnes Changeset [8650dce52dd8](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=8650dce52dd8) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=8650dce52dd8](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=8650dce52dd8) Changeset description: fixed bug #3209, ie first crossproduct if the join expression consists of functions (these should have been pushed down, whenever possible). ## Comment 18256 Date: 2012-12-15 12:33:50 +0100 From: @njnes fixed by first doing a crossproduct, when the join expression has functions ## Comment 18257 Date: 2012-12-15 14:08:52 +0100 From: @njnes Changeset [2f659fd4dff9](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=2f659fd4dff9) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=2f659fd4dff9](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=2f659fd4dff9) Changeset description: fix for bug #3209 ## Comment 18260 Date: 2012-12-17 23:24:38 +0100 From: @njnes Changeset [4bbf60a4e03a](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=4bbf60a4e03a) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=4bbf60a4e03a](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=4bbf60a4e03a) Changeset description: missing part of fix for bug #3209 (no propagation need, is allready in Feb2013 and up) ## Comment 18368 Date: 2013-01-22 09:29:10 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
exp_bin: Assertion `0' failed
https://api.github.com/repos/MonetDB/MonetDB/issues/3209/comments
0
2020-11-30T12:16:13Z
2024-06-27T11:58:33Z
https://github.com/MonetDB/MonetDB/issues/3209
753,429,407
3,209
[ "MonetDB", "MonetDB" ]
Date: 2012-12-14 13:23:32 +0100 From: Percy Wegmann &lt;<percy>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.5 (Oct2012-SP1) CC: @njnes Last updated: 2013-01-22 09:29:04 +0100 ## Comment 18249 Date: 2012-12-14 13:23:32 +0100 From: Percy Wegmann &lt;<percy>&gt; When executing a prepared statement with a high number of columns, some arguments are not recognized and I'm given an error of the form: wrong number of arguments for prepared statement: 120, expected 147 I first saw this while using the JDBC API, but I see it from the mclient as well. At first I thought 120 was a magic number, but when I constructed a test scenario to reproduce, the error changed a little: wrong number of arguments for prepared statement: 100, expected 150 So, I guess it's not always the same cutoff point. ## Comment 18250 Date: 2012-12-14 13:24:31 +0100 From: Percy Wegmann &lt;<percy>&gt; Here is an MClient session for reproducing the issue. sql>CREATE TABLE wide("1" VARCHAR(255), "2" VARCHAR(255), "3" VARCHAR(255), "4" VARCHAR(255), "5" VARCHAR(255), "6" VARCHAR(255), "7" VARCHAR(255), "8" VARCHAR(255), "9" VARCHAR(255), "10" VARCHAR(255), "11" VARCHAR(255), "12" VARCHAR(255), "13" VARCHAR(255), "14" VARCHAR(255), "15" VARCHAR(255), "16" VARCHAR(255), "17" VARCHAR(255), "18" VARCHAR(255), "19" VARCHAR(255), "20" VARCHAR(255), "21" VARCHAR(255), "22" VARCHAR(255), "23" VARCHAR(255), "24" VARCHAR(255), "25" VARCHAR(255), "26" VARCHAR(255), "27" VARCHAR(255), "28" VARCHAR(255), "29" VARCHAR(255), "30" VARCHAR(255), "31" VARCHAR(255), "32" VARCHAR(255), "33" VARCHAR(255), "34" VARCHAR(255), "35" VARCHAR(255), "36" VARCHAR(255), "37" VARCHAR(255), "38" VARCHAR(255), "39" VARCHAR(255), "40" VARCHAR(255), "41" VARCHAR(255), "42" VARCHAR(255), "43" VARCHAR(255), "44" VARCHAR(255), "45" VARCHAR(255), "46" VARCHAR(255), "47" VARCHAR(255), "48" VARCHAR(255), "49" VARCHAR(255), "50" VARCHAR(255), "51" VARCHAR(255), "52" VARCHAR(255), "53" VARCHAR(255), "54" VARCHAR(255), "55" VARCHAR(255), "56" VARCHAR(255), "57" VARCHAR(255), "58" VARCHAR(255), "59" VARCHAR(255), "60" VARCHAR(255), "61" VARCHAR(255), "62" VARCHAR(255), "63" VARCHAR(255), "64" VARCHAR(255), "65" VARCHAR(255), "66" VARCHAR(255), "67" VARCHAR(255), "68" VARCHAR(255), "69" VARCHAR(255), "70" VARCHAR(255), "71" VARCHAR(255), "72" VARCHAR(255), "73" VARCHAR(255), "74" VARCHAR(255), "75" VARCHAR(255), "76" VARCHAR(255), "77" VARCHAR(255), "78" VARCHAR(255), "79" VARCHAR(255), "80" VARCHAR(255), "81" VARCHAR(255), "82" VARCHAR(255), "83" VARCHAR(255), "84" VARCHAR(255), "85" VARCHAR(255), "86" VARCHAR(255), "87" VARCHAR(255), "88" VARCHAR(255), "89" VARCHAR(255), "90" VARCHAR(255), "91" VARCHAR(255), "92" VARCHAR(255), "93" VARCHAR(255), "94" VARCHAR(255), "95" VARCHAR(255), "96" VARCHAR(255), "97" VARCHAR(255), "98" VARCHAR(255), "99" VARCHAR(255), "100" VARCHAR(255), "101" VARCHAR(255), "102" VARCHAR(255), "103" VARCHAR(255), "104" VARCHAR(255), "105" VARCHAR(255), "106" VARCHAR(255), "107" VARCHAR(255), "108" VARCHAR(255), "109" VARCHAR(255), "110" VARCHAR(255), "111" VARCHAR(255), "112" VARCHAR(255), "113" VARCHAR(255), "114" VARCHAR(255), "115" VARCHAR(255), "116" VARCHAR(255), "117" VARCHAR(255), "118" VARCHAR(255), "119" VARCHAR(255), "120" VARCHAR(255), "121" VARCHAR(255), "122" VARCHAR(255), "123" VARCHAR(255), "124" VARCHAR(255), "125" VARCHAR(255), "126" VARCHAR(255), "127" VARCHAR(255), "128" VARCHAR(255), "129" VARCHAR(255), "130" VARCHAR(255), "131" VARCHAR(255), "132" VARCHAR(255), "133" VARCHAR(255), "134" VARCHAR(255), "135" VARCHAR(255), "136" VARCHAR(255), "137" VARCHAR(255), "138" VARCHAR(255), "139" VARCHAR(255), "140" VARCHAR(255), "141" VARCHAR(255), "142" VARCHAR(255), "143" VARCHAR(255), "144" VARCHAR(255), "145" VARCHAR(255), "146" VARCHAR(255), "147" VARCHAR(255), "148" VARCHAR(255), "149" VARCHAR(255), "150" VARCHAR(255)); operation successful (96.567ms) sql>PREPARE INSERT INTO wide("1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21", "22", "23", "24", "25", "26", "27", "28", "29", "30", "31", "32", "33", "34", "35", "36", "37", "38", "39", "40", "41", "42", "43", "44", "45", "46", "47", "48", "49", "50", "51", "52", "53", "54", "55", "56", "57", "58", "59", "60", "61", "62", "63", "64", "65", "66", "67", "68", "69", "70", "71", "72", "73", "74", "75", "76", "77", "78", "79", "80", "81", "82", "83", "84", "85", "86", "87", "88", "89", "90", "91", "92", "93", "94", "95", "96", "97", "98", "99", "100", "101", "102", "103", "104", "105", "106", "107", "108", "109", "110", "111", "112", "113", "114", "115", "116", "117", "118", "119", "120", "121", "122", "123", "124", "125", "126", "127", "128", "129", "130", "131", "132", "133", "134", "135", "136", "137", "138", "139", "140", "141", "142", "143", "144", "145", "146", "147", "148", "149", "150") more>VALUES(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?); execute prepared statement using: EXEC 1(...) +---------+--------+-------+--------+-------+--------+ | type | digits | scale | schema | table | column | +=========+========+=======+========+=======+========+ | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | +---------+--------+-------+--------+-------+--------+ 150 tuples (4.084ms) sql> sql>EXEC 1('', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', ''); EXEC: wrong number of arguments for prepared statement: 100, expected 150 sql> -- I then tried the same query without the explicit columns, but got the same error sql>PREPARE INSERT INTO WIDE VALUES(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?); execute prepared statement using: EXEC 2(...) +---------+--------+-------+--------+-------+--------+ | type | digits | scale | schema | table | column | +=========+========+=======+========+=======+========+ | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | | varchar | 255 | 0 | null | null | null | +---------+--------+-------+--------+-------+--------+ 150 tuples (4.147ms) sql>EXEC 2('', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', ''); EXEC: wrong number of arguments for prepared statement: 100, expected 150 -- Doing it as an insert without first preparing it works sql>INSERT INTO wide("1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12", "13", "14", "15", "16", "17", "18", "19", "20", "21", "22", "23", "24", "25", "26", "27", "28", "29", "30", "31", "32", "33", "34", "35", "36", "37", "38", "39", "40", "41", "42", "43", "44", "45", "46", "47", "48", "49", "50", "51", "52", "53", "54", "55", "56", "57", "58", "59", "60", "61", "62", "63", "64", "65", "66", "67", "68", "69", "70", "71", "72", "73", "74", "75", "76", "77", "78", "79", "80", "81", "82", "83", "84", "85", "86", "87", "88", "89", "90", "91", "92", "93", "94", "95", "96", "97", "98", "99", "100", "101", "102", "103", "104", "105", "106", "107", "108", "109", "110", "111", "112", "113", "114", "115", "116", "117", "118", "119", "120", "121", "122", "123", "124", "125", "126", "127", "128", "129", "130", "131", "132", "133", "134", "135", "136", "137", "138", "139", "140", "141", "142", "143", "144", "145", "146", "147", "148", "149", "150") VALUES ('', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', '', ''); 1 affected row (45.940ms) ## Comment 18251 Date: 2012-12-14 15:09:31 +0100 From: Percy Wegmann &lt;<percy>&gt; Interestingly enough, if I insert NULLs rather than empty strings, the query succeeds. This led me to sql/server/sql_parser.y line 3755: if (m->emode == m_normal && m->caching && m->argc < 100) { If I change the 100 to 10000, that solves my problem. The reason that the cutoff didn't always look like 100 is that NULLs are accepted happily by the parser, just not atoms. The question now is, was there a reason for the argc < 100 condition? ## Comment 18253 Date: 2012-12-14 18:10:41 +0100 From: @njnes Changeset [013de2efeb3c](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=013de2efeb3c) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=013de2efeb3c](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=013de2efeb3c) Changeset description: added test for bug #3208 fixed problem with maximun number of prepare arguments. Limit is no longer needed. ## Comment 18359 Date: 2013-01-22 09:29:04 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
Unable to execute prepared statements with a large number of arguments
https://api.github.com/repos/MonetDB/MonetDB/issues/3208/comments
0
2020-11-30T12:16:10Z
2024-06-27T11:58:32Z
https://github.com/MonetDB/MonetDB/issues/3208
753,429,372
3,208
[ "MonetDB", "MonetDB" ]
Date: 2012-12-11 09:29:46 +0100 From: @grobian To: clients devs &lt;<bugs-clients>&gt; Version: 11.13.5 (Oct2012-SP1) Last updated: 2012-12-11 16:55:37 +0100 ## Comment 18245 Date: 2012-12-11 09:29:46 +0100 From: @grobian On the Ubuntu testing machine: monet@hamer:~/testing/GNU-Ubuntu-i386-propcheck-d40b1be57b1e-Oct2012/install$ la lib/python2.7/ dist-packages site-packages monet@hamer:~/testing/GNU-Ubuntu-i386-propcheck-d40b1be57b1e-Oct2012/install$ la lib/python2.7/dist-packages/ MonetDBtesting monet@hamer:~/testing/GNU-Ubuntu-i386-propcheck-d40b1be57b1e-Oct2012/install$ la lib/python2.7/site-packages/ monetdb python_monetdb-11.13.6-py2.7.egg-info 1) MonetDBtesting is installed in dist-packages, but should be in site-packages, like on other platforms 2) PYTHONX_LIBDIR point to dist-packages, not site-packages (most likely the cause for 1) ) Because the Python dbapi is installed with setup.py, it ends up in the correct location, regardless what configure probed. Therefore, Mtest assembles an incorrect PYTHONXPATH path. Mtest contains hardwired hacks for Ubuntu to replace dist-packages with site-packages from distutils.sysconfig.get_python_lib(0, 0 '') to build its own PYTHONPATH. Most likely Mtest should take the configure probed paths here. ## Comment 18246 Date: 2012-12-11 09:39:33 +0100 From: @grobian Ubuntu modified distutils.sysconfig as follows: if standard_lib: return libpython + elif is_default_prefix and 'PYTHONUSERBASE' not in os.environ and 'real_prefix' not in sys.__dict__: + return os.path.join(libpython, "dist-packages") else: return os.path.join(libpython, "site-packages") This means on Ubuntu distutils.sysconfig.get_python_lib(0, 0, '') will return dist-packages, iso site-packages as with vanilla python. However, if we give get_python_lib the prefix we're installing for: >>> distutils.sysconfig.get_python_lib(0,0,'/usr/local/whatever') '/usr/local/whatever/lib/python2.7/site-packages' Ubuntu returns the site-packges, like other platforms would also do, e.g.: % python Python 3.3.0 (default, Dec 10 2012, 16:16:18) [GCC 4.6.3] on linux Type "help", "copyright", "credits" or "license" for more information. >>> import distutils.sysconfig >>> distutils.sysconfig.get_python_lib(0, 0, '/usr/local/whatever') '/usr/local/whatever/lib/python3.3/site-packages' >>> ## Comment 18247 Date: 2012-12-11 10:37:47 +0100 From: @grobian I suggest this patch (which works for me), either to be committed to Oct2012 after Sjoerd finishes building the release, or on Feb2013: HG changeset patch User Fabian Groffen <fabian@monetdb.org> Date 1355218583 -3600 Branch Oct2012 Node ID 9d0c14ef71255e1f3ed088a31e11c76dc10ffc6a Parent [22634fc2c6b9cbe197c68e3ee1553b264cfb2c99](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=22634fc2c6b9cbe197c68e3ee1553b264cfb2c99) python: fix PYTHONX_LIBDIR values, bug #3207 diff -r [22634fc2c6b9](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=22634fc2c6b9) -r 9d0c14ef7125 configure.ag --- a/configure.ag Tue Dec 11 09:42:06 2012 +0100 +++ b/configure.ag Tue Dec 11 10:36:23 2012 +0100 @@ -1167,10 +1167,15 @@ if test "x$have_python2" != xno; then fi case "$host_os-`"$PYTHON2" -V 2>&1`" in darwin9*-*2.5.1) - PYTHON2_LIBDIR="`"$PYTHON2" -c 'import distutils.sysconfig; print distutils.sysconfig.get_python_lib(0,1,"")' 2>/dev/null`/site-packages";; + This is the Python installed on OSX Leopard, in + later versions of OSX, Python is fixed to return + standard output + PYTHON2_LIBDIR="`"$PYTHON2" -c 'import distutils.sysconfig; print distutils.sysconfig.get_python_lib(0,1,"'"$Qprefix"'")' 2>/dev/null`/site-packages";; *) - PYTHON2_LIBDIR="`"$PYTHON2" -c 'import distutils.sysconfig; print distutils.sysconfig.get_python_lib(0,0,"")' 2>/dev/null`";; + Use prefix field for Ubuntu Python, bug #3207 + PYTHON2_LIBDIR="`"$PYTHON2" -c 'import distutils.sysconfig; print distutils.sysconfig.get_python_lib(0,0,"'"$Qprefix"'")' 2>/dev/null`";; esac + PYTHON2_LIBDIR=`echo "$PYTHON2_LIBDIR" | sed "s|^$Qprefix/||"` ;; no) ;; $Qprefix/*) dnl dubious @@ -1235,7 +1240,9 @@ if test "x$have_python3" != xno; then if test x$cross_compiling = xyes; then AC_MSG_ERROR([Must specify --with-python3-libdir when cross compiling]) fi - PYTHON3_LIBDIR="`"$PYTHON3" -c 'import distutils.sysconfig; print(distutils.sysconfig.get_python_lib(0,0,""))' 2>/dev/null`" + Use prefix field for Ubuntu Python, bug #3207 + PYTHON3_LIBDIR="`"$PYTHON3" -c 'import distutils.sysconfig; print(distutils.sysconfig.get_python_lib(0,0,"'"$Qprefix"'"))' 2>/dev/null`" + PYTHON3_LIBDIR=`echo "$PYTHON3_LIBDIR" | sed "s|^$Qprefix/||"` ;; no) ;; $Qprefix/*) dnl dubious diff -r [22634fc2c6b9](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=22634fc2c6b9) -r 9d0c14ef7125 testing/Mtest.py.in --- a/testing/Mtest.py.in Tue Dec 11 09:42:06 2012 +0100 +++ b/testing/Mtest.py.in Tue Dec 11 10:36:23 2012 +0100 @@ -144,21 +144,7 @@ except ImportError: try: import MonetDBtesting.subprocess26 as subprocess except ImportError: - import distutils.sysconfig - if os.name != "nt" and os.uname()[0] + os.uname()[2][:1] == "Darwin9" and sys.version[:5] == "2.5.1": - p = _configure(os.path.join('@QXprefix@',distutils.sysconfig.get_python_lib(0,1,""),'site-packages')) - else: - p = distutils.sysconfig.get_python_lib(0, 0, '') - if p.endswith('dist-packages'): - Ubuntu - p = p.replace('dist-packages', 'site-packages') - _configure(os.path.join('@QXprefix@', p)) - sys.path.insert(0, p) - if os.environ.has_key('PYTHONPATH'): - p += os.pathsep + os.environ['PYTHONPATH'] - os.environ['PYTHONPATH'] = p - p = distutils.sysconfig.get_python_lib(0, 0, '') - p = _configure(os.path.join('@QXprefix@', p)) + p = _configure(os.path.join('@QXprefix@', '@PYTHON2_LIBDIR@')) sys.path.insert(0, p) import MonetDBtesting.subprocess26 as subprocess if os.environ.has_key('PYTHONPATH'): @@ -254,11 +240,7 @@ except ImportError: try: from MonetDBtesting import monet_options except ImportError: - import distutils.sysconfig - if os.name != "nt" and os.uname()[0] + os.uname()[2][:1] == "Darwin9" and sys.version[:5] == "2.5.1": - p = _configure(os.path.join('@QXprefix@',distutils.sysconfig.get_python_lib(0,1,""),'site-packages')) - else: - p = _configure(os.path.join('@QXprefix@',distutils.sysconfig.get_python_lib(0,0,""))) + p = _configure(os.path.join('@QXprefix@', '@PYTHON2_LIBDIR@')) sys.path.insert(0, p) from MonetDBtesting import monet_options if os.environ.has_key('PYTHONPATH'): ## Comment 18248 Date: 2012-12-11 16:53:53 +0100 From: @grobian Changeset [a1826ecde882](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=a1826ecde882) made by Fabian Groffen <fabian@monetdb.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=a1826ecde882](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=a1826ecde882) Changeset description: python: fix PYTHONX_LIBDIR values, bug #3207
Python installation directory mismatch on Ubuntu (PYTHONX_LIBDIR is wrong)
https://api.github.com/repos/MonetDB/MonetDB/issues/3207/comments
0
2020-11-30T12:16:07Z
2024-06-27T11:58:31Z
https://github.com/MonetDB/MonetDB/issues/3207
753,429,326
3,207
[ "MonetDB", "MonetDB" ]
Date: 2012-12-07 13:48:29 +0100 From: @grobian To: MonetDB5 devs &lt;<bugs-monetdb5>&gt; Version: 11.15.1 (Feb2013) CC: duc Last updated: 2013-01-29 10:48:58 +0100 ## Comment 18241 Date: 2012-12-07 13:48:29 +0100 From: @grobian ever since the lordf branch was merged (45693:146b0a7a1b66) modules/mal/tokenizer00 fails. See: http://monetdb.cwi.nl/testweb/web/testchange.php?test=46060%3A14b654bc168e%2FGNU-Darwin-i386-propcheck%2Fmonetdb5%2FmTests%2Fmodules%2Fmal%2Ftokenizer00&submit=update and http://monetdb.cwi.nl/testweb/web/showtestoutput.php?serial=46231:6df1de2f1ecd&target=GNU-Darwin-i386-propcheck&module=monetdb5&test=modules%2Fmal%2Ftokenizer00&which=out ## Comment 18244 Date: 2012-12-10 14:58:41 +0100 From: @lsidir Changeset [801a4ecc0819](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=801a4ecc0819) made by lsidir <lsidir@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=801a4ecc0819](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=801a4ecc0819) Changeset description: Fix for Bug #3206. Tokenizer should not wrap ourput strings to language specific syntax sych as <../>. ## Comment 18445 Date: 2013-01-29 10:48:58 +0100 From: @sjoerdmullender Seems to be fixed.
modules/mal/tokenizer00 fails since 45693:146b0a7a1b66
https://api.github.com/repos/MonetDB/MonetDB/issues/3206/comments
0
2020-11-30T12:16:05Z
2024-06-27T11:58:31Z
https://github.com/MonetDB/MonetDB/issues/3206
753,429,300
3,206
[ "MonetDB", "MonetDB" ]
Date: 2012-12-04 22:00:36 +0100 From: Percy Wegmann &lt;<percy>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.3 (Oct2012) CC: @drstmane Last updated: 2013-01-22 09:29:05 +0100 ## Comment 18233 Date: 2012-12-04 22:00:36 +0100 From: Percy Wegmann &lt;<percy>&gt; User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_5) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.95 Safari/537.11 Build Identifier: When using parameters of type INET in SQL queries, the results of inserts and queries vary depending on which of the following syntaxes one uses: inet '127.0.0.1' cast('127.0.0.1' AS inet) '127.0.0.1' Reproducible: Always ### Steps to Reproduce: sql>create table test_table(col inet); operation successful (27.394ms) sql>insert into test_table values('127.0.0.1'); 1 affected row (20.370ms) sql>insert into test_table values(inet '127.0.0.1'); 1 affected row (19.654ms) sql>insert into test_table values(cast('127.0.0.1' as inet)); 1 affected row (25.038ms) sql>select count(*) from test_table where col = '127.0.0.1'; +------+ | L1 | +======+ | 3 | +------+ 1 tuple (1.547ms) sql>select count(*) from test_table where col = inet '127.0.0.1'; +------+ | L1 | +======+ | 0 | +------+ 1 tuple (0.946ms) sql>select count(*) from test_table where col = cast('127.0.0.1' as inet); +------+ | L1 | +======+ | 2 | +------+ 1 tuple (0.982ms) sql>select count(*) from test_table where col = inet '127.0.0.1'; +------+ | L1 | +======+ | 2 | +------+ 1 tuple (0.937ms) sql>select count(*) from test_table where col = inet '127.0.0.1'; +------+ | L1 | +======+ | 0 | +------+ 1 tuple (0.801ms) ### Actual Results: Queries return different counts depending on how INET value was bound to query. Particularly interesting is that the output when using the inet '127.0.0.1' syntax is non-deterministic. ### Expected Results: All queries return a count of 3 ## Comment 18234 Date: 2012-12-04 22:43:28 +0100 From: @drstmane With a slightly modified/extended test, I seems to get deterministic, though also incorrect / unexpected results: create table test_table(pos int, col inet); operation successful insert into test_table values(1, '127.0.0.1'); 1 affected row insert into test_table values(2, inet '127.0.0.1'); 1 affected row insert into test_table values(3, cast('127.0.0.1' as inet)); 1 affected row select * from test_table; +------+------------------------------------------------------+ | pos | col | +======+======================================================+ | 1 | 127.0.0.1 | | 2 | 127.0.0.1 | | 3 | 127.0.0.1 | +------+------------------------------------------------------+ 3 tuples select * from test_table where col = '127.0.0.1'; +------+------------------------------------------------------+ | pos | col | +======+======================================================+ | 1 | 127.0.0.1 | | 2 | 127.0.0.1 | | 3 | 127.0.0.1 | +------+------------------------------------------------------+ 3 tuples select * from test_table where col = inet '127.0.0.1'; +------+------------------------------------------------------+ | pos | col | +======+======================================================+ | 2 | 127.0.0.1 | +------+------------------------------------------------------+ 1 tuple select * from test_table where col = cast('127.0.0.1' as inet); +------+------------------------------------------------------+ | pos | col | +======+======================================================+ | 1 | 127.0.0.1 | | 3 | 127.0.0.1 | +------+------------------------------------------------------+ 2 tuples select * from test_table where col = inet '127.0.0.1'; +------+------------------------------------------------------+ | pos | col | +======+======================================================+ | 2 | 127.0.0.1 | +------+------------------------------------------------------+ 1 tuple select * from test_table where col = inet '127.0.0.1'; +------+------------------------------------------------------+ | pos | col | +======+======================================================+ | 2 | 127.0.0.1 | +------+------------------------------------------------------+ 1 tuple select * from test_table; +------+------------------------------------------------------+ | pos | col | +======+======================================================+ | 1 | 127.0.0.1 | | 2 | 127.0.0.1 | | 3 | 127.0.0.1 | +------+------------------------------------------------------+ 3 tuples ## Comment 18235 Date: 2012-12-05 08:40:06 +0100 From: @grobian I think the problem here is that the underlying datatype is a 64-bits integer (lng). It uses four bytes for the dotted quad (IPv4 address), and the rest for the subnet mask. If the subnetmask isn't given, it defaults to 32, which is also suppressed in the output if it is 32. It might be that a difference in the subnetmask is causing this "weird" output. ## Comment 18236 Date: 2012-12-05 10:39:19 +0100 From: @sjoerdmullender Changeset [0103f834b924](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=0103f834b924) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=0103f834b924](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=0103f834b924) Changeset description: Added test for bug #3205. ## Comment 18237 Date: 2012-12-05 10:56:54 +0100 From: @sjoerdmullender Changeset [d8ba0cdf945f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=d8ba0cdf945f) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=d8ba0cdf945f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=d8ba0cdf945f) Changeset description: Fully initialize inet structure. This fixes bug #3205. ## Comment 18238 Date: 2012-12-05 10:58:08 +0100 From: @sjoerdmullender It helps to fully initialize the structure. The bug seems to be fixed. ## Comment 18360 Date: 2013-01-22 09:29:05 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
Inet datatype handling inconsistent between int, cast( as inet) and string
https://api.github.com/repos/MonetDB/MonetDB/issues/3205/comments
0
2020-11-30T12:16:02Z
2024-06-27T11:58:30Z
https://github.com/MonetDB/MonetDB/issues/3205
753,429,266
3,205
[ "MonetDB", "MonetDB" ]
Date: 2012-12-03 14:32:58 +0100 From: @grobian To: Merovingian devs &lt;<bugs-merovingian>&gt; Version: 11.17.9 (Jan2014) Last updated: 2014-10-31 14:14:54 +0100 ## Comment 18232 Date: 2012-12-03 14:32:58 +0100 From: @grobian Instead of locking a database right after its creation, it would be more secure (and useful) if monetdb create had an option to set the admin (monetdb) password, such that the database can be really setup by the dba without anyone ever being able to access it using its default (monetdb/monetdb) credentials. ## Comment 20292 Date: 2014-10-15 10:02:21 +0200 From: @sjoerdmullender Implemented by Fabian. ## Comment 20396 Date: 2014-10-31 14:14:54 +0100 From: @sjoerdmullender Oct2014 has been released.
monetdb create: allow setting admin password during creation
https://api.github.com/repos/MonetDB/MonetDB/issues/3204/comments
0
2020-11-30T12:15:59Z
2024-06-27T11:58:29Z
https://github.com/MonetDB/MonetDB/issues/3204
753,429,235
3,204
[ "MonetDB", "MonetDB" ]
Date: 2012-12-03 14:26:19 +0100 From: @grobian To: Merovingian devs &lt;<bugs-merovingian>&gt; Version: -- development Last updated: 2016-04-11 11:44:08 +0200 ## Comment 18231 Date: 2012-12-03 14:26:19 +0100 From: @grobian Funnels should use credentials from the client, or have their own credential management.
allow to set user/password for funnel connections
https://api.github.com/repos/MonetDB/MonetDB/issues/3203/comments
0
2020-11-30T12:15:57Z
2024-06-28T13:40:09Z
https://github.com/MonetDB/MonetDB/issues/3203
753,429,204
3,203
[ "MonetDB", "MonetDB" ]
Date: 2012-12-01 00:33:25 +0100 From: @yzchang To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.5 (Oct2012-SP1) CC: @drstmane, @yzchang Last updated: 2014-07-03 17:36:33 +0200 ## Comment 18223 Date: 2012-12-01 00:33:25 +0100 From: @yzchang The following queries result in a bus error when adding the compound primary key: CREATE TABLE images_very_small (imageid INT, xstart INT, ystart INT, xend INT, yend INT, time INT, cyclem INT); CREATE TABLE images_pixels_very_small (imageid INT, tile INT, x INT, y INT, pix INT, var INT, valid INT, sat INT, v0 INT, v1 INT, v2 INT, v3 INT, v4 INT, v5 INT, v6 INT); COPY INTO images_very_small FROM '/ufs/zhang/papers/ssdb/monetdb/data/benchdata.very_small.pos' DELIMITERS ',','\n'; COPY 102400000 RECORDS INTO images_pixels_very_small FROM '/ufs/zhang/papers/ssdb/monetdb/data/benchdata.very_small' DELIMITERS ',','\n'; ALTER TABLE images_very_small ADD PRIMARY KEY (imageid); ALTER TABLE images_pixels_very_small ADD PRIMARY KEY (imageid, tile, x, y); ALTER TABLE images_pixels_very_small ADD FOREIGN KEY (imageid) REFERENCES images_very_small (imageid); Some GDB and mserver5 info: $ gdb --args /export/scratch2/zhang/monet-install/ssdb/debug/bin/mserver5 --set gdk_dbfarm=/var/tmp/dbfarm --dbname=ssdb --set mapi_open=true --set mapi_usock=/var/tmp/dbfarm/ssdb/.mapi.sock --set monet_vault_key=/var/tmp/dbfarm/ssdb/.vaultkey --set gdk_nr_threads=8 --set max_clients=64 --set sql_optimizer=default_pipe GNU gdb (GDB) Fedora (7.3.50.20110722-16.fc16) Copyright (C) 2011 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-redhat-linux-gnu". For bug reporting instructions, please see: <http://www.gnu.org/software/gdb/bugs/>... Reading symbols from /export/scratch2/zhang/monet-install/ssdb/debug/bin/mserver5...done. (gdb) r Starting program: /export/scratch2/zhang/monet-install/ssdb/debug/bin/mserver5 --set gdk_dbfarm=/var/tmp/dbfarm --dbname=ssdb --set mapi_open=true --set mapi_usock=/var/tmp/dbfarm/ssdb/.mapi.sock --set monet_vault_key=/var/tmp/dbfarm/ssdb/.vaultkey --set gdk_nr_threads=8 --set max_clients=64 --set sql_optimizer=default_pipe [Thread debugging using libthread_db enabled] Using host libthread_db library "/lib64/libthread_db.so.1". [New Thread 0x7fffeff0a700 (LWP 15170)] MonetDB 5 server v11.13.6 This is an unreleased version Serving database 'ssdb', using 8 threads Compiled for x86_64-unknown-linux-gnu/64bit with 64bit OIDs dynamically linked Found 15.629 GiB available main-memory. Copyright (c) 1993-July 2008 CWI. Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved Visit http://www.monetdb.org/ for further information [New Thread 0x7fffee06b700 (LWP 15171)] Listening for connection requests on mapi:monetdb://riga.ins.cwi.nl:50000/ Listening for UNIX domain connection requests on mapi:monetdb:///var/tmp/dbfarm/ssdb/.mapi.sock MonetDB/GIS module loaded MonetDB/JAQL module loaded [New Thread 0x7fffede6a700 (LWP 15172)] MonetDB/SQL module loaded MonetDB/DataCell loaded [...] Program received signal SIGBUS, Bus error. [Switching to Thread 0x7fffedc69700 (LWP 15174)] 0x00007ffff69409b7 in BATappend (b=0x7fffe00d83c0, n=0x7fffe0058520, force=1 '\001') at /ufs/zhang/monet/ssdb/gdk/gdk_batop.c:578 578 bunfastins_nocheck(b, r, NULL, BUNtail(ni, p), 0, Tsize(b)); Missing separate debuginfos, use: debuginfo-install bzip2-libs-1.0.6-3.fc15.x86_64 cfitsio-3.280-2.fc16.x86_64 cyrus-sasl-lib-2.1.23-27.fc16.x86_64 geos-3.3.1-1.fc16.x86_64 glibc-2.14.90-24.fc16.9.x86_64 keyutils-libs-1.5.2-1.fc16.x86_64 krb5-libs-1.9.4-3.fc16.x86_64 libcom_err-1.41.14-2.fc15.x86_64 libcurl-7.21.7-8.fc16.x86_64 libgcc-4.6.3-2.fc16.x86_64 libidn-1.22-3.fc16.x86_64 libselinux-2.1.6-6.fc16.x86_64 libssh2-1.2.7-4.fc16.x86_64 libstdc++-4.6.3-2.fc16.x86_64 libuuid-2.20.1-2.3.fc16.x86_64 libxml2-2.7.8-8.fc16.x86_64 ncurses-libs-5.9-2.20110716.fc16.x86_64 nspr-4.9.2-1.fc16.x86_64 nss-3.13.6-1.fc16.x86_64 nss-softokn-freebl-3.13.6-1.fc16.x86_64 nss-util-3.13.6-1.fc16.x86_64 openldap-2.4.26-8.fc16.x86_64 openssl-1.0.0j-1.fc16.x86_64 pcre-8.12-9.fc16.x86_64 readline-6.2-2.fc16.x86_64 zlib-1.2.5-7.fc16.x86_64 (gdb) bt 0 0x00007ffff69409b7 in BATappend (b=0x7fffe00d83c0, n=0x7fffe0058520, force=1 '\001') at /ufs/zhang/monet/ssdb/gdk/gdk_batop.c:578 1 0x00007fffeedf500e in delta_append_bat (bat=0x7fffe009f010, i=0x7fffe0058520) at /ufs/zhang/monet/ssdb/sql/storage/bat/bat_storage.c:268 2 0x00007fffeedf5258 in append_col (tr=0x7fffe0007fb0, c=0x7fffe00b3280, i=0x7fffe0058520, tpe=4) at /ufs/zhang/monet/ssdb/sql/storage/bat/bat_storage.c:307 3 0x00007fffeececdde in mvc_append_wrap (cntxt=0x7fffefc9a338, mb=0x7fffe0073e20, stk=0x7fffe00e2df0, pci=0x7fffe00ea3a0) at /ufs/zhang/monet/ssdb/sql/backends/monet5/sql.mx:3220 4 0x00007ffff718a6c5 in runMALsequence (cntxt=0x7fffefc9a338, mb=0x7fffe0073e20, startpc=1, stoppc=0, stk=0x7fffe00e2df0, env=0x0, pcicaller=0x0) at /ufs/zhang/monet/ssdb/monetdb5/mal/mal_interpreter.c:707 5 0x00007ffff7189c7f in callMAL (cntxt=0x7fffefc9a338, mb=0x7fffe0073e20, env=0x7fffedc68b30, argv=0x7fffedc68bd0, debug=0 '\000') at /ufs/zhang/monet/ssdb/monetdb5/mal/mal_interpreter.c:542 6 0x00007fffeecccd9a in SQLexecutePrepared (c=0x7fffefc9a338, be=0x7fffe005de50, q=0x7fffe00de0a0) at /ufs/zhang/monet/ssdb/sql/backends/monet5/sql_scenario.c:1762 7 0x00007fffeeccd07d in SQLengineIntern (c=0x7fffefc9a338, be=0x7fffe005de50) at /ufs/zhang/monet/ssdb/sql/backends/monet5/sql_scenario.c:1815 8 0x00007fffeeccd614 in SQLengine (c=0x7fffefc9a338) at /ufs/zhang/monet/ssdb/sql/backends/monet5/sql_scenario.c:1941 9 0x00007ffff71ba297 in runPhase (c=0x7fffefc9a338, phase=4) ---Type <return> to continue, or q <return> to quit--- at /ufs/zhang/monet/ssdb/monetdb5/mal/mal_scenario.c:522 10 0x00007ffff71ba491 in runScenarioBody (c=0x7fffefc9a338) at /ufs/zhang/monet/ssdb/monetdb5/mal/mal_scenario.c:573 11 0x00007ffff71ba68e in runScenario (c=0x7fffefc9a338) at /ufs/zhang/monet/ssdb/monetdb5/mal/mal_scenario.c:601 12 0x00007ffff71bb70e in MSserveClient (dummy=0x7fffefc9a338) at /ufs/zhang/monet/ssdb/monetdb5/mal/mal_session.c:430 13 0x000000325f607d90 in start_thread () from /lib64/libpthread.so.0 14 0x000000325eaf119d in clone () from /lib64/libc.so.6 These queries use to work using the Oct2012 branch last September, but now it crashes on the 'ssdb' branch (which is based on Oct2012 and is just merged). If I restart mserver5, and run 'ALTER TABLE images_pixels_very_small ADD PRIMARY KEY (imageid, tile, x, y);' again, it will finish. ## Comment 18224 Date: 2012-12-01 01:13:45 +0100 From: @drstmane Works fine for me, both with latest Oct2012 branch (5bbaa060c8fd) & latest ssdb branch (b3e06448b318): sql>CREATE TABLE images_very_small (imageid INT, xstart INT, ystart INT, xend INT, yend INT, time INT, cyclem INT); operation successful (1.693ms) sql>CREATE TABLE images_pixels_very_small (imageid INT, tile INT, x INT, y INT, pix INT, var INT, valid INT, sat INT, v0 INT, v1 INT, v2 INT, v3 INT, v4 INT, v5 INT, v6 INT); operation successful (2.212ms) sql>COPY INTO images_very_small FROM '/net/riga//export/scratch2/zhang/papers/ssdb/monetdb/data/benchdata.very_small.pos' DELIMITERS ',','\n'; 11 affected rows (142.121ms) sql>COPY 102400000 RECORDS INTO images_pixels_very_small FROM '/net/riga//export/scratch2/zhang/papers/ssdb/monetdb/data/benchdata.very_small' DELIMITERS ',','\n'; 25648186 affected rows (58.4s) sql>ALTER TABLE images_very_small ADD PRIMARY KEY (imageid); operation successful (3.047ms) sql>ALTER TABLE images_pixels_very_small ADD PRIMARY KEY (imageid, tile, x, y); operation successful (11.3s) sql>ALTER TABLE images_pixels_very_small ADD FOREIGN KEY (imageid) REFERENCES images_very_small (imageid); operation successful (2.2s) ## Comment 18226 Date: 2012-12-02 20:28:11 +0100 From: @yzchang error was caused by a full disk ## Comment 19869 Date: 2014-07-03 17:36:33 +0200 From: MonetDB Mercurial Repository &lt;<hg>&gt; Changeset [45acd0d7a20a](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=45acd0d7a20a) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=45acd0d7a20a](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=45acd0d7a20a) Changeset description: Use posix_fallocate if available to extend files. Using this function will ensure that disk blocks are allocated, so when the file is the memory mapped and the memory then written to, we should never get a Bus Error because the disk is full. This hopefully fixes bug #64, bug #3202, and bug #3507, and possibly also bug #3502.
bus error when adding primary key
https://api.github.com/repos/MonetDB/MonetDB/issues/3202/comments
0
2020-11-30T12:15:54Z
2024-06-28T13:16:47Z
https://github.com/MonetDB/MonetDB/issues/3202
753,429,169
3,202
[ "MonetDB", "MonetDB" ]
Date: 2012-11-28 13:56:48 +0100 From: Percy Wegmann &lt;<percy>&gt; To: MonetDB5 devs &lt;<bugs-monetdb5>&gt; Version: 11.13.3 (Oct2012) Last updated: 2012-11-28 14:01:53 +0100 ## Comment 18209 Date: 2012-11-28 13:56:48 +0100 From: Percy Wegmann &lt;<percy>&gt; User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_5) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.64 Safari/537.11 Build Identifier: When setting ulimit -Sv, once Monet encounters the virtual memory limit, it crashes. The way in which it crashes depends on what it was trying to allocate at the time, but in all cases it fails because it is unable to allocate memory. Stefan asked me to log this. I'm not entirely surprised by the behavior myself, since I think ulimit -Sv is effectively restricting Monet's address space. Reproducible: Always ### Steps to Reproduce: In one terminal: - Make sure monet is stopped - Set a max virtual memory size of 100 MB ulimit -Sv 100000 - Start monet using monetdbd start Now, in another window, open an mclient connection to a database. ### Actual Results: The mclient disconnects and returns this error: monetdbd: internal error while starting mserver, please refer to the logs merovingian.log reports this: 2012-11-28 06:51:27 MSG merovingian[26983]: starting database 'click', up min/avg/max: 12s/6h/5d, crash average: 0.00 0.40 0.40 (37-25=12) 2012-11-28 06:51:27 MSG click[27268]: arguments: /usr/local/bin/mserver5 --set gdk_dbfarm=/home/percy/click_monet --dbname=click --set merovingian_uri=mapi:monetdb://percy-sandbox:50000/click --set mapi_open=false --set mapi_port=0 --set mapi_usock=/home/percy/click_monet/click/.mapi.sock --set monet_vault_key=/home/percy/click_monet/click/.vaultkey --set gdk_nr_threads=4 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes 2012-11-28 06:51:27 ERR click[27268]: /usr/local/bin/mserver5: error while loading shared libraries: libasn1.so.8: failed to map segment from shared object: Cannot allocate memory 2012-11-28 06:51:27 MSG merovingian[26983]: database 'click' (27268) has exited with exit status 127 2012-11-28 06:51:27 ERR merovingian[26983]: client error: database 'click' appears to shut itself down after starting, check monetdbd's logfile for possible hints ### Expected Results: - database starts successfully - mclient stays connected - if and when Monet is unable to service a request, it gives the mclient an error message and mclient stays connected When setting higher virtual memory limits (on my system, above 500), Monet is able to start. However, when throwing a workload at it, the database process will terminate with a different memory allocation error or just a SIGSEGV. ## Comment 18210 Date: 2012-11-28 14:01:53 +0100 From: @grobian Yeah, well, the OS complains it can no longer load the shared libraries (they are memmapped too), so we really can't deal with this. Virtual memory is virtual, not real. Don't mess with settings like these. It's like removing the gas-tank of a car, and still expecting the engine to keep on going.
MonetDB crashes when it hits the virtual memory limit
https://api.github.com/repos/MonetDB/MonetDB/issues/3201/comments
0
2020-11-30T12:15:52Z
2024-06-28T13:16:46Z
https://github.com/MonetDB/MonetDB/issues/3201
753,429,143
3,201
[ "MonetDB", "MonetDB" ]
Date: 2012-11-28 13:16:54 +0100 From: Swapnil Joshi &lt;<webmaster.swapnil>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.5 (Oct2012-SP1) CC: @njnes Last updated: 2012-11-28 13:56:13 +0100 ## Comment 18185 Date: 2012-11-28 13:16:54 +0100 From: Swapnil Joshi &lt;<webmaster.swapnil>&gt; User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:14.0) Gecko/20100101 Firefox/14.0.1 Build Identifier: when i am trying to execute mal program i got following error: !TypeException:user.s1_1[76]:'aggr.sum' undefined in Hello Sir, I am doing same research on monetdb. setp 1: I have open [mclient -d test1] and {explain select sum(v1) from demo;} it show following result. swapnil@swapnil-lp:~$ mclient test1 Welcome to mclient, the MonetDB/SQL interactive terminal (Jul2012-SP1) Database: MonetDB v11.11.7 (Jul2012-SP1), 'mapi:monetdb://swapnil-lp:50000/test1' Type \q to quit, \? for a list of available commands auto commit mode: on sql>explain select sum(v1) from demo; +-------------------------------------------------------------------------------+ | mal | +===============================================================================+ | function user.s1_1{autoCommit=true}():void; | | X_13:lng := nil:lng; | | barrier X_141 := language.dataflow(); | | X_2 := sql.mvc(); | | X_35:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,0,8); | | X_71 := algebra.selectNotNil(X_35); | | X_60:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,0,8); | | X_83 := algebra.kdifference(X_71,X_60); | | X_95 := algebra.selectNotNil(X_60); | | X_104 := algebra.kunion(X_83,X_95); | | X_11:bat[:oid,:oid] := sql.bind_dbat(X_2,"sys","demo",1); | | X_12 := bat.reverse(X_11); | | X_117 := algebra.kdifference(X_104,X_12); | | X_131 := aggr.sum(X_117); | | X_39:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,1,8); | | X_73 := algebra.selectNotNil(X_39); | | X_62:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,1,8); | | X_84 := algebra.kdifference(X_73,X_62); | | X_97 := algebra.selectNotNil(X_62); | | X_106 := algebra.kunion(X_84,X_97); | | X_118 := algebra.kdifference(X_106,X_12); | | X_132 := aggr.sum(X_118); | | X_42:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,2,8); | | X_75 := algebra.selectNotNil(X_42); | | X_63:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,2,8); | | X_85 := algebra.kdifference(X_75,X_63); | | X_98 := algebra.selectNotNil(X_63); | | X_108 := algebra.kunion(X_85,X_98); | | X_119 := algebra.kdifference(X_108,X_12); | | X_133 := aggr.sum(X_119); | | X_45:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,3,8); | | X_77 := algebra.selectNotNil(X_45); | | X_64:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,3,8); | | X_86 := algebra.kdifference(X_77,X_64); | | X_99 := algebra.selectNotNil(X_64); | | X_110 := algebra.kunion(X_86,X_99); | | X_120 := algebra.kdifference(X_110,X_12); | | X_134 := aggr.sum(X_120); | | X_48:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,4,8); | | X_78 := algebra.selectNotNil(X_48); | | X_65:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,4,8); | | X_87 := algebra.kdifference(X_78,X_65); | | X_100 := algebra.selectNotNil(X_65); | | X_112 := algebra.kunion(X_87,X_100); | | X_121 := algebra.kdifference(X_112,X_12); | | X_135 := aggr.sum(X_121); | | X_51:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,5,8); | | X_80 := algebra.selectNotNil(X_51); | | X_66:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,5,8); | | X_89 := algebra.kdifference(X_80,X_66); | | X_101 := algebra.selectNotNil(X_66); | | X_113 := algebra.kunion(X_89,X_101); | | X_123 := algebra.kdifference(X_113,X_12); | | X_136 := aggr.sum(X_123); | | X_54:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,6,8); | | X_81 := algebra.selectNotNil(X_54); | | X_68:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,6,8); | | X_91 := algebra.kdifference(X_81,X_68); | | X_102 := algebra.selectNotNil(X_68); | | X_114 := algebra.kunion(X_91,X_102); | | X_125 := algebra.kdifference(X_114,X_12); | | X_137 := aggr.sum(X_125); | | X_58:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,7,8); | | X_82 := algebra.selectNotNil(X_58); | | X_70:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,7,8); | | X_93 := algebra.kdifference(X_82,X_70); | | X_103 := algebra.selectNotNil(X_70); | | X_115 := algebra.kunion(X_93,X_103); | | X_127 := algebra.kdifference(X_115,X_12); | | X_138 := aggr.sum(X_127); | | X_8:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",1); | | X_10 := algebra.selectNotNil(X_8); | | X_129 := algebra.kdifference(X_10,X_12); | | X_139 := aggr.sum(X_129); | | X_130 := mat.pack(X_131,X_132,X_133,X_134,X_135,X_136,X_137,X_138,X_139); | | X_140 := algebra.selectNotNil(X_130); | | X_13:lng := aggr.sum(X_140); | | exit X_141; | | sql.exportValue(1,"sys.demo","L1","bigint",32,0,6,X_13,""); | | end s1_1; | +-------------------------------------------------------------------------------+ 80 tuples (2.845ms) Setp 2: I have copy same mal program on another teminal [mclient -lmsql -dtest1] swapnil@swapnil-lp:~$ mclient -lmsql -dtest1 Welcome to mclient, the MonetDB interactive terminal (Jul2012-SP1) Type \q to quit, \? for a list of available commands msql>function user.s1_1{autoCommit=true}():void; msql> X_13:lng := nil:lng; msql> barrier X_141 := language.dataflow(); msql> X_2 := sql.mvc(); msql> X_35:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,0,8); msql> X_71 := algebra.selectNotNil(X_35); msql> X_60:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,0,8); msql> X_83 := algebra.kdifference(X_71,X_60); msql> X_95 := algebra.selectNotNil(X_60); msql> X_104 := algebra.kunion(X_83,X_95); msql> X_11:bat[:oid,:oid] := sql.bind_dbat(X_2,"sys","demo",1); msql> X_12 := bat.reverse(X_11); msql> X_117 := algebra.kdifference(X_104,X_12); msql> X_131 := aggr.sum(X_117); msql> X_39:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,1,8); msql> X_73 := algebra.selectNotNil(X_39); msql> X_62:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,1,8); msql> X_84 := algebra.kdifference(X_73,X_62); msql> X_97 := algebra.selectNotNil(X_62); msql> X_106 := algebra.kunion(X_84,X_97); msql> X_118 := algebra.kdifference(X_106,X_12); msql> X_132 := aggr.sum(X_118); msql> X_42:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,2,8); msql> X_75 := algebra.selectNotNil(X_42); msql> X_63:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,2,8); msql> X_85 := algebra.kdifference(X_75,X_63); msql> X_98 := algebra.selectNotNil(X_63); msql> X_108 := algebra.kunion(X_85,X_98); msql> X_119 := algebra.kdifference(X_108,X_12); msql> X_133 := aggr.sum(X_119); msql> X_45:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,3,8); msql> X_77 := algebra.selectNotNil(X_45); msql> X_64:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,3,8); msql> X_86 := algebra.kdifference(X_77,X_64); msql> X_99 := algebra.selectNotNil(X_64); msql> X_110 := algebra.kunion(X_86,X_99); msql> X_120 := algebra.kdifference(X_110,X_12); msql> X_134 := aggr.sum(X_120); msql> X_48:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,4,8); msql> X_78 := algebra.selectNotNil(X_48); msql> X_65:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,4,8); msql> X_87 := algebra.kdifference(X_78,X_65); msql> X_100 := algebra.selectNotNil(X_65); msql> X_112 := algebra.kunion(X_87,X_100); msql> X_121 := algebra.kdifference(X_112,X_12); msql> X_135 := aggr.sum(X_121); msql> X_51:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,5,8); msql> X_80 := algebra.selectNotNil(X_51); msql> X_66:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,5,8); msql> X_89 := algebra.kdifference(X_80,X_66); msql> X_101 := algebra.selectNotNil(X_66); msql> X_113 := algebra.kunion(X_89,X_101); msql> X_123 := algebra.kdifference(X_113,X_12); msql> X_136 := aggr.sum(X_123); msql> X_54:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,6,8); msql> X_81 := algebra.selectNotNil(X_54); msql> X_68:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,6,8); msql> X_91 := algebra.kdifference(X_81,X_68); msql> X_102 := algebra.selectNotNil(X_68); msql> X_114 := algebra.kunion(X_91,X_102); msql> X_125 := algebra.kdifference(X_114,X_12); msql> X_137 := aggr.sum(X_125); msql> X_58:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,7,8); msql> X_82 := algebra.selectNotNil(X_58); msql> X_70:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,7,8); msql> X_93 := algebra.kdifference(X_82,X_70); msql> X_103 := algebra.selectNotNil(X_70); msql> X_115 := algebra.kunion(X_93,X_103); msql> X_127 := algebra.kdifference(X_115,X_12); msql> X_138 := aggr.sum(X_127); msql> X_8:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",1); msql> X_10 := algebra.selectNotNil(X_8); msql> X_129 := algebra.kdifference(X_10,X_12); msql> X_139 := aggr.sum(X_129); msql> X_130 := mat.pack(X_131,X_132,X_133,X_134,X_135,X_136,X_137,X_138,X_139); msql> X_140 := algebra.selectNotNil(X_130); msql> X_13:lng := aggr.sum(X_140); msql> exit X_141; msql> sql.exportValue(1,"sys.demo","L1","bigint",32,0,6,X_13,""); msql> end s1_1; MAPI = (monetdb) /tmp/.s.monetdb.50000 QUERY = end s1_1; ERROR = !TypeException:user.s1_1[76]:'aggr.sum' undefined in: X_13:lng := aggr.sum(X_140:bat[:oid,:dbl]) msql>user.s1_1 MAPI = (monetdb) /tmp/.s.monetdb.50000 QUERY = user.s1_1 ERROR = !SyntaxException:parseError: !'(' expected msql>user.s1_1(); MAPI = (monetdb) /tmp/.s.monetdb.50000 QUERY = user.s1_1(); ERROR = !TypeException:user.main[1]:'user.s1_1' undefined in: _1:void := user.s1_1() msql> It gives such error what is reason of giving such error by monetdb. i am really very frustrate what is reasone and how will i execute mal program. please help me !!!!!!!!!!!!! :) and another question is is Monetdb maintain any cache for storing result of SQL statment. -- Reproducible: Always ### Steps to Reproduce: 1.I have open [mclient -d test1] and {explain select sum(v1) from demo;} it show following result. swapnil@swapnil-lp:~$ mclient test1 Welcome to mclient, the MonetDB/SQL interactive terminal (Jul2012-SP1) Database: MonetDB v11.11.7 (Jul2012-SP1), 'mapi:monetdb://swapnil-lp:50000/test1' Type \q to quit, \? for a list of available commands auto commit mode: on sql>explain select sum(v1) from demo; +-------------------------------------------------------------------------------+ | mal | +===============================================================================+ | function user.s1_1{autoCommit=true}():void; | | X_13:lng := nil:lng; | | barrier X_141 := language.dataflow(); | | X_2 := sql.mvc(); | | X_35:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,0,8); | | X_71 := algebra.selectNotNil(X_35); | | X_60:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,0,8); | | X_83 := algebra.kdifference(X_71,X_60); | | X_95 := algebra.selectNotNil(X_60); | | X_104 := algebra.kunion(X_83,X_95); | | X_11:bat[:oid,:oid] := sql.bind_dbat(X_2,"sys","demo",1); | | X_12 := bat.reverse(X_11); | | X_117 := algebra.kdifference(X_104,X_12); | | X_131 := aggr.sum(X_117); | | X_39:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,1,8); | | X_73 := algebra.selectNotNil(X_39); | | X_62:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,1,8); | | X_84 := algebra.kdifference(X_73,X_62); | | X_97 := algebra.selectNotNil(X_62); | | X_106 := algebra.kunion(X_84,X_97); | | X_118 := algebra.kdifference(X_106,X_12); | | X_132 := aggr.sum(X_118); | | X_42:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,2,8); | | X_75 := algebra.selectNotNil(X_42); | | X_63:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,2,8); | | X_85 := algebra.kdifference(X_75,X_63); | | X_98 := algebra.selectNotNil(X_63); | | X_108 := algebra.kunion(X_85,X_98); | | X_119 := algebra.kdifference(X_108,X_12); | | X_133 := aggr.sum(X_119); | | X_45:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,3,8); | | X_77 := algebra.selectNotNil(X_45); | | X_64:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,3,8); | | X_86 := algebra.kdifference(X_77,X_64); | | X_99 := algebra.selectNotNil(X_64); | | X_110 := algebra.kunion(X_86,X_99); | | X_120 := algebra.kdifference(X_110,X_12); | | X_134 := aggr.sum(X_120); | | X_48:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,4,8); | | X_78 := algebra.selectNotNil(X_48); | | X_65:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,4,8); | | X_87 := algebra.kdifference(X_78,X_65); | | X_100 := algebra.selectNotNil(X_65); | | X_112 := algebra.kunion(X_87,X_100); | | X_121 := algebra.kdifference(X_112,X_12); | | X_135 := aggr.sum(X_121); | | X_51:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,5,8); | | X_80 := algebra.selectNotNil(X_51); | | X_66:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,5,8); | | X_89 := algebra.kdifference(X_80,X_66); | | X_101 := algebra.selectNotNil(X_66); | | X_113 := algebra.kunion(X_89,X_101); | | X_123 := algebra.kdifference(X_113,X_12); | | X_136 := aggr.sum(X_123); | | X_54:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,6,8); | | X_81 := algebra.selectNotNil(X_54); | | X_68:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,6,8); | | X_91 := algebra.kdifference(X_81,X_68); | | X_102 := algebra.selectNotNil(X_68); | | X_114 := algebra.kunion(X_91,X_102); | | X_125 := algebra.kdifference(X_114,X_12); | | X_137 := aggr.sum(X_125); | | X_58:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,7,8); | | X_82 := algebra.selectNotNil(X_58); | | X_70:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,7,8); | | X_93 := algebra.kdifference(X_82,X_70); | | X_103 := algebra.selectNotNil(X_70); | | X_115 := algebra.kunion(X_93,X_103); | | X_127 := algebra.kdifference(X_115,X_12); | | X_138 := aggr.sum(X_127); | | X_8:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",1); | | X_10 := algebra.selectNotNil(X_8); | | X_129 := algebra.kdifference(X_10,X_12); | | X_139 := aggr.sum(X_129); | | X_130 := mat.pack(X_131,X_132,X_133,X_134,X_135,X_136,X_137,X_138,X_139); | | X_140 := algebra.selectNotNil(X_130); | | X_13:lng := aggr.sum(X_140); | | exit X_141; | | sql.exportValue(1,"sys.demo","L1","bigint",32,0,6,X_13,""); | | end s1_1; | +-------------------------------------------------------------------------------+ 80 tuples (2.845ms) 2. I have copy same mal program on another teminal [mclient -lmsql -dtest1] swapnil@swapnil-lp:~$ mclient -lmsql -dtest1 Welcome to mclient, the MonetDB interactive terminal (Jul2012-SP1) Type \q to quit, \? for a list of available commands msql>function user.s1_1{autoCommit=true}():void; msql> X_13:lng := nil:lng; msql> barrier X_141 := language.dataflow(); msql> X_2 := sql.mvc(); msql> X_35:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,0,8); msql> X_71 := algebra.selectNotNil(X_35); msql> X_60:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,0,8); msql> X_83 := algebra.kdifference(X_71,X_60); msql> X_95 := algebra.selectNotNil(X_60); msql> X_104 := algebra.kunion(X_83,X_95); msql> X_11:bat[:oid,:oid] := sql.bind_dbat(X_2,"sys","demo",1); msql> X_12 := bat.reverse(X_11); msql> X_117 := algebra.kdifference(X_104,X_12); msql> X_131 := aggr.sum(X_117); msql> X_39:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,1,8); msql> X_73 := algebra.selectNotNil(X_39); msql> X_62:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,1,8); msql> X_84 := algebra.kdifference(X_73,X_62); msql> X_97 := algebra.selectNotNil(X_62); msql> X_106 := algebra.kunion(X_84,X_97); msql> X_118 := algebra.kdifference(X_106,X_12); msql> X_132 := aggr.sum(X_118); msql> X_42:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,2,8); msql> X_75 := algebra.selectNotNil(X_42); msql> X_63:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,2,8); msql> X_85 := algebra.kdifference(X_75,X_63); msql> X_98 := algebra.selectNotNil(X_63); msql> X_108 := algebra.kunion(X_85,X_98); msql> X_119 := algebra.kdifference(X_108,X_12); msql> X_133 := aggr.sum(X_119); msql> X_45:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,3,8); msql> X_77 := algebra.selectNotNil(X_45); msql> X_64:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,3,8); msql> X_86 := algebra.kdifference(X_77,X_64); msql> X_99 := algebra.selectNotNil(X_64); msql> X_110 := algebra.kunion(X_86,X_99); msql> X_120 := algebra.kdifference(X_110,X_12); msql> X_134 := aggr.sum(X_120); msql> X_48:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,4,8); msql> X_78 := algebra.selectNotNil(X_48); msql> X_65:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,4,8); msql> X_87 := algebra.kdifference(X_78,X_65); msql> X_100 := algebra.selectNotNil(X_65); msql> X_112 := algebra.kunion(X_87,X_100); msql> X_121 := algebra.kdifference(X_112,X_12); msql> X_135 := aggr.sum(X_121); msql> X_51:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,5,8); msql> X_80 := algebra.selectNotNil(X_51); msql> X_66:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,5,8); msql> X_89 := algebra.kdifference(X_80,X_66); msql> X_101 := algebra.selectNotNil(X_66); msql> X_113 := algebra.kunion(X_89,X_101); msql> X_123 := algebra.kdifference(X_113,X_12); msql> X_136 := aggr.sum(X_123); msql> X_54:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,6,8); msql> X_81 := algebra.selectNotNil(X_54); msql> X_68:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,6,8); msql> X_91 := algebra.kdifference(X_81,X_68); msql> X_102 := algebra.selectNotNil(X_68); msql> X_114 := algebra.kunion(X_91,X_102); msql> X_125 := algebra.kdifference(X_114,X_12); msql> X_137 := aggr.sum(X_125); msql> X_58:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",0,7,8); msql> X_82 := algebra.selectNotNil(X_58); msql> X_70:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",2,7,8); msql> X_93 := algebra.kdifference(X_82,X_70); msql> X_103 := algebra.selectNotNil(X_70); msql> X_115 := algebra.kunion(X_93,X_103); msql> X_127 := algebra.kdifference(X_115,X_12); msql> X_138 := aggr.sum(X_127); msql> X_8:bat[:oid,:int] := sql.bind(X_2,"sys","demo","v1",1); msql> X_10 := algebra.selectNotNil(X_8); msql> X_129 := algebra.kdifference(X_10,X_12); msql> X_139 := aggr.sum(X_129); msql> X_130 := mat.pack(X_131,X_132,X_133,X_134,X_135,X_136,X_137,X_138,X_139); msql> X_140 := algebra.selectNotNil(X_130); msql> X_13:lng := aggr.sum(X_140); msql> exit X_141; msql> sql.exportValue(1,"sys.demo","L1","bigint",32,0,6,X_13,""); msql> end s1_1; MAPI = (monetdb) /tmp/.s.monetdb.50000 QUERY = end s1_1; ERROR = !TypeException:user.s1_1[76]:'aggr.sum' undefined in: X_13:lng := aggr.sum(X_140:bat[:oid,:dbl]) msql>user.s1_1 MAPI = (monetdb) /tmp/.s.monetdb.50000 QUERY = user.s1_1 ERROR = !SyntaxException:parseError: !'(' expected msql>user.s1_1(); MAPI = (monetdb) /tmp/.s.monetdb.50000 QUERY = user.s1_1(); ERROR = !TypeException:user.main[1]:'user.s1_1' undefined in: _1:void := user.s1_1() msql> It gives such error what is reason of giving such error by monetdb. i am really very frustrate what is reasone and how will i execute mal program. please help me !!!!!!!!!!!!! :) 3. ### Actual Results: MAPI = (monetdb) /tmp/.s.monetdb.50000 QUERY = end s1_1; ERROR = !TypeException:user.s1_1[76]:'aggr.sum' undefined in: X_13:lng := aggr.sum(X_140:bat[:oid,:dbl]) msql>user.s1_1 MAPI = (monetdb) /tmp/.s.monetdb.50000 QUERY = user.s1_1 ERROR = !SyntaxException:parseError: !'(' expected msql>user.s1_1(); MAPI = (monetdb) /tmp/.s.monetdb.50000 QUERY = user.s1_1(); ERROR = !TypeException:user.main[1]:'user.s1_1' undefined in: _1:void := user.s1_1() ### Expected Results: it has to give sum of that specific column. ## Comment 18186 Date: 2012-11-28 13:35:53 +0100 From: @njnes This is not a bug. The output of the explain simply misses the correct full signature. Explain output isn't there for copy/paste actions, its for viewing how the plan is executed (which doesn't require the full type info). ## Comment 18208 Date: 2012-11-28 13:56:13 +0100 From: Swapnil Joshi &lt;<webmaster.swapnil>&gt; (In reply to comment 1) > This is not a bug. The output of the explain simply misses the correct full > signature. Explain output isn't there for copy/paste actions, its for viewing > how the plan is executed (which doesn't require the full type info). Then how will i execute MAL for agrregate function sum: Suppose i want to execute MAL plan for sum statement {select sum(v1) from demo;} Do you have any demo MAL Function? which I can execute there. Thanks for immediate response. :)
!TypeException:user.s1_1[76]:'aggr.sum' undefined
https://api.github.com/repos/MonetDB/MonetDB/issues/3200/comments
0
2020-11-30T12:15:49Z
2024-06-28T13:17:35Z
https://github.com/MonetDB/MonetDB/issues/3200
753,429,103
3,200
[ "MonetDB", "MonetDB" ]
Date: 2012-11-28 10:11:08 +0100 From: @hannesmuehleisen To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.5 (Oct2012-SP1) CC: @hannesmuehleisen, @njnes Last updated: 2013-01-22 09:29:06 +0100 ## Comment 18169 Date: 2012-11-28 10:11:08 +0100 From: @hannesmuehleisen User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_2) AppleWebKit/537.19 (KHTML, like Gecko) Chrome/25.0.1323.1 Safari/537.19 Build Identifier: While investigating Bug #3184, a problem in MonetDB was discovered. The following sequence of commands produces an unexpected result: (login, CREATE TABLE T (a INT);) sSET TIME ZONE INTERVAL '+01:00' HOUR TO MINUTE; Xauto_commit 0 Xreply_size 250 sPREPARE DELETE FROM t;; ( &5 0 0 6 0 % .prepare, .prepare, .prepare, .prepare, .prepare, .prepare table_name % type, digits, scale, schema, table, column name % varchar, int, int, str, str, str type % 0, 1, 1, 0, 0, 0 length ) sexec 0(); sCOMMIT; sPREPARE INSERT INTO t VALUES(?); sexec 1(42); sCOMMIT; Xrelease 1 sPREPARE DELETE FROM t;; ( &2 1 -1 ) Now, the last response is obviously not the expected one for the PREPARE statement. Reproducible: Always ### Steps to Reproduce: 1. create the table t using CREATE TABLE T (a INT); 2. run the attached Java program 3. observe exception and the responses in the created MAPI log file ### Actual Results: Response code &2 ### Expected Results: Normal PREPARE response, code &5 ## Comment 18170 Date: 2012-11-28 10:11:44 +0100 From: @hannesmuehleisen Created attachment 161 MAPI log file containing issue > Attached file: [monet_1354093401387.log](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3199_monet_1354093401387.log_161) (text/plain, 3376 bytes) > Description: MAPI log file containing issue ## Comment 18171 Date: 2012-11-28 10:12:20 +0100 From: @hannesmuehleisen Created attachment 162 Sequence of JDBC calls in Java that provoke the bug > Attached file: [MonetBugExposer.java](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3199_MonetBugExposer.java_162) (application/octet-stream, 852 bytes) > Description: Sequence of JDBC calls in Java that provoke the bug ## Comment 18227 Date: 2012-12-03 10:23:41 +0100 From: @njnes found a bug in the logics for query caching vs prepare/exec. Could you add the test? ## Comment 18229 Date: 2012-12-03 10:39:11 +0100 From: @njnes Changeset [bc7daa96d11e](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=bc7daa96d11e) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=bc7daa96d11e](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=bc7daa96d11e) Changeset description: fixed bug #3199 ## Comment 18362 Date: 2013-01-22 09:29:06 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
Inconspicuous sequence of prepare, execute, commit and close produces error
https://api.github.com/repos/MonetDB/MonetDB/issues/3199/comments
0
2020-11-30T12:15:46Z
2024-06-27T11:58:24Z
https://github.com/MonetDB/MonetDB/issues/3199
753,429,059
3,199
[ "MonetDB", "MonetDB" ]
Date: 2012-11-28 00:40:56 +0100 From: @skinkie To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.3 (Oct2012) CC: gordon, @mlkersten, @njnes Last updated: 2014-02-20 15:02:24 +0100 ## Comment 18167 Date: 2012-11-28 00:40:56 +0100 From: @skinkie User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.17 (KHTML, like Gecko) Chrome/24.0.1312.14 Safari/537.17 Build Identifier: I was doing a few queries on my dataset. Then I wondered about this query; select * from adres where adres.huisletter is null and adres.huisnummertoevoeging is not null; Which resulted in: 0x00007ffff6713c4d in insert_string_bat (b=0x7fffe419d0a0, n=0x7fffc4006010, append=0) at gdk_batop.c:196 196 bunfastins(b, hp, tp); (gdb) bt 0 0x00007ffff6713c4d in insert_string_bat (b=0x7fffe419d0a0, n=0x7fffc4006010, append=0) at gdk_batop.c:196 1 0x00007ffff6717aeb in BATins (b=0x7fffe419d0a0, n=0x7fffc4006010, force=0 '\000') at gdk_batop.c:387 2 0x00007ffff7935367 in MATpackInternal (stk=0x7fffe41a7c20, p=0x7fffe4184a10) at mat.c:125 3 0x00007ffff79361a0 in MATpack (cntxt=0x7ffff30f3338, mb=0x7fffe4078d50, stk=0x7fffe41a7c20, p=0x7fffe4184a10) at mat.c:382 4 0x00007ffff6f749cc in runMALsequence (cntxt=0x7ffff30f3338, mb=0x7fffe4078d50, startpc=1, stoppc=0, stk=0x7fffe41a7c20, env=0x0, pcicaller=0x0) at mal_interpreter.c:707 5 0x00007ffff6f73f63 in callMAL (cntxt=0x7ffff30f3338, mb=0x7fffe4078d50, env=0x7ffff0bc3be0, argv=0x7ffff0bc3c80, debug=0 '\000') at mal_interpreter.c:542 6 0x00007ffff16048bf in SQLexecutePrepared (c=0x7ffff30f3338, be=0x7fffe40701b0, q=0x7fffe4079540) at sql_scenario.c:1763 7 0x00007ffff1604ba7 in SQLengineIntern (c=0x7ffff30f3338, be=0x7fffe40701b0) at sql_scenario.c:1816 8 0x00007ffff1605152 in SQLengine (c=0x7ffff30f3338) at sql_scenario.c:1942 9 0x00007ffff6fa447c in runPhase (c=0x7ffff30f3338, phase=4) at mal_scenario.c:522 10 0x00007ffff6fa4676 in runScenarioBody (c=0x7ffff30f3338) at mal_scenario.c:573 11 0x00007ffff6fa4886 in runScenario (c=0x7ffff30f3338) at mal_scenario.c:601 12 0x00007ffff6fa592a in MSserveClient (dummy=0x7ffff30f3338) at mal_session.c:430 13 0x00007ffff42c9ea7 in start_thread () from /lib64/libpthread.so.0 14 0x00007ffff400314d in clone () from /lib64/libc.so.6 Reproducible: Always ### Expected Results: It seems that: select * from adres where adres.huisletter is null and adres.huisnummertoevoeging is not null limit 10; Works, while the query without limit 10 doesn't. The data is already available at CWI. Latest pull from Oct2012 ## Comment 18173 Date: 2012-11-28 11:09:27 +0100 From: @njnes seems to work fine on the default. Looks similar to *** This bug has been marked as a duplicate of bug #3165 *** ## Comment 18175 Date: 2012-11-28 11:10:45 +0100 From: @njnes also related 3165 *** This bug has been marked as a duplicate of bug #3153 *** ## Comment 18177 Date: 2012-11-28 11:15:46 +0100 From: @njnes lets point the other bugs into this one as we do have (usefull) data here ## Comment 18179 Date: 2012-11-28 11:16:53 +0100 From: @njnes *** Bug #3153 has been marked as a duplicate of this bug. *** ## Comment 18181 Date: 2012-11-28 11:17:10 +0100 From: @njnes *** Bug #3165 has been marked as a duplicate of this bug. *** ## Comment 18184 Date: 2012-11-28 12:06:40 +0100 From: @njnes fix insert_string_bat code. It didn't handle oid,str b, void,str n properly. Now we need a small test.... ## Comment 18312 Date: 2012-12-27 22:20:46 +0100 From: @mlkersten Is the bug still alive om KvK? ## Comment 18313 Date: 2012-12-27 22:21:52 +0100 From: @skinkie It was the last time I tested. ## Comment 18314 Date: 2012-12-27 22:23:24 +0100 From: @skinkie (In reply to comment 8) > It was the last time I tested. But like Niels pointed out, it required a backport of the patch. Maybe I should again upgrade to default. ## Comment 18446 Date: 2013-01-29 10:52:27 +0100 From: @sjoerdmullender Is this bug still present on the Feb2013 branch? If not, I'd like to close this with NEXTFEATURERELEASE since it's unlikely that we'll make another Oct2012-based release. ## Comment 19593 Date: 2014-02-20 15:02:24 +0100 From: @sjoerdmullender Jan2014 has been released.
SIGSEGV insert_string_bat (b=0x7fffe419d0a0, n=0x7fffc4006010, append=0) at gdk_batop.c:196
https://api.github.com/repos/MonetDB/MonetDB/issues/3198/comments
0
2020-11-30T12:15:43Z
2024-06-27T11:58:23Z
https://github.com/MonetDB/MonetDB/issues/3198
753,429,022
3,198
[ "MonetDB", "MonetDB" ]
Date: 2012-11-27 12:03:09 +0100 From: Stratos Idreos &lt;<s.idreos>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.5 (Oct2012-SP1) CC: @njnes Last updated: 2012-12-03 10:31:03 +0100 ## Comment 18039 Date: 2012-11-27 12:03:09 +0100 From: Stratos Idreos &lt;<s.idreos>&gt; User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_2) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.64 Safari/537.11 Build Identifier: Prepare statements are lost after making a user error. So once a statement is prepared it works fine until the user makes a syntax error. After that, the prepared statement is lost and monetdb replies e.g., EXEC: no prepared statement with id: 1 Reproducible: Always ### Steps to Reproduce: prepare select * from sys.tables limit ?; EXEC 1(2); dummy wrong statement; EXEC 1(2); the first exec works fine the second it does not ### Actual Results: sql>prepare select * from sys.tables limit ?; execute prepared statement using: EXEC 1(...) +------+--------+-------+--------+-------+--------+ | type | digits | scale | schema | table | column | +======+========+=======+========+=======+========+ | wrd | 64 | 0 | null | null | null | +------+--------+-------+--------+-------+--------+ 1 tuple (3.998ms) sql>EXEC 1(2); +------+---------+-----------+-------+------+--------+---------------+----------+-----------+ | id | name | schema_id | query | type | system | commit_action | readonly | temporary | +======+=========+===========+=======+======+========+===============+==========+===========+ | 2001 | schemas | 2000 | null | 0 | true | 0 | false | 0 | | 2006 | types | 2000 | null | 0 | true | 0 | false | 0 | +------+---------+-----------+-------+------+--------+---------------+----------+-----------+ 2 tuples (1.335ms) sql>dummy wrong statement; syntax error, unexpected IDENT in: "dummy" sql>EXEC 1(2); EXEC: no prepared statement with id: 1 ### Expected Results: sql>prepare select * from sys.tables limit ?; execute prepared statement using: EXEC 1(...) +------+--------+-------+--------+-------+--------+ | type | digits | scale | schema | table | column | +======+========+=======+========+=======+========+ | wrd | 64 | 0 | null | null | null | +------+--------+-------+--------+-------+--------+ 1 tuple (3.998ms) sql>EXEC 1(2); +------+---------+-----------+-------+------+--------+---------------+----------+-----------+ | id | name | schema_id | query | type | system | commit_action | readonly | temporary | +======+=========+===========+=======+======+========+===============+==========+===========+ | 2001 | schemas | 2000 | null | 0 | true | 0 | false | 0 | | 2006 | types | 2000 | null | 0 | true | 0 | false | 0 | +------+---------+-----------+-------+------+--------+---------------+----------+-----------+ 2 tuples (1.335ms) sql>dummy wrong statement; syntax error, unexpected IDENT in: "dummy" sql>EXEC 1(2); +------+---------+-----------+-------+------+--------+---------------+----------+-----------+ | id | name | schema_id | query | type | system | commit_action | readonly | temporary | +======+=========+===========+=======+======+========+===============+==========+===========+ | 2001 | schemas | 2000 | null | 0 | true | 0 | false | 0 | | 2006 | types | 2000 | null | 0 | true | 0 | false | 0 | +------+---------+-----------+-------+------+--------+---------------+----------+-----------+ 2 tuples (1.335ms) ## Comment 18158 Date: 2012-11-27 17:17:54 +0100 From: @njnes not a bug, but a feature. ## Comment 18165 Date: 2012-11-27 20:34:31 +0100 From: @grobian in what way is that a useful feature? ## Comment 18228 Date: 2012-12-03 10:31:03 +0100 From: @njnes the prepared statement cache is a bit crude, but implementing a more advanced scheme, which checks the effects of the wrong statement is for now to much work ie less high on the priority list...
prepare statement is lost after the first wrong statement is posed
https://api.github.com/repos/MonetDB/MonetDB/issues/3197/comments
0
2020-11-30T12:15:41Z
2024-06-28T13:40:08Z
https://github.com/MonetDB/MonetDB/issues/3197
753,428,999
3,197
[ "MonetDB", "MonetDB" ]
Date: 2012-11-26 13:23:42 +0100 From: martinmiddel To: Documentation maintainers &lt;<bugs-docs>&gt; Version: unspecified Last updated: 2012-11-26 16:22:37 +0100 ## Comment 18005 Date: 2012-11-26 13:23:42 +0100 From: martinmiddel User-Agent: Mozilla/5.0 (Windows NT 6.2; WOW64; rv:16.0) Gecko/20100101 Firefox/16.0 Build Identifier: I'm getting a error 403 on attempting to open the voc_dump.sql.gz and -bz2 files. The files are linked at on http://www.monetdb.org/Documentation/Tutorial. The alleged locations are http://dev.monetdb.org/Assets/VOC/voc_dump.sql.gz and http://dev.monetdb.org/Assets/VOC/voc_dump.sql.bz2. Please fix it, my group and I would like to get to know MonetDB. Reproducible: Always ### Steps to Reproduce: 1.Try to acces http://dev.monetdb.org/Assets/VOC/voc_dump.sql.bz2 or http://dev.monetdb.org/Assets/VOC/voc_dump.sql.gz 2. 3. ### Actual Results: We get a 403 error ### Expected Results: we would get the file ## Comment 18010 Date: 2012-11-26 15:49:31 +0100 From: @grobian The "VOC" part needs to be dropped. Thanks for the report! ## Comment 18013 Date: 2012-11-26 16:22:37 +0100 From: @sjoerdmullender There was an SELinux issue which is now fixed. You should be able to get the documents now.
403 on VOC_dump.sql.gz /bz2
https://api.github.com/repos/MonetDB/MonetDB/issues/3196/comments
0
2020-11-30T12:15:39Z
2024-06-27T11:58:20Z
https://github.com/MonetDB/MonetDB/issues/3196
753,428,976
3,196
[ "MonetDB", "MonetDB" ]
Date: 2012-11-25 19:55:53 +0100 From: mrunal.gawade To: Merovingian devs &lt;<bugs-merovingian>&gt; Version: 11.13.5 (Oct2012-SP1) Last updated: 2012-11-25 20:37:55 +0100 ## Comment 18001 Date: 2012-11-25 19:55:53 +0100 From: mrunal.gawade User-Agent: Mozilla/5.0 (X11; Linux i686) AppleWebKit/537.1 (KHTML, like Gecko) Chrome/21.0.1180.79 Safari/537.1 Build Identifier: Default Branch - parent: 45974:36ab5eed1603 -----From Log -------- SEGMENTATION FAULT OCCURRED A fatal error has occurred which prevents monetdbd from operating. This is likely a bug in monetdbd, please report it on http://bugs.monetdb.org/ and include the tail of this log in your bugreport with your explanation of what you were doing, if possible. ABORTING NOW, YOU HAVE TO MANUALLY KILL ALL REMAINING mserver5 PROCESSES 2012-11-25 19:45:06 MSG merovingian[9577]: redirecting client (local) for database 'SF-10/*' to mapi:monetdb://cologne.ins.cwi.nl:56001/SF-10 ------------- Mserver command line from log --------------- mserver5 --dbpath=/export/scratch2/gawade/MonetDbFarms/Farm2/SF-10 --set merovingian_uri=mapi:monetdb://cologne.ins.cwi.nl:56001/SF-10 --set mapi_open=false --set mapi_port=0 --set mapi_usock=/export/scratch2/gawade/MonetDbFarms/Farm2/SF-10/.mapi.sock --set monet_vault_key=/export/scratch2/gawade/MonetDbFarms/Farm2/SF-10/.vaultkey --set gdk_nr_threads=8 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes -------Stethoscope invocation -------------- -bash-4.2$ stethoscope -dSF-10 -p56001 MAPI = monetdb@cologne.ins.cwi.nl:56001 ACTION= mapi_start_talking ERROR = !Connection terminated -- connection with server mapi:monetdb://cologne.ins.cwi.nl:56001/SF-10 closed Reproducible: Always ### Steps to Reproduce: 1. Start mserver as above 2. start monetdbd 3. attach stethoscope / tomograph 4. Crash of monetdbd / stethoscope ## Comment 18002 Date: 2012-11-25 20:37:31 +0100 From: @grobian Changeset [154bd2fd9350](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=154bd2fd9350) made by Fabian Groffen <fabian@monetdb.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=154bd2fd9350](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=154bd2fd9350) Changeset description: getRemoteDB: properly initialise uri, bug #3195 ## Comment 18003 Date: 2012-11-25 20:37:55 +0100 From: @grobian thanks, fixed
Monetdbd crashes when stethoscope / tomograph is attached
https://api.github.com/repos/MonetDB/MonetDB/issues/3195/comments
0
2020-11-30T12:15:36Z
2024-06-27T11:58:19Z
https://github.com/MonetDB/MonetDB/issues/3195
753,428,945
3,195
[ "MonetDB", "MonetDB" ]
Date: 2012-11-25 14:48:59 +0100 From: mrunal.gawade To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.5 (Oct2012-SP1) CC: @njnes Last updated: 2012-11-25 15:08:30 +0100 ## Comment 17998 Date: 2012-11-25 14:48:59 +0100 From: mrunal.gawade User-Agent: Mozilla/5.0 (X11; Linux i686) AppleWebKit/537.1 (KHTML, like Gecko) Chrome/21.0.1180.79 Safari/537.1 Build Identifier: +-----------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------+ | name | def | status | +=================+================================================================================================================================================================================================================================================================================================================================================================================================================================================================+==============+ | minimal_pipe | optimizer.inline();optimizer.remap();optimizer.deadcode();optimizer.multiplex();optimizer.garbageCollector(); | stable | | default_pipe | optimizer.inline();optimizer.remap();optimizer.evaluate();optimizer.costModel();optimizer.coercions();optimizer.emptySet();optimizer.aliases();optimizer.pushselect();optimizer.mitosis();optimizer.mergetable();optimizer.deadcode();optimizer.commonTerms();optimizer.groups();optimizer.joinPath();optimizer.reorder();optimizer.deadcode();optimizer.reduce();optimizer.dataflow();optimizer.history();optimizer.multiplex();optimizer.garbageCollector(); | stable | | no_mitosis_pipe | optimizer.inline();optimizer.remap();optimizer.evaluate();optimizer.costModel();optimizer.coercions();optimizer.emptySet();optimizer.aliases();optimizer.mergetable();optimizer.deadcode();optimizer.commonTerms();optimizer.groups();optimizer.joinPath();optimizer.reorder();optimizer.deadcode();optimizer.reduce();optimizer.dataflow();optimizer.history();optimizer.multiplex();optimizer.garbageCollector(); | stable | | sequential_pipe | optimizer.inline();optimizer.remap();optimizer.evaluate();optimizer.costModel();optimizer.coercions();optimizer.emptySet();optimizer.aliases();optimizer.mergetable();optimizer.deadcode();optimizer.commonTerms();optimizer.groups();optimizer.joinPath();optimizer.reorder();optimizer.deadcode();optimizer.reduce();optimizer.history();optimizer.multiplex();optimizer.garbageCollector(); | stable | | recycler_pipe | optimizer.inline();optimizer.remap();optimizer.evaluate();optimizer.costModel();optimizer.coercions();optimizer.emptySet();optimizer.aliases();optimizer.deadcode();optimizer.commonTerms();optimizer.groups();optimizer.joinPath();optimizer.deadcode();optimizer.recycle();optimizer.reduce();optimizer.history();optimizer.multiplex();optimizer.garbageCollector(); | experimental | +-----------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------+ 5 tuples (1.690ms) Reproducible: Always ### Steps to Reproduce: 1. select * from optimizers(); 2. 3. ### Actual Results: +-----------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------+ | name | def | status | +=================+================================================================================================================================================================================================================================================================================================================================================================================================================================================================+==============+ | minimal_pipe | optimizer.inline();optimizer.remap();optimizer.deadcode();optimizer.multiplex();optimizer.garbageCollector(); | stable | | default_pipe | optimizer.inline();optimizer.remap();optimizer.evaluate();optimizer.costModel();optimizer.coercions();optimizer.emptySet();optimizer.aliases();optimizer.pushselect();optimizer.mitosis();optimizer.mergetable();optimizer.deadcode();optimizer.commonTerms();optimizer.groups();optimizer.joinPath();optimizer.reorder();optimizer.deadcode();optimizer.reduce();optimizer.dataflow();optimizer.history();optimizer.multiplex();optimizer.garbageCollector(); | stable | | no_mitosis_pipe | optimizer.inline();optimizer.remap();optimizer.evaluate();optimizer.costModel();optimizer.coercions();optimizer.emptySet();optimizer.aliases();optimizer.mergetable();optimizer.deadcode();optimizer.commonTerms();optimizer.groups();optimizer.joinPath();optimizer.reorder();optimizer.deadcode();optimizer.reduce();optimizer.dataflow();optimizer.history();optimizer.multiplex();optimizer.garbageCollector(); | stable | | sequential_pipe | optimizer.inline();optimizer.remap();optimizer.evaluate();optimizer.costModel();optimizer.coercions();optimizer.emptySet();optimizer.aliases();optimizer.mergetable();optimizer.deadcode();optimizer.commonTerms();optimizer.groups();optimizer.joinPath();optimizer.reorder();optimizer.deadcode();optimizer.reduce();optimizer.history();optimizer.multiplex();optimizer.garbageCollector(); | stable | | recycler_pipe | optimizer.inline();optimizer.remap();optimizer.evaluate();optimizer.costModel();optimizer.coercions();optimizer.emptySet();optimizer.aliases();optimizer.deadcode();optimizer.commonTerms();optimizer.groups();optimizer.joinPath();optimizer.deadcode();optimizer.recycle();optimizer.reduce();optimizer.history();optimizer.multiplex();optimizer.garbageCollector(); | experimental | +-----------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------+ 5 tuples (1.690ms) ## Comment 17999 Date: 2012-11-25 15:08:30 +0100 From: @njnes seems to work for me. The lines are very long, but not messed up.
Select * from optimizers(); displays messed up content
https://api.github.com/repos/MonetDB/MonetDB/issues/3194/comments
0
2020-11-30T12:15:34Z
2024-06-28T13:17:34Z
https://github.com/MonetDB/MonetDB/issues/3194
753,428,911
3,194
[ "MonetDB", "MonetDB" ]
Date: 2012-11-24 05:29:07 +0100 From: Brandon Jackson &lt;<monetdbuser>&gt; To: @njnes Version: 11.13.5 (Oct2012-SP1) CC: bugs-sql, monetdbuser, @njnes Last updated: 2013-02-19 13:17:59 +0100 ## Comment 17990 Date: 2012-11-24 05:29:07 +0100 From: Brandon Jackson &lt;<monetdbuser>&gt; User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:17.0) Gecko/17.0 Firefox/17.0 Build Identifier: Pasted email response from Fabian below: Hi Brandon, On 19-11-2012 16:24:09 -0600, Brandon Jackson wrote: > // original query > > // expressions are not supported in group by and order by > > select "time_by_day"."the_year" as "c0", "the_year" || '-12-31' as > "c1" from "time_by_day" as "time_by_day" group by "time_by_day"."the_year", "the_year" > || '-12-31' order by CASE WHEN "time_by_day"."the_year" IS NULL THEN > || 1 ELSE > 0 END, "time_by_day"."the_year" ASC > > // this doesn't work because the group by and order by for c0 are > different > > select "time_by_day"."the_year" as "c0", "the_year" || '-12-31' as > "c1" from "time_by_day" as "time_by_day" group by c0, c1 order by > CASE WHEN "time_by_day"."the_year" IS NULL THEN 1 ELSE 0 END, "time_by_day"."the_year" > ASC > > // this works again > > select "time_by_day"."the_year" as "c0", "the_year" || '-12-31' as > "c1" from "time_by_day" as "time_by_day" group by c0, c1 order by > CASE WHEN c0 IS NULL THEN 1 ELSE 0 END, c0 ASC > > Use SQL queries to illustrate the problem Mondrian is having: > > Query 1, is what we have right now with the dialect just created. If > we turn on the “group by alias” code in Mondrian, I get query 2, but > what we actually need is query 3. > > We have looked at the SQL standard as best we can, but cannot find > where it comes right out and says what the outcome should be. > However, from experience we know most databases we’ve encountered > support this. What is your take on the matter? My feeling is that since group columns need to appear in select, it makes sense that group by doesn't support expressions. The alias solves that, which gets you sort of duplicate elimination for free. I understand you can live with that fine too. What you end up with is the "mismatch" of c0 and its unmodified original column. I think it's worth filing a bug for this one. Niels can judge whether this can be easily detected by some more checking, or not. Fabian -- dr. Fabian Groffen fabian@monetdb.com column-store pioneer www.monetdb.com Reproducible: Always ## Comment 18020 Date: 2012-11-26 21:52:31 +0100 From: @njnes are there other examples of the case 2 vs 3. This example maybe fixable but I'm afraid it may require a more general (even larger) patch. ## Comment 18083 Date: 2012-11-27 14:35:10 +0100 From: @njnes Changeset [89a9ebc92eda](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=89a9ebc92eda) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=89a9ebc92eda](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=89a9ebc92eda) Changeset description: added tests for Bugs 3193, 3179 and 3172 Fixed bug #3191, we now allow the order by column expressions to refer to the lower level projection. This is very limited support voor order by with expressions. Aliases is still preferred. Fixed bug #3179 (or feature request). We now rewrite batstr.*like + subselect into *likeselect. Also some cleanup of pushselect optimizer and mergetable related helper functions in opt_support.c Fixed bug #3172. We still don't allow multi row input in table functions. But we now don't crash on it anymore. Still work on mal.multiplex needed (requires multiple outputs)! ## Comment 18513 Date: 2013-02-19 13:17:59 +0100 From: @sjoerdmullender Feb2013 has been released.
Expressions not supported in the GROUP BY or ORDER BY clause.
https://api.github.com/repos/MonetDB/MonetDB/issues/3193/comments
0
2020-11-30T12:15:31Z
2024-06-27T11:58:18Z
https://github.com/MonetDB/MonetDB/issues/3193
753,428,874
3,193
[ "MonetDB", "MonetDB" ]
Date: 2012-11-21 02:57:08 +0100 From: Julian Hyde &lt;<julianhyde>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.3 (Oct2012) Last updated: 2013-01-22 09:29:15 +0100 ## Comment 17969 Date: 2012-11-21 02:57:08 +0100 From: Julian Hyde &lt;<julianhyde>&gt; User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:16.0) Gecko/20100101 Firefox/16.0 Build Identifier: I prepare the following SQL statement: select case when "sales_fact_1997"."promotion_id" = 0 then 0 else "sales_fact_1997"."store_sales" end as "c0" from "sales_fact_1997" as "sales_fact_1997" using Connection.prepareStatement(String) in JDBC driver. ResultSetMetaData.getColumnCount() returns 1, but ResultSetMetaData.getColumnName(1) throws: java.sql.SQLException: No such column with index: 1 at nl.cwi.monetdb.jdbc.MonetPreparedStatement.getColumnIdx(MonetPreparedStatement.java:311) at nl.cwi.monetdb.jdbc.MonetPreparedStatement.access$400(MonetPreparedStatement.java:53) at nl.cwi.monetdb.jdbc.MonetPreparedStatement$1.getColumnName(MonetPreparedStatement.java:615) at mondrian.rolap.RolapSchema$PhysSchema.describe(RolapSchema.java:1025) This is from mondrian's lagunitas branch, using JDBC driver 2.6 and MonetDB-11.13.4. Reproducible: Always ## Comment 17970 Date: 2012-11-21 08:41:26 +0100 From: @grobian This looks very similar to bug #3158. That fix is in 2.7. Can you give it a try (http://dev.monetdb.org/downloads/testing/Java/Oct2012-SP1/)? ## Comment 17976 Date: 2012-11-21 14:54:02 +0100 From: @grobian Oct2012-SP1 was released (http://dev.monetdb.org/downloads/Java/Oct2012-SP1/monetdb-jdbc-2.7.jar) I believe this is fixed in 2.7 (Oct2012-SP1), please test. ## Comment 17978 Date: 2012-11-21 19:16:08 +0100 From: Julian Hyde &lt;<julianhyde>&gt; Still occurs with 2.7. Error stack is identical. I looked at http://dev.monetdb.org/hg/MonetDB/file/7fb99d31ceec/java/src/nl/cwi/monetdb/jdbc/MonetPreparedStatement.java. It seems a bit strange that getColumnIdx, if it returns, will return an index for which column[index] is null, yet getColumnName uses that index into the columns array. public String getColumnName(int col) throws SQLException { return column[getColumnIdx(col)]; } private int getColumnIdx(int colnr) throws SQLException { int curcol = 0; for (int i = 0; i < size; i++) { if (column[i] != null) continue; curcol++; if (curcol == colnr) return i; } throw new SQLException("No such column with index: " + colnr, "M1M05"); } There is very similar code in MonetResultSet which I suspect is better tested. I also spotted a bug in getTableName. Code looks familiar? public String getTableName(int col) throws SQLException { return column[getColumnIdx(col)]; } ## Comment 17979 Date: 2012-11-21 21:25:42 +0100 From: @grobian (In reply to comment 3) > I also spotted a bug in getTableName. Code looks familiar? please enlighten me, I don't see the bug ## Comment 17980 Date: 2012-11-22 02:40:09 +0100 From: Julian Hyde &lt;<julianhyde>&gt; It should be something like public String getTableName(int col) throws SQLException { return table[getColumnIdx(col)]; } As it stands getTableName(x) will always return the same as getColumnName(x). ## Comment 17981 Date: 2012-11-22 09:01:41 +0100 From: @grobian oh, doh! thanks ## Comment 17982 Date: 2012-11-22 09:05:55 +0100 From: @grobian Changeset [c58ed8603d69](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=c58ed8603d69) made by Fabian Groffen <fabian@monetdb.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=c58ed8603d69](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=c58ed8603d69) Changeset description: getTableName: use correct backing array Thanks Julian Hyde for noticing in bug #3192 ## Comment 17983 Date: 2012-11-22 13:37:16 +0100 From: @grobian Problem found, I mixed up parameters and columns that one has in a prepared statement. Building proper test now. ## Comment 17984 Date: 2012-11-22 13:54:16 +0100 From: @grobian Changeset [59deba53fa55](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=59deba53fa55) made by Fabian Groffen <fabian@monetdb.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=59deba53fa55](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=59deba53fa55) Changeset description: Test_PSmetadata: test for column and parameter metadata This test reveals the problem reported in bug #3192 ## Comment 17985 Date: 2012-11-22 13:54:23 +0100 From: @grobian Changeset [1e15c1849512](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=1e15c1849512) made by Fabian Groffen <fabian@monetdb.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=1e15c1849512](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=1e15c1849512) Changeset description: PreparedStatement: don't mix up parameters and columns PreparedStatements can return metadata for parameters as well as result columns since Dec2011. In previous fixes to cope with this, I didn't quite realise that there is a difference between the two. We now properly separate both, such that we don't mistakenly claim a column or parameter doesn't exist, such as in bug #3192. This changeset makes Test_PSmetadata working correctly. ## Comment 17986 Date: 2012-11-22 13:54:25 +0100 From: @grobian Changeset [e4a6b9edf48f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=e4a6b9edf48f) made by Fabian Groffen <fabian@monetdb.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=e4a6b9edf48f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=e4a6b9edf48f) Changeset description: Add Mtest for bug #3192 ## Comment 18375 Date: 2013-01-22 09:29:15 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
"No such column with index" error if CASE in SELECT clause
https://api.github.com/repos/MonetDB/MonetDB/issues/3192/comments
0
2020-11-30T12:15:28Z
2024-06-27T11:58:17Z
https://github.com/MonetDB/MonetDB/issues/3192
753,428,834
3,192
[ "MonetDB", "MonetDB" ]
Date: 2012-11-20 17:24:36 +0100 From: @skinkie To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.3 (Oct2012) CC: @njnes Last updated: 2013-01-22 09:29:10 +0100 ## Comment 17966 Date: 2012-11-20 17:24:36 +0100 From: @skinkie User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.17 (KHTML, like Gecko) Chrome/24.0.1312.14 Safari/537.17 Build Identifier: >mserver5: rel_optimizer.c:5596: _rel_optimizer: Assertion `0' failed. Aborted Reproducible: Always ### Steps to Reproduce: I am trying the following query; update kvk set anbi = (select begindatum from sys.anbi_kvk, anbi_intern where anbi_kvk.anbi = anbi_intern.id and kvk.kvks = anbi_kvk.kvks and anbi_intern.einddatum is null) where kvk.kvks in (select kvks from anbi_kvk); This results in; mserver5: rel_optimizer.c:5596: _rel_optimizer: Assertion `0' failed. Program received signal SIGABRT, Aborted. [Switching to Thread 0x7ffff0bd7700 (LWP 4376)] 0x00007ffff3f63015 in raise () from /lib64/libc.so.6 (gdb) bt 0 0x00007ffff3f63015 in raise () from /lib64/libc.so.6 1 0x00007ffff3f6448b in abort () from /lib64/libc.so.6 2 0x00007ffff3f5c15e in ?? () from /lib64/libc.so.6 3 0x00007ffff3f5c202 in __assert_fail () from /lib64/libc.so.6 4 0x00007ffff16f1348 in _rel_optimizer (sql=0x7fffe4005470, rel=0x7fffe4107ad0, level=11) at rel_optimizer.c:5596 5 0x00007ffff16f1375 in _rel_optimizer (sql=0x7fffe4005470, rel=0x7fffe4107ad0, level=11) at rel_optimizer.c:5599 6 0x00007ffff16f1375 in _rel_optimizer (sql=0x7fffe4005470, rel=0x7fffe4107ad0, level=10) at rel_optimizer.c:5599 7 0x00007ffff16f1375 in _rel_optimizer (sql=0x7fffe4005470, rel=0x7fffe4107ad0, level=9) at rel_optimizer.c:5599 8 0x00007ffff16f1375 in _rel_optimizer (sql=0x7fffe4005470, rel=0x7fffe4107ad0, level=8) at rel_optimizer.c:5599 9 0x00007ffff16f1375 in _rel_optimizer (sql=0x7fffe4005470, rel=0x7fffe4107ad0, level=7) at rel_optimizer.c:5599 10 0x00007ffff16f1375 in _rel_optimizer (sql=0x7fffe4005470, rel=0x7fffe4107ad0, level=6) at rel_optimizer.c:5599 11 0x00007ffff16f1375 in _rel_optimizer (sql=0x7fffe4005470, rel=0x7fffe4107ad0, level=5) at rel_optimizer.c:5599 12 0x00007ffff16f1375 in _rel_optimizer (sql=0x7fffe4005470, rel=0x7fffe4107ad0, level=4) at rel_optimizer.c:5599 13 0x00007ffff16f1375 in _rel_optimizer (sql=0x7fffe4005470, rel=0x7fffe4107ad0, level=3) at rel_optimizer.c:5599 14 0x00007ffff16f1375 in _rel_optimizer (sql=0x7fffe4005470, rel=0x7fffe4107ad0, level=2) at rel_optimizer.c:5599 15 0x00007ffff16f1375 in _rel_optimizer (sql=0x7fffe4005470, rel=0x7fffe4107ad0, level=1) at rel_optimizer.c:5599 16 0x00007ffff16f13d3 in rel_optimizer (sql=0x7fffe4005470, rel=0x7fffe4107ad0) at rel_optimizer.c:5608 17 0x00007ffff163008d in sql_symbol2relation (c=0x7fffe4005470, sym=0x7fffe40ffc20) at sql.mx:1679 18 0x00007ffff1616c6d in SQLparser (c=0x7ffff3106338) at sql_scenario.c:1560 19 0x00007ffff6faf5ac in runPhase (c=0x7ffff3106338, phase=1) at mal_scenario.c:522 20 0x00007ffff6faf707 in runScenarioBody (c=0x7ffff3106338) at mal_scenario.c:564 21 0x00007ffff6faf9b6 in runScenario (c=0x7ffff3106338) at mal_scenario.c:601 22 0x00007ffff6fb0a5a in MSserveClient (dummy=0x7ffff3106338) at mal_session.c:430 23 0x00007ffff42dcea7 in start_thread () from /lib64/libpthread.so.0 24 0x00007ffff401614d in clone () from /lib64/libc.so.6 (gdb) up 1 0x00007ffff3f6448b in abort () from /lib64/libc.so.6 (gdb) up 2 0x00007ffff3f5c15e in ?? () from /lib64/libc.so.6 (gdb) up 3 0x00007ffff3f5c202 in __assert_fail () from /lib64/libc.so.6 (gdb) up 4 0x00007ffff16f1348 in _rel_optimizer (sql=0x7fffe4005470, rel=0x7fffe4107ad0, level=11) at rel_optimizer.c:5596 5596 assert(0); (gdb) list 5591 } 5592 5593 rel = rewrite(sql, rel, &rel_merge_table_rewrite, &changes); 5594 5595 if (changes && level > 10) 5596 assert(0); 5597 5598 if (changes) 5599 return _rel_optimizer(sql, rel, ++level); 5600 (gdb) print changes $1 = 1 (gdb) print level $2 = 11 ### Expected Results: When I loose the 'where' part of the update. The query finishes and the result is as expected. sql>update kvk set anbi = (select begindatum from sys.anbi_kvk, anbi_intern where anbi_kvk.anbi = anbi_intern.id and kvk.kvks = anbi_kvk.kvks and anbi_intern.einddatum is null); 2416276 affected rows (2.5s) MonetDB 5 server v11.13.6 (64-bit, 64-bit oids) This is an unreleased version Copyright (c) 1993-July 2008 CWI Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved Visit http://www.monetdb.org/ for further information Found 23.5GiB available memory, 8 available cpu cores Libraries: libpcre: 8.31 2012-07-06 (compiled with 8.31) openssl: OpenSSL 1.0.1c 10 May 2012 (compiled with OpenSSL 1.0.1c 10 May 2012) libxml2: 2.8.0 (compiled with 2.8.0) Compiled by: root@openstate-one (x86_64-unknown-linux-gnu) Compilation: gcc -g -Werror -Wall -Wextra -W -Werror-implicit-function-declaration -Wpointer-arith -Wdeclaration-after-statement -Wundef -Wformat=2 -Wno-format-nonliteral -Winit-self -Winvalid-pch -Wmissing-declarations -Wmissing-format-attribute -Wmissing-prototypes -Wold-style-definition -Wpacked -Wunknown-pragmas -Wvariadic-macros -fstack-protector-all -Wstack-protector -Wpacked-bitfield-compat -Wsync-nand -Wjump-misses-init -Wmissing-include-dirs -Wlogical-op -Wunreachable-code Linking : /usr/x86_64-pc-linux-gnu/bin/ld -m elf_x86_64 ## Comment 17991 Date: 2012-11-24 13:33:58 +0100 From: @njnes somehow the optimizer gets into an every changing query plan loop. After 10 rounds we bail out the hard way. Could you send the ddl statements such that we can debug this problem ## Comment 17992 Date: 2012-11-24 14:13:16 +0100 From: @skinkie Created attachment 159 This directly crashes the server. > Attached file: [naarniels.sql](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3191_naarniels.sql_159) (text/plain, 1216 bytes) > Description: This directly crashes the server. ## Comment 17993 Date: 2012-11-24 15:03:23 +0100 From: @skinkie Maybe another suggestion, as you point out "bailing out the hard way" is there a way to just disable the optimiser, print a message in the server and go on without any optimiser? ## Comment 17996 Date: 2012-11-24 18:45:13 +0100 From: @njnes added test recursive_optimizer.Bug-3191.sql Solved the optimizers introduce empty selects. When pushing these down the optimizers get into an endless recursion. This was fixed by no longer pushing down empty selects. ## Comment 17997 Date: 2012-11-24 18:48:30 +0100 From: @njnes Changeset [4c00145df76f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=4c00145df76f) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=4c00145df76f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=4c00145df76f) Changeset description: fixed bug #3191, problem with endless recursive optimizer calls. Solved by not pushing down empty selects. ## Comment 18086 Date: 2012-11-27 14:35:11 +0100 From: @njnes Changeset [89a9ebc92eda](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=89a9ebc92eda) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=89a9ebc92eda](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=89a9ebc92eda) Changeset description: added tests for Bugs 3193, 3179 and 3172 Fixed bug #3191, we now allow the order by column expressions to refer to the lower level projection. This is very limited support voor order by with expressions. Aliases is still preferred. Fixed bug #3179 (or feature request). We now rewrite batstr.*like + subselect into *likeselect. Also some cleanup of pushselect optimizer and mergetable related helper functions in opt_support.c Fixed bug #3172. We still don't allow multi row input in table functions. But we now don't crash on it anymore. Still work on mal.multiplex needed (requires multiple outputs)! ## Comment 18367 Date: 2013-01-22 09:29:10 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
rel_optimizer.c:5596: _rel_optimizer: Assertion `0' failed.
https://api.github.com/repos/MonetDB/MonetDB/issues/3191/comments
0
2020-11-30T12:15:25Z
2024-06-27T11:58:16Z
https://github.com/MonetDB/MonetDB/issues/3191
753,428,795
3,191
[ "MonetDB", "MonetDB" ]
Date: 2012-11-19 19:46:52 +0100 From: Percy Wegmann &lt;<percy>&gt; To: MonetDB5 devs &lt;<bugs-monetdb5>&gt; Version: 11.13.3 (Oct2012) CC: @yzchang Last updated: 2013-01-22 09:29:18 +0100 ## Comment 17954 Date: 2012-11-19 19:46:52 +0100 From: Percy Wegmann &lt;<percy>&gt; User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_5) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.64 Safari/537.11 Build Identifier: This problem is specific to subtracting a column from another column. If subtracting a timestamp literal from a column, things work. Reproducible: Always ### Steps to Reproduce: percy@percy-sandbox:~$ uname -a Linux percy-sandbox 3.2.0-33-generic 52-Ubuntu SMP Thu Oct 18 16:29:15 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux percy@percy-sandbox:~$ monetdbd -v MonetDB Database Server v1.6 (Oct2012) percy@percy-sandbox:~$ mclient -u monetdb -d click password: Welcome to mclient, the MonetDB/SQL interactive terminal (Oct2012) Database: MonetDB v11.13.3 (Oct2012), 'mapi:monetdb://percy-sandbox:50000/click' Type \q to quit, \? for a list of available commands auto commit mode: on sql>create table time_table (atime timestamp, btime timestamp, ctime date); operation successful (33.944ms) sql>insert into time_table values(timestamp '1970-JAN-1', timestamp '1980-DEC-31', date '2012-JAN-1'); 1 affected row (20.649ms) sql>select * from time_table; +----------------------------+----------------------------+------------+ | atime | btime | ctime | +============================+============================+============+ | 1970-01-01 [000000000000](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=000000000000) | 1980-12-31 [000000000000](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=000000000000) | 2012-01-01 | +----------------------------+----------------------------+------------+ 1 tuple (1.402ms) sql>select btime <> atime from time_table; +----------+ | <>_btime | +==========+ | true | +----------+ 1 tuple (1.208ms) sql>select btime - timestamp '1975-JAN-01' from time_table; +---------------+ | sql_sub_btime | +===============+ | 189302400000 | +---------------+ 1 tuple (1.389ms) sql>select btime - atime from time_table; +---------------+ | sql_sub_btime | +===============+ +---------------+ 0 tuples (1.450ms) ### Actual Results: The query that performs date subtraction between two columns returns 0 tuples. ### Expected Results: All queries return 1 tuple Stefan Manegold investigated and concluded the following: This seems to be a bug in batmtime.diff(), which appears to return an empty result on a non-empty input: sql>trace select btime - atime from time_table; +---------------+ | sql_sub_btime | +===============+ +---------------+ 0 tuples (29.511ms) +-------+-----------------------------------------------------------------------------------------------------------------------+ | ticks | stmt | +=======+=======================================================================================================================+ | 1 | X_26:bat[:oid,:lng] := nil:bat[:oid,:lng]; | | 5 | X_2 := sql.mvc(); | | 31 | X_18:bat[:oid,:timestamp] =<tmp_1301>[1] := sql.bind(X_2=0,"sys","time_table","atime",0); | | 22 | X_8:bat[:oid,:timestamp] =<tmp_1113>[0] := sql.bind(X_2=0,"sys","time_table","btime",2); | | 128 | X_12:bat[:oid,:timestamp] =<tmp_1114>[0] := sql.bind(X_2=0,"sys","time_table","btime",1); | | 32 | X_23:bat[:oid,:timestamp] =<tmp_1114>[0] := sql.bind(X_2=0,"sys","time_table","atime",1); | | 38 | X_3:bat[:oid,:timestamp] =<tmp_1314>[1] := sql.bind(X_2=0,"sys","time_table","btime",0); | | 277 | X_20:bat[:oid,:timestamp] =<tmp_1113>[0] := sql.bind(X_2=0,"sys","time_table","atime",2); | | 207 | X_15:bat[:oid,:oid] =<tmp_1313>[0] := sql.bind_dbat(X_2=0,"sys","time_table",1); | | 14 | X_10=<tmp_1271>[1] := algebra.kdifference(X_3==nil:bat[:oid,:timestamp],X_8=="<tmp_1113>":bat[:oid,:timestamp][0]); | | 15 | X_21=<tmp_1270>[1] := algebra.kdifference(X_18==nil:bat[:oid,:timestamp],X_20=="<tmp_1113>":bat[:oid,:timestamp][0]); | | 21 | X_11=<tmp_1316>[1] := algebra.kunion(X_10==nil:timestamp,X_8==nil:bat[:oid,:timestamp]); | | 5 | X_16=<tmpr_1313>[0] := bat.reverse(X_15=nil:bat[:oid,:oid]); | | 22 | X_22=<tmp_1271>[1] := algebra.kunion(X_21==nil:timestamp,X_20==nil:bat[:oid,:timestamp]); | | 15 | X_14=<tmp_1270>[1] := algebra.kunion(X_11==nil:timestamp,X_12==nil:bat[:oid,:timestamp]); | | 11 | X_24=<tmp_1316>[1] := algebra.kunion(X_22==nil:timestamp,X_23==nil:bat[:oid,:timestamp]); | | 7 | X_17=<tmp_1271>[1] := algebra.kdifference(X_14==nil:timestamp,X_16=<tmpr_1313>[0]); | | 7 | X_25=<tmp_1270>[1] := algebra.kdifference(X_24==nil:timestamp,X_16=nil); | | 9 | X_26:bat[:oid,:lng] =<tmp_1316>[0] := batmtime.diff(X_17==nil:timestamp,X_25==nil:timestamp); | | 2301 | barrier X_44 := language.dataflow(); | | 4 | X_28 := sql.resultSet(1,1,X_26=<tmp_1316>:bat[:oid,:lng][0]); | | 5 | sql.rsColumn(X_28=5,"sys.","sql_sub_btime","bigint",64,0,X_26=nil:bat[:oid,:lng]); | | 1 | X_34 := io.stdout(); | | 13 | sql.exportResult(X_34=="104d2":streams,X_28=5); | | 2 | end s7_1; | | 2582 | X_5:void := user.s7_1(); | +-------+-----------------------------------------------------------------------------------------------------------------------+ 26 tuples (29.537ms) ## Comment 17955 Date: 2012-11-20 09:50:11 +0100 From: @sjoerdmullender Changeset [1d7a4799035d](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=1d7a4799035d) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=1d7a4799035d](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=1d7a4799035d) Changeset description: Set missing properties, chief of which the count. This fixes bug #3190. ## Comment 17956 Date: 2012-11-20 09:53:37 +0100 From: @sjoerdmullender Changeset [e123a2c7b7e1](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=e123a2c7b7e1) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=e123a2c7b7e1](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=e123a2c7b7e1) Changeset description: Added test for bug #3190. ## Comment 17957 Date: 2012-11-20 09:55:26 +0100 From: @sjoerdmullender Fixed. This will be in Oct2012-SP2, not in SP1 which is due out this week. ## Comment 18384 Date: 2013-01-22 09:29:18 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
When subtracting two columns of type "timestamp", no results are returned
https://api.github.com/repos/MonetDB/MonetDB/issues/3190/comments
0
2020-11-30T12:15:22Z
2024-06-27T11:58:15Z
https://github.com/MonetDB/MonetDB/issues/3190
753,428,750
3,190
[ "MonetDB", "MonetDB" ]
Date: 2012-11-19 18:54:58 +0100 From: @skinkie To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.3 (Oct2012) CC: @njnes, @drstmane Last updated: 2013-01-22 09:29:08 +0100 ## Comment 17951 Date: 2012-11-19 18:54:58 +0100 From: @skinkie User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.17 (KHTML, like Gecko) Chrome/24.0.1312.14 Safari/537.17 Build Identifier: sql>select * from (select 1 as x) as x where x in (1234567890); MAPI = monetdb@localhost:60001 QUERY = select * from (select 1 as x) as x where x in (1234567890); ERROR = !overflow in calculation. Wouldn't it be possible to have something more meaningful, for example showing the actual value that raised the overflow? Reproducible: Always ## Comment 17952 Date: 2012-11-19 19:01:52 +0100 From: @drstmane Overflow occurs when trying to cast value 1234567890 into a tinyint (1 byte). Plan generation gone wrong due to too eager aiming for minimal implementation types? sql>select * from (select 1 as x) as x where x in (1234567890); overflow in calculation. sql>plan select * from (select 1 as x) as x where x in (1234567890); +-------------------------------------------------------+ | rel | +=======================================================+ | project ( | | | select ( | | | | [ tinyint "1" as x.x ] | | | ) [ x.x, in (tinyint[int "1234567890"] as L2.L1) ] | | ) [ x.x ] | +-------------------------------------------------------+ 5 tuples (0.533ms) Work-around: sql>plan select * from (select cast(1 as integer) as x) as x where x in (1234567890); +----------------------------------------------+ | rel | +==============================================+ | project ( | | | select ( | | | | [ int[tinyint "1"] as x.x ] | | | ) [ x.x, in (int "1234567890" as L2.L1) ] | | ) [ x.x ] | +----------------------------------------------+ 5 tuples (0.433ms) sql>select * from (select cast(1 as integer) as x) as x where x in (1234567890); +---+ | x | +===+ +---+ 0 tuples (3.083ms) ## Comment 17953 Date: 2012-11-19 19:24:27 +0100 From: @skinkie It accidently triggered in a very long range of pasted values in the IN (...) part of the query, so this is just the minimal case I wanted to reproduce. In that specific case, the IN was operating on an integer. But my point here is more in sense: ERROR = !SELECT: identifier 'blabla' unknown I would expect something like: ERROR = !SELECT: calculation on '1234567890' overflowed. ## Comment 18011 Date: 2012-11-26 16:04:03 +0100 From: @sjoerdmullender Changeset [04369d14a3b0](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=04369d14a3b0) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=04369d14a3b0](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=04369d14a3b0) Changeset description: Moved the generation of overflow messages down. This way the message can (and now does) contain the values that caused the problem. This fixes part of the problem in bug #3189. ## Comment 18022 Date: 2012-11-27 10:52:43 +0100 From: @sjoerdmullender Changeset [0f366c399f79](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=0f366c399f79) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=0f366c399f79](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=0f366c399f79) Changeset description: Added test for bug #3189. ## Comment 18168 Date: 2012-11-28 09:29:55 +0100 From: @njnes Changeset [df6fb82513f6](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=df6fb82513f6) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=df6fb82513f6](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=df6fb82513f6) Changeset description: fixes for bug #3189, ie use correct types on both sides of the IN. ## Comment 18365 Date: 2013-01-22 09:29:08 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
Overflow in calculation
https://api.github.com/repos/MonetDB/MonetDB/issues/3189/comments
0
2020-11-30T12:15:20Z
2024-06-27T11:58:14Z
https://github.com/MonetDB/MonetDB/issues/3189
753,428,715
3,189
[ "MonetDB", "MonetDB" ]
Date: 2012-11-19 14:01:56 +0100 From: @skinkie To: Stefan de Konink &lt;<stefan>&gt; Version: 11.13.3 (Oct2012) Last updated: 2013-01-22 09:29:15 +0100 ## Comment 17950 Date: 2012-11-19 14:01:56 +0100 From: @skinkie User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.17 (KHTML, like Gecko) Chrome/24.0.1312.14 Safari/537.17 Build Identifier: The current client does not seem to store history anymore. Neither with -H or --history. The last time we discussed this issue there was a porblem detecting something in the configure phase. As far as I can see readline is installed, so I wonder what other things might be missing. sys-libs/readline-6.2_p1-r1 It would be valuable to remove the help option if the configuration would prevent the storage at all. Reproducible: Always ## Comment 17987 Date: 2012-11-22 13:58:01 +0100 From: @grobian Are you on Oct2012 or on default? In the latter case, we might have introduced a bug when we did some moving of code around in mclient. ## Comment 17988 Date: 2012-11-22 13:58:27 +0100 From: @skinkie Oct2012. ## Comment 18026 Date: 2012-11-27 11:03:14 +0100 From: @sjoerdmullender What is your OS/distribution and version? What version of MonetDB are you using (binary release, self-compiled)? The history works for me so it may have something to do with that. ## Comment 18028 Date: 2012-11-27 11:24:01 +0100 From: @skinkie (In reply to comment 3) > What is your OS/distribution and version? > What version of MonetDB are you using (binary release, self-compiled)? > The history works for me so it may have something to do with that. Gentoo Linux latest unstable Selfcompiled Oct2012 I do remember Fabian and me tested something the last time, but I don't know what. ## Comment 18166 Date: 2012-11-27 23:25:27 +0100 From: @skinkie Created attachment 160 Fix to create the initial history file. The problem is occurs if you don't have a .mapiclient_history_sql in the homedir. Why is this a problem? Because append_history is called from add_history. Append history will set the overwrite=0 argument in history_do_write, which causes the file mode to get O_WRONLY|O_APPEND|O_BINARY opposed to O_WRONLY|O_CREAT|O_TRUNC|O_BINARY. I am glad I could be part of bugday! > Attached file: [fix-mapiclient-history-creation.patch](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3188_fix-mapiclient-history-creation.patch_160) (text/plain, 471 bytes) > Description: Fix to create the initial history file. ## Comment 18239 Date: 2012-12-05 15:58:15 +0100 From: @sjoerdmullender Changeset [86c18d07007c](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=86c18d07007c) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=86c18d07007c](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=86c18d07007c) Changeset description: Create history file if it didn't exist. Obviously only when the user requested history be saved. This fixes bug #3188. ## Comment 18240 Date: 2012-12-05 15:58:51 +0100 From: @sjoerdmullender A slightly different fix has been checked in. ## Comment 18317 Date: 2013-01-04 12:17:28 +0100 From: @skinkie The first time a client tries to save history there is a warning now: "Warning: not saving history" While the second time the message is gone. I don't know if this is intended. ## Comment 18377 Date: 2013-01-22 09:29:15 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
Storage of client history
https://api.github.com/repos/MonetDB/MonetDB/issues/3188/comments
0
2020-11-30T12:15:17Z
2024-06-27T11:58:13Z
https://github.com/MonetDB/MonetDB/issues/3188
753,428,687
3,188
[ "MonetDB", "MonetDB" ]
Date: 2012-11-19 13:26:55 +0100 From: @skinkie To: SQL devs &lt;<bugs-sql>&gt; Version: -- development CC: @yzchang Last updated: 2016-04-11 11:46:34 +0200 ## Comment 17949 Date: 2012-11-19 13:26:55 +0100 From: @skinkie User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.17 (KHTML, like Gecko) Chrome/24.0.1312.14 Safari/537.17 Build Identifier: "The input syntax should comply to the following grammar: [ [ [quote] [[escape]char] * [quote]] feldspar] * record separator. Quote characters in quoted fields may be escaped with a backslash. Field and record separators can be embedded in quoted fields." I wanted to disable the escape character entirely, because it does more harm than it does good. copy 3188251 records into kvk_import from '/home/skinkie/kvk_normal_sort.tsv' using delimiters '', '\t', '\n' NULL AS ''; But this doesn't seem to be picked up. Reproducible: Always ## Comment 17959 Date: 2012-11-20 13:30:38 +0100 From: @grobian so, you effectively want this to work: '\' right? ## Comment 17961 Date: 2012-11-20 13:45:59 +0100 From: @skinkie (In reply to comment 1) > so, you effectively want this to work: > > '\' > > right? Effectively I want '' to work. Ignore all escape chars in the file. ## Comment 17962 Date: 2012-11-20 13:53:16 +0100 From: @grobian I don't know right now if strings are or are not required to be quoted. If so, you exclude your quote character to occur (could be fine). When a string isn't quoted you can't use the , or whatever is the column separating char. It seems to me if you want to add random garbage to the database using copy into, you'll have to ensure it "behaves", e.g. being properly escaped in a double-quoted encapsulation. ## Comment 17963 Date: 2012-11-20 13:58:59 +0100 From: @skinkie (In reply to comment 3) > I don't know right now if strings are or are not required to be quoted. Strings doesn't have to be quoted. The example below '\t', '\n' perfectly import tab separated files. > It seems to me if you want to add random garbage to the database using copy > into, you'll have to ensure it "behaves", e.g. being properly escaped in a > double-quoted encapsulation. No I don't want to put random garbage in, I want to put in text files that might use \ as ordinary character. MonetDB now forces the user to explicitly replace those occurences in that file with \\. If the escape functuality could be disabled, it would just tokenize and copy. ## Comment 17964 Date: 2012-11-20 14:02:54 +0100 From: @grobian I'm not sure if it's easily possible to bypass the escaping routines. ## Comment 17965 Date: 2012-11-20 14:37:46 +0100 From: @skinkie (In reply to comment 5) > I'm not sure if it's easily possible to bypass the escaping routines. From a quickscan in the code from copyfrom and rel_import (sql) to insert_line (monetdb5), it might be possible to add a dynamic escape character. /* recognize fields starting with a quote */ if (*line && *line == fmt[i].quote && (line == s || *(line - 1) != '\\')) { Is my reading of the documentation wrong? If we look at for example to PostgreSQL they have a keyword for ESCAPE. Similar to the keyword QUOTE. In any case it would be a valuable enhancement. ## Comment 18143 Date: 2012-11-27 16:21:39 +0100 From: @yzchang No test needed for feature request
Documentation suggests changing escape character is possible - how to disable it entirely?
https://api.github.com/repos/MonetDB/MonetDB/issues/3187/comments
0
2020-11-30T12:15:15Z
2024-06-28T13:40:08Z
https://github.com/MonetDB/MonetDB/issues/3187
753,428,661
3,187
[ "MonetDB", "MonetDB" ]
Date: 2012-11-16 12:11:58 +0100 From: @bartscheers To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.3 (Oct2012) CC: @njnes Last updated: 2013-01-22 09:29:11 +0100 ## Comment 17946 Date: 2012-11-16 12:11:58 +0100 From: @bartscheers User-Agent: Mozilla/5.0 (X11; Linux i686 on x86_64; rv:16.0) Gecko/20100101 Firefox/16.0 Build Identifier: sql> SELECT CASE WHEN TRUE THEN -10. ELSE 0/0 END; division by zero. but sql> sql>SELECT CASE WHEN TRUE THEN -10 ELSE 0/0 END; +---------------------+ | isnull_single_value | +=====================+ | -10 | +---------------------+ 1 tuple (1.992ms) Reproducible: Always ### Actual Results: division by zero ### Expected Results: same result for the int case We use this on tables where we check if a value c2 is less than 10^{-6}. If so we print 10.0 else c1/c2. ## Comment 17947 Date: 2012-11-16 12:23:40 +0100 From: @bartscheers A work around would be SELECT coalesce (CASE WHEN TRUE THEN -10. end, case when false then 0/0 END); ## Comment 17994 Date: 2012-11-24 17:10:57 +0100 From: @njnes added test case_evaluated_too_early.Bug-3186.sql fixed exp_case_fixup to also handle this case ## Comment 17995 Date: 2012-11-24 17:11:52 +0100 From: @njnes Changeset [1a10469e62a2](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=1a10469e62a2) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=1a10469e62a2](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=1a10469e62a2) Changeset description: fixed bug #3186 ## Comment 18370 Date: 2013-01-22 09:29:11 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
case evaluted to early
https://api.github.com/repos/MonetDB/MonetDB/issues/3186/comments
0
2020-11-30T12:15:13Z
2024-06-27T11:58:11Z
https://github.com/MonetDB/MonetDB/issues/3186
753,428,629
3,186
[ "MonetDB", "MonetDB" ]
Date: 2012-11-16 12:02:44 +0100 From: @drstmane To: clients devs &lt;<bugs-clients>&gt; Version: 11.13.3 (Oct2012) Last updated: 2013-01-22 09:29:16 +0100 ## Comment 17943 Date: 2012-11-16 12:02:44 +0100 From: @drstmane In some (many?/most??/all???) of our command line programs, mserver5, mclient, msqldump, stethoscope, mnc, it seems that the actual implementation of command line options differs from their documentation in the respective usage messages and/or man pages, or getopt_long() is simply used in a wrong way. See the respective code and its documentation for details. We need to double check this to make sure that implementation and documentation are aligned with each other and with the actual intention of the respective options. Moreover, we should align naming and semantics of (similar) command line option across all command line tools. ## Comment 17944 Date: 2012-11-16 12:05:07 +0100 From: @drstmane In fact, mclient & msqldump might be the least likely candidates for inconsistencies. Once they are checked (or fixed, if necessary), please update the component (-> stethoscope) or product (-> MAL/M5, Server tools) accordingly. ## Comment 17945 Date: 2012-11-16 12:11:41 +0100 From: @drstmane There are also inconsistencies / conflicts between supposedly paired long and short options. ## Comment 17948 Date: 2012-11-16 12:39:08 +0100 From: @grobian Yes, and this also differs per platform. ## Comment 18043 Date: 2012-11-27 12:34:37 +0100 From: @sjoerdmullender No need to create a test for this bug. ## Comment 18225 Date: 2012-12-02 15:35:18 +0100 From: @drstmane Finally finalizing my bug-day work yesterday, I hope correctness and consistency of command line options, their documentation and implementation is restored, both in Oct2012 and Feb2013 branch --- for the time being ... ## Comment 18379 Date: 2013-01-22 09:29:16 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
inconsistency between documentation and implementation of command line options
https://api.github.com/repos/MonetDB/MonetDB/issues/3185/comments
0
2020-11-30T12:15:10Z
2024-06-27T11:58:10Z
https://github.com/MonetDB/MonetDB/issues/3185
753,428,596
3,185
[ "MonetDB", "MonetDB" ]
Date: 2012-11-16 11:21:05 +0100 From: Ashish Kumar Singh &lt;<ashishk>&gt; To: Hannes Muehleisen &lt;<hannes>&gt; Version: 11.15.11 (Feb2013-SP3) CC: ashishk, bugs-sql, @hannesmuehleisen, @njnes Last updated: 2013-07-31 13:51:01 +0200 ## Comment 17942 Date: 2012-11-16 11:21:05 +0100 From: Ashish Kumar Singh &lt;<ashishk>&gt; User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.64 Safari/537.11 Build Identifier: MonetDB memory keeps on increasing and will result in crash when a lot of queries are sent to monetdb from a single connection. See a copy paste from email send to user list which was unanswered. Hi, I ran some test on a simple flat schema and below are results hinting at some bug! Vmem and RES are collected from top command. It seems when you close connection at that time only monetdb releases server side resources which is quite undesirable. All queries are insert queries sent using JDBC. Insertion Model Number of record Vmem (MB) RES System Monet DB Health Single Connection Multiple Statement 45603 3596m 2.8g Crash Single Connection Single Statement 69699 2508m 1.9g Crash Single Connection Single Statement Disposed and recreated after every 100 record 396980 713 M 66 M Good Health Single Connection Single Statement Disposed and recreated after every 100 record 800000 713 M 66 M Good Health Single Connection Single Statement Disposed and recreated after every 100 record 396980 773 M 67 M Good Health Single Connection Single Statement Disposed and recreated after every 100 record 8000000 1603 M 97 M Good Health Schema: CREATE TABLE rc_event( roe_type bigint, dc_servername varchar(50), roe_start_datetime timestamp , resources_used_vmem double, resource_list_vmem double, roe_source_id varchar(120), walltime_splitt bigint, ncpu_walltime bigint, custom_resource_1 bigint, custom_resource_2 bigint, custom_resource_3 bigint, custom_resource_4 bigint, custom_resource_5 bigint); I ran these test on CentOS 5.8 2 core 4 GB ram . Regards, Ashish From: Ashish Kumar Singh [mailto:ashishkumar.singh@altair.com] Sent: Saturday, November 10, 2012 5:28 PM To: users-list@monetdb.org Cc: ashishk@altair.com Subject: RE: Database Memory Usage Also it will be interesting to know if large memory usage is due to intermediate results then when can be expect them to be cleaned? ON statement and connection close?? Regards, Ashish From: Ashish Kumar Singh Sent: Saturday, November 10, 2012 3:09 PM To: users-list@monetdb.org Cc: Ashish Kumar Singh Subject: Database Memory Usage HI All, While calculating monetdb size I am observing below : When I am inserting records to Monet DB using JDBC total memory and VM usage is going to 10 G + but when I see file system size of the database directory it is showing something like 1 GB . Is some compression coming to picture here while storing data in file system? Any pointers will be helpful. Regards, Ashish Reproducible: Always ### Steps to Reproduce: 1.Open a JDBC connection 2.fire multiple queries using this connection 3.Database size will keep on increasing resulting in crash once it reaches OS memory limits. It happens with only insert queries which are committed on each insert. ### Actual Results: DB memory is growing ### Expected Results: After commit memory should be released. It shouldn't result in unrealistic crash for small data sets. ## Comment 17989 Date: 2012-11-22 17:49:36 +0100 From: Ashish Kumar Singh &lt;<ashishk>&gt; Hi, Can you please help me by providing your plan for fixing this issue? Regards, Ashish ## Comment 18123 Date: 2012-11-27 15:40:07 +0100 From: @hannesmuehleisen Hello Ahsish, we are trying to reproduce the bug at the moment. Could you maybe provide the Java code you have used to test this? Thanks, Hannes ## Comment 18164 Date: 2012-11-27 20:33:41 +0100 From: @grobian keep bugs-sql@monetdb.org in the loop ## Comment 18182 Date: 2012-11-28 11:41:39 +0100 From: Ashish Kumar Singh &lt;<ashishk>&gt; Hi I will attach the test cases shortly. ## Comment 18220 Date: 2012-11-29 11:33:24 +0100 From: @hannesmuehleisen Created attachment 163 JDBC test case Test case for one-by-one insert with both recycled and recreated statements. > Attached file: [BulkInserter.java](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3184_BulkInserter.java_163) (text/x-java, 3936 bytes) > Description: JDBC test case ## Comment 18221 Date: 2012-11-29 11:33:39 +0100 From: @hannesmuehleisen Created attachment 164 Results from test case > Attached file: [plot.png](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3184_plot.png_164) (image/png, 159823 bytes) > Description: Results from test case ## Comment 18222 Date: 2012-11-29 11:47:19 +0100 From: @hannesmuehleisen I have created a test case for the problems you have mentioned and ran it on the current development version of MonetDB. As you can see in the picture attachment, there is indeed an increasing memory footprint when the query is prepared for every insert. However, I could not observe a crash when running this up to 2 Million tuples. Furthermore, the test with the recycled statement did neither crash nor produce an increasing memory footprint, and was also at least five times faster. In this light, I am looking forward to your test case, but am unable to verify your issue at this point. ## Comment 18966 Date: 2013-07-31 13:51:01 +0200 From: @njnes could you rerun the test, we have solved some leaks recently
MonetDB memory keeps on increasing and will result in crash when a lot of queries are sent to monetdb from a single connection
https://api.github.com/repos/MonetDB/MonetDB/issues/3184/comments
0
2020-11-30T12:15:07Z
2024-06-27T11:58:09Z
https://github.com/MonetDB/MonetDB/issues/3184
753,428,561
3,184
[ "MonetDB", "MonetDB" ]
Date: 2012-11-13 11:19:23 +0100 From: @grobian To: GDK devs &lt;<bugs-common>&gt; Version: 11.17.9 (Jan2014) CC: @yzchang Last updated: 2015-08-12 14:22:15 +0200 ## Comment 17940 Date: 2012-11-13 11:19:23 +0100 From: @grobian The server should terminate early when it detects it is going to load a database that is newer than what it supports, to avoid any damage. ## Comment 18113 Date: 2012-11-27 15:23:07 +0100 From: @yzchang Don't know how to add test for this bug ## Comment 21128 Date: 2015-08-12 14:22:15 +0200 From: @sjoerdmullender I agree completely, but without specifics on when and where we don't check for downgrades, this is hardly a bug report, but more of a general policy statement.
A database downgrade should be impossible
https://api.github.com/repos/MonetDB/MonetDB/issues/3183/comments
0
2020-11-30T12:15:05Z
2024-06-27T11:58:08Z
https://github.com/MonetDB/MonetDB/issues/3183
753,428,532
3,183
[ "MonetDB", "MonetDB" ]
Date: 2012-11-09 20:57:30 +0100 From: Brandon Jackson &lt;<monetdbuser>&gt; To: clients devs &lt;<bugs-clients>&gt; Version: 11.13.3 (Oct2012) CC: monetdbuser, @njnes Last updated: 2012-11-21 14:49:39 +0100 ## Comment 17928 Date: 2012-11-09 20:57:30 +0100 From: Brandon Jackson &lt;<monetdbuser>&gt; User-Agent: Mozilla/5.0 (X11; Linux i686) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.64 Safari/537.11 Build Identifier: When using the JDBC driver with SQuirreL 3.4 and Pentaho Mondrian 3.5 the column/field metadata returned when using aggregate functions, ex. SUM(whatever_column), always return precision and decimal as 0,0 instead of some precision derived from the input types used in the aggregate function itself. When not using an aggregate function and simply "Select My_measure FROM table", the metadata for My_measure is returned correctly with types DECIMAL and NUMERIC. See the attached screen captures of the testing. The same test was performed against MySQL using their JDBC driver, which alludes to what proper output looks similar to. Reproducible: Always ### Steps to Reproduce: 1. Use SQuirreL to execute a simple query Select SUM(some_dec_or_num_col) FROM x 2. Look at the "Columns" tab to see the metadata reported back. 3. It will incorrectly report DECIMAL(0,0) etc if used on a numeric column. ### Actual Results: Mondrian having seen no precision casts the result to an int. The sums come back as 0. Squirrel is a bit smarter and guesses that there is precision and returns a valid answer. ### Expected Results: Expected when using aggregate functions that metadata returned about the dynamically created field/column would at least match the types put in. ## Comment 17929 Date: 2012-11-09 21:00:47 +0100 From: Brandon Jackson &lt;<monetdbuser>&gt; Created attachment 154 Precision and scale not returned using aggregate functions see M0 in the picture > Attached file: [Aggregate functions with decimal or numeric results do not return precision or scale.png](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3182_Aggregate_functions_with_decimal_or_numeric_results_do_not_return_precision_or_scale.png_154) (image/png, 51928 bytes) > Description: Precision and scale not returned using aggregate functions see M0 in the picture ## Comment 17930 Date: 2012-11-09 21:01:39 +0100 From: Brandon Jackson &lt;<monetdbuser>&gt; Created attachment 155 Normal columns, no agg functions return proper precision and scale > Attached file: [Non-aggregate queries return correct metadata.png](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3182_Non-aggregate_queries_return_correct_metadata.png_155) (image/png, 46358 bytes) > Description: Normal columns, no agg functions return proper precision and scale ## Comment 17931 Date: 2012-11-09 21:02:21 +0100 From: Brandon Jackson &lt;<monetdbuser>&gt; Created attachment 156 mclient showing the proper precision and scale of the table in question > Attached file: [mclient - table description.png](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3182_mclient_-_table_description.png_156) (image/png, 23625 bytes) > Description: mclient showing the proper precision and scale of the table in question ## Comment 17932 Date: 2012-11-09 21:02:56 +0100 From: Brandon Jackson &lt;<monetdbuser>&gt; Created attachment 157 MySQL example showing proper scale and precision > Attached file: [Result from MySQL via JDBC reporting scale and precision on aggregate function use.png](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3182_Result_from_MySQL_via_JDBC_reporting_scale_and_precision_on_aggregate_function_use.png_157) (image/png, 31262 bytes) > Description: MySQL example showing proper scale and precision ## Comment 17933 Date: 2012-11-12 12:44:59 +0100 From: @grobian sql>create table type_test ( dval double, nval numeric(5,3)); operation successful (117.142ms) sql>insert into type_test values (5.4, 5.4),(1.3,1.3),(8.252, 8.252); 3 affected rows (16.731ms) sql>select * from type_test; +--------------------------+---------+ | dval | nval | +==========================+=========+ | 5.4000000000000004 | 5.400 | | 1.3 | 1.300 | | 8.2520000000000007 | 8.252 | +--------------------------+---------+ 3 tuples (1.678ms) sql>select count(dval), count(nval) from type_test; +------+-------------+ | L1 | scale_up_L2 | +======+=============+ | 3 | 3000 | +------+-------------+ 1 tuple (2.053ms) sql>select sum(dval), sum(nval) from type_test; +--------------------------+---------+ | L1 | L2 | +==========================+=========+ | 14.952000000000002 | 14.952 | +--------------------------+---------+ 1 tuple (1.674ms) sql> For the count on numeric, I wouldn't expect any scale_up or anything, it simply should return the number of rows (hence integer-like type). The correction made is obviously wrong. ## Comment 17938 Date: 2012-11-12 23:11:29 +0100 From: @njnes added test aggregate_incorrect_precision_scale.Bug-3182.sql fixed in rel_aggr, fix scale isn't needed here. ## Comment 17939 Date: 2012-11-12 23:12:43 +0100 From: @njnes Changeset [31329234b6ea](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=31329234b6ea) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=31329234b6ea](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=31329234b6ea) Changeset description: added test for bug #3182 cleaned up some leftover comments ## Comment 17973 Date: 2012-11-21 14:49:39 +0100 From: @sjoerdmullender Oct2012-SP1 has been released.
When using aggregate SQL functions, precision & decimal metadata for numeric/decimal type returned is 0,0
https://api.github.com/repos/MonetDB/MonetDB/issues/3182/comments
0
2020-11-30T12:15:03Z
2024-06-27T11:58:07Z
https://github.com/MonetDB/MonetDB/issues/3182
753,428,503
3,182
[ "MonetDB", "MonetDB" ]
Date: 2012-11-09 13:12:40 +0100 From: Stella Giannakopoulou &lt;<sgian>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.3 (Oct2012) CC: charnik, @njnes, sgian, @drstmane Last updated: 2013-06-16 18:39:37 +0200 ## Comment 17925 Date: 2012-11-09 13:12:40 +0100 From: Stella Giannakopoulou &lt;<sgian>&gt; User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/535.19 (KHTML, like Gecko) Ubuntu/11.10 Chromium/18.0.1025.168 Chrome/18.0.1025.168 Safari/535.19 Build Identifier: I am running an sql script which performs some joins that involve two tables, the one of which has an index. The problem is that when executing the join query in monetdb, i get zero results, even if there should be some. Reproducible: Always ### Steps to Reproduce: I am running the following script: CREATE TABLE R ( u int NOT NULL, v int NOT NULL, r int NOT NULL ); CREATE TABLE trans ( s int NOT NULL, t int NOT NULL, comp int NOT NULL ); CREATE INDEX trans_st_idx ON trans (s, t); INSERT INTO trans(s, t, comp) VALUES (1, 2, 31), (1, 16, 31), (1, 3, 255), (255, 3, 255); INSERT INTO R (u, v, r) VALUES (0, 1, 1), (1, 2, 3), (2, 4, 3), (1, 4, 16), (1, 3, 2), (3, 2, 255); SELECT TR.x, TR.z, comp FROM (SELECT TR1.u as x, TR1.v as y, TR2.v as z, TR1.r as rxy, TR2.r as ryz FROM R as TR1 JOIN R as TR2 ON (TR1.v = TR2.u AND TR1.u <> TR2.v) ) as TR JOIN trans ON (TR.rxy = s AND TR.ryz = t); ### Actual Results: +---+---+------+ | x | z | comp | +===+===+======+ +---+---+------+ ### Expected Results: x | z | comp ---+---+------ 0 | 3 | 31 0 | 2 | 255 0 | 4 | 31 3 | 4 | 255 (4 rows) The problem disappears when i remove the statement that creates the index on table R: CREATE INDEX trans_st_idx ON trans (s, t); I have tested the same script in postgres and I get the expected results. ## Comment 17926 Date: 2012-11-09 13:20:12 +0100 From: Stella Giannakopoulou &lt;<sgian>&gt; Created attachment 153 The script that returns the wrong results. > Attached file: [bug_monet.sql](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3181_bug_monet.sql_153) (text/x-sql, 643 bytes) > Description: The script that returns the wrong results. ## Comment 17927 Date: 2012-11-09 16:02:21 +0100 From: @drstmane Confirmed with both Oct2012 & current development branch. Work-around until we fix the bug: do not create the index ;-) ## Comment 18007 Date: 2012-11-26 15:04:53 +0100 From: @njnes Added test join_over_multitable_using_index.Bug-3181 ## Comment 18008 Date: 2012-11-26 15:06:57 +0100 From: @njnes The problem was caused by a multicolumn join expression over (3 tables). The index table and 2 other tables. We now don't allow join's over more than 2 tables to be rewritten using the index column. ## Comment 18012 Date: 2012-11-26 16:19:23 +0100 From: @njnes Changeset [28d08769660b](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=28d08769660b) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=28d08769660b](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=28d08769660b) Changeset description: add test for bug #3181 ## Comment 18380 Date: 2013-01-22 09:29:16 +0100 From: @sjoerdmullender Oct2012-SP3 has been released. ## Comment 18848 Date: 2013-06-16 18:39:37 +0200 From: MonetDB Mercurial Repository &lt;<hg>&gt; Changeset [56d9e6140bfe](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=56d9e6140bfe) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=56d9e6140bfe](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=56d9e6140bfe) Changeset description: new fix for bug #3181.
Join query returns zero results when there is an index on the tables
https://api.github.com/repos/MonetDB/MonetDB/issues/3181/comments
0
2020-11-30T12:14:59Z
2024-06-27T11:58:06Z
https://github.com/MonetDB/MonetDB/issues/3181
753,428,460
3,181
[ "MonetDB", "MonetDB" ]
Date: 2012-11-07 16:19:27 +0100 From: @hannesmuehleisen To: Merovingian devs &lt;<bugs-merovingian>&gt; Version: 11.13.3 (Oct2012) CC: @hannesmuehleisen Last updated: 2012-11-07 18:52:44 +0100 ## Comment 17883 Date: 2012-11-07 16:19:27 +0100 From: @hannesmuehleisen User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:16.0) Gecko/20100101 Firefox/16.0 Build Identifier: I am running the following commands: monetdbd create /some/path/dbfarm monetdbd start /some/path/dbfarm monetdb create mydb monetdb start mydb monetdb release mydb (So far, all is well, but then:) mclient -u monetdb -d mydb password: CREATE FUNCTION: name 'storage' already in use ParseException:SQLparser:CREATE FUNCTION: name 'storage' already in use I have then run mclient -u monetdb -d mydb -X password: MAPI = (monetdb) /tmp/.s.monetdb.50000 ACTION= mapi_start_talking ERROR = !CREATE FUNCTION: name 'storage' already in use !ParseException:SQLparser:CREATE FUNCTION: name 'storage' already in use and looked at "mapi_start_talking" in clients/mapilib/mapi.c, but not find references to a function being created. I then assumed that this is an error thrown in the backend ending up in the client, and looked for places where a function named "storage" is being created, but no luck. Maybe "I am doing it wrong", if so, it would be nice if someone could point me in the right direction. Reproducible: Always ### Actual Results: Error Message ### Expected Results: Shell to DB open ## Comment 17884 Date: 2012-11-07 16:25:11 +0100 From: @grobian Can you give any information on /what/ you did/installed? Most likely hg summary will do, but the output of "mserver5 --version" (as we ask for in the instructions when filing this bug) would also be informative. ## Comment 17885 Date: 2012-11-07 16:29:42 +0100 From: @hannesmuehleisen I have downloaded the last source tarball release version, MonetDB-11.13.3. Output of mserver5 --version: MonetDB 5 server v11.13.3 "Oct2012" (64-bit, 64-bit oids) Copyright (c) 1993-July 2008 CWI Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved Visit http://www.monetdb.org/ for further information Found 15.6GiB available memory, 8 available cpu cores Libraries: libpcre: 8.12 2011-01-15 (compiled with 8.12) openssl: OpenSSL 1.0.0j 10 May 2012 (compiled with OpenSSL 1.0.0j-fips 10 May 2012) libxml2: 2.7.8 (compiled with 2.7.8) Compiled by: hannes@bristol.ins.cwi.nl (x86_64-unknown-linux-gnu) Compilation: gcc -g -O2 Linking : /usr/bin/ld -m elf_x86_64 ## Comment 17886 Date: 2012-11-07 16:31:06 +0100 From: @hannesmuehleisen I went through the usual ./bootstrap, ./compile --prefix=/some/non/root/dir, make, make install ## Comment 17887 Date: 2012-11-07 16:42:13 +0100 From: @grobian seems you got it to work (at least it works for me now) ## Comment 17888 Date: 2012-11-07 17:06:03 +0100 From: @sjoerdmullender The function sys.storage is created when a new database is created (see 25_debug.sql in .../monetdb5/createdb). It is also created during an upgrade to Apr2012-SP1 or later if the function sys.optimizers does not exist. I don't know what I should make of the error message in the context of what you say you did. It always helps to look at the logs (merovingian.log, that is).
Error when connecting to a new database
https://api.github.com/repos/MonetDB/MonetDB/issues/3180/comments
0
2020-11-30T12:14:57Z
2024-06-28T13:17:33Z
https://github.com/MonetDB/MonetDB/issues/3180
753,428,411
3,180
[ "MonetDB", "MonetDB" ]
Date: 2012-11-07 15:09:36 +0100 From: @swingbit To: @njnes Version: 11.13.3 (Oct2012) CC: bugs-sql, @njnes Last updated: 2013-02-19 13:17:57 +0100 ## Comment 17882 Date: 2012-11-07 15:09:36 +0100 From: @swingbit User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.11 (KHTML, like Gecko) Chrome/23.0.1271.60 Safari/537.11 Build Identifier: Take the following query: sql>select name,func from functions where name like '%optimizers%'; +------------+----------------------------------------------------+ | name | func | +============+====================================================+ | optimizers | -- MONETDB KERNEL SECTION | : : -- optimizer pipe catalog : : : create function optimizers () : : : returns table (name string, def string, status st : : : ring) : : : external name sql.optimizers; : +------------+----------------------------------------------------+ 1 tuple (2.156ms) And its explain (I used the sequential_pipe to get a more readable explain): sql>explain select name,func from functions where name like '%optimizers%'; +-----------------------------------------------------------------------+ | mal | +=======================================================================+ | function user.s14_1{autoCommit=true}(A0:str):void; | | X_23 := nil:bat[:oid,:str]; | | X_33 := nil:bat[:oid,:str]; | | barrier X_62 := language.dataflow(); | | X_3 := sql.mvc(); | | X_4:bat[:oid,:str] := sql.bind(X_3,"sys","functions","name",0); | | X_9:bat[:oid,:str] := sql.bind(X_3,"sys","functions","name",2); | | X_11 := algebra.kdifference(X_4,X_9); | | X_12 := algebra.kunion(X_11,X_9); | | X_13:bat[:oid,:str] := sql.bind(X_3,"sys","functions","name",1); | | X_15 := algebra.kunion(X_12,X_13); | | X_16:bat[:oid,:oid] := sql.bind_dbat(X_3,"sys","functions",1); | | X_17 := bat.reverse(X_16); | | X_18 := algebra.kdifference(X_15,X_17); | | X_19 := batcalc.str(X_18); | | X_20 := pcre.like_filter(X_19,A0,"":str); | | X_21 := algebra.markT(X_20,0@0:oid); | | X_22 := bat.reverse(X_21); | | X_23 := algebra.leftjoin(X_22,X_15); | | X_24:bat[:oid,:str] := sql.bind(X_3,"sys","functions","func",0); | | X_26:bat[:oid,:str] := sql.bind(X_3,"sys","functions","func",2); | | X_27 := algebra.kdifference(X_24,X_26); | | X_28 := algebra.kunion(X_27,X_26); | | X_29:bat[:oid,:str] := sql.bind(X_3,"sys","functions","func",1); | | X_32 := algebra.kunion(X_28,X_29); | | X_33 := algebra.leftjoin(X_22,X_32); | | exit X_62; | | X_34 := sql.resultSet(2,1,X_23); | | sql.rsColumn(X_34,"sys.functions","name","varchar",256,0,X_23); | | sql.rsColumn(X_34,"sys.functions","func","varchar",8196,0,X_33); | | X_45 := io.stdout(); | | sql.exportResult(X_45,X_34); | | end s14_1; | +-----------------------------------------------------------------------+ 33 tuples (2.937ms) Notice that pcre.like_filter() is used. Now, I define the following function: create function contains(str string, substr string) returns boolean begin return str like '%'||substr||'%'; end; And get the explain for the following query (equivalent to the previous one): sql>explain select name,func from functions where contains(name, 'optimizers'); +-----------------------------------------------------------------------+ | mal | +=======================================================================+ | function user.s21_1{autoCommit=true}(A0:str):void; | | X_22 := nil:bat[:oid,:str]; | | X_36 := nil:bat[:oid,:str]; | | barrier X_70 := language.dataflow(); | | X_3 := sql.mvc(); | | X_4:bat[:oid,:str] := sql.bind(X_3,"sys","functions","name",0); | | X_9:bat[:oid,:str] := sql.bind(X_3,"sys","functions","name",2); | | X_11 := algebra.kdifference(X_4,X_9); | | X_12 := algebra.kunion(X_11,X_9); | | X_13:bat[:oid,:str] := sql.bind(X_3,"sys","functions","name",1); | | X_15 := algebra.kunion(X_12,X_13); | | X_16:bat[:oid,:oid] := sql.bind_dbat(X_3,"sys","functions",1); | | X_17 := bat.reverse(X_16); | | X_18 := algebra.kdifference(X_15,X_17); | | X_59 := calc.+("%":str,A0); | | X_60 := calc.+(X_59,"%":str); | | X_61 := batstr.like(X_18,X_60); | | X_19 := algebra.uselect(X_61,true:bit); | | X_20 := algebra.markT(X_19,0@0:oid); | | X_21 := bat.reverse(X_20); | | X_22 := algebra.leftjoin(X_21,X_18); | | X_23:bat[:oid,:str] := sql.bind(X_3,"sys","functions","func",0); | | X_28:bat[:oid,:str] := sql.bind(X_3,"sys","functions","func",2); | | X_30 := algebra.kdifference(X_23,X_28); | | X_31 := algebra.kunion(X_30,X_28); | | X_32:bat[:oid,:str] := sql.bind(X_3,"sys","functions","func",1); | | X_34 := algebra.kunion(X_31,X_32); | | X_35 := algebra.kdifference(X_34,X_17); | | X_36 := algebra.leftjoin(X_21,X_35); | | exit X_70; | | X_37 := sql.resultSet(2,1,X_22); | | sql.rsColumn(X_37,"sys.functions","name","varchar",256,0,X_22); | | sql.rsColumn(X_37,"sys.functions","func","varchar",8196,0,X_36); | | X_45 := io.stdout(); | | sql.exportResult(X_45,X_37); | | end s21_1; | +-----------------------------------------------------------------------+ 36 tuples (3.790ms) Notice that, this time, pcre.like_filter() is replaced now with batstr.like() + algebra.uselect(). In principle I wouldn't consider this as a bug, as long as this difference comes for a reason. However, I mark it as a bug because: 1) the batstr.like() + algebra.uselect() version is MUCH slower, so it should not be used unless there is a good reason 2) when I tried both versions on larger tables, the batstr.like() + algebra.uselect() MISSED RESULTS Reproducible: Always ### Steps to Reproduce: 1. try both versions mentioned above 2. preferably on large string columns 3. MonetDB 5 server v11.11.12 (64-bit, 64-bit oids) This is an unreleased version Copyright (c) 1993-July 2008 CWI Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved Visit http://www.monetdb.org/ for further information Found 35.5GiB available memory, 8 available cpu cores Libraries: libpcre: 7.8 2008-09-05 (compiled with 7.8) openssl: OpenSSL 1.0.0d 8 Feb 2011 (compiled with OpenSSL 1.0.0d-fips 8 Feb 2011) libxml2: 2.7.7 (compiled with 2.7.7) Compiled by: roberto@spinque01.ins.cwi.nl (x86_64-unknown-linux-gnu) Compilation: gcc -g -Werror -Wall -Wextra -W -Werror-implicit-function-declaration -Wpointer-arith -Wdeclaration-after-statement -Wformat=2 -Wno-format-nonliteral -Winit-self -Winvalid-pch -Wmissing-declarations -Wmissing-format-attribute -Wmissing-prototypes -Wold-style-definition -Wpacked -Wunknown-pragmas -Wvariadic-macros -fstack-protector-all -Wstack-protector -Wpacked-bitfield-compat -Wsync-nand -Wmissing-include-dirs Linking : /usr/bin/ld -m elf_x86_64 ## Comment 18000 Date: 2012-11-25 15:20:19 +0100 From: @njnes The mal plan with function will first inline the contains function, then rewrite it. The later works on bases of equal names, but different module name (ie batstr instead of str. So we need to align names of single value, bulk and select operators, str.like, batstr.like and likesubselect (former filter). To go from batstr.like + subselect (former uselect) a new optimizer should be introduced. ## Comment 18021 Date: 2012-11-27 10:05:39 +0100 From: @grobian keep alias in the loop ## Comment 18084 Date: 2012-11-27 14:35:11 +0100 From: @njnes Changeset [89a9ebc92eda](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=89a9ebc92eda) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=89a9ebc92eda](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=89a9ebc92eda) Changeset description: added tests for Bugs 3193, 3179 and 3172 Fixed bug #3191, we now allow the order by column expressions to refer to the lower level projection. This is very limited support voor order by with expressions. Aliases is still preferred. Fixed bug #3179 (or feature request). We now rewrite batstr.*like + subselect into *likeselect. Also some cleanup of pushselect optimizer and mergetable related helper functions in opt_support.c Fixed bug #3172. We still don't allow multi row input in table functions. But we now don't crash on it anymore. Still work on mal.multiplex needed (requires multiple outputs)! ## Comment 18510 Date: 2013-02-19 13:17:57 +0100 From: @sjoerdmullender Feb2013 has been released.
LIKE: batstr.like+algebra.uselect called instead of pcre.like_filter
https://api.github.com/repos/MonetDB/MonetDB/issues/3179/comments
0
2020-11-30T12:14:53Z
2024-06-27T11:58:04Z
https://github.com/MonetDB/MonetDB/issues/3179
753,428,377
3,179
[ "MonetDB", "MonetDB" ]
Date: 2012-11-06 22:59:41 +0100 From: Yin &lt;<yinhqiao>&gt; To: MonetDB5 devs &lt;<bugs-monetdb5>&gt; Version: 11.13.9 (Oct2012-SP3) CC: @yzchang Last updated: 2013-02-19 13:17:56 +0100 ## Comment 17881 Date: 2012-11-06 22:59:41 +0100 From: Yin &lt;<yinhqiao>&gt; User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:2.0) Gecko/20100101 Firefox/4.0 Build Identifier: The current implementation takes two scans of the BAT. First scan to compute the sum (average) Second scan to compute stdev. By using a well-known mathematical property of the stdev, one scan is enough: during the scan, the sum of the value and the square of the value can be computed together, and the stdev can be computed then. Reproducible: Always Yin's one scan implementation is available by the following diff: diff -r bcdb312657ff monetdb5/modules/kernel/algebra.mx --- a/monetdb5/modules/kernel/algebra.mx Tue Nov 06 12:03:33 2012 -0800 +++ b/monetdb5/modules/kernel/algebra.mx Tue Nov 06 13:40:09 2012 -0800 @@ -4149,47 +4149,64 @@ } /* - * @+ BAT standard deviation + * @+ BAT standard deviation---Yin's one scan implementation */ @= stdev_impl str ALGstdev_@1(dbl *res, int *bid) { BAT *b; - BUN cnt = 0; - + BUN cnt; + BATiter bi; + bit hasnull; + BUN p,q; + @1 value; + dbl x, sum, sumsqr, stdev; + if ((b=BATdescriptor(*bid)) == NULL) { throw(MAL, "algebra.stdev", RUNTIME_OBJECT_MISSING); } + BATcheck(b,"ALGstdev_@1"); + cnt = BATcount(b); - if (cnt) { - dbl stdev = 0; - /* first, we need the average of the tail values */ - bit t = TRUE; - dbl avg = 0; - CMDsum_@1_dbl(&avg, b, &t); - if (avg != dbl_nil) { - BATiter bi = bat_iterator(b); - BUN p,q; - - avg /= cnt; - - /* next, we need the sum of the squares of the difference of each - value in the tail with the avg */ - - /* no need to check for nil values on the tail, the CMDsum has - already done that and reported back */ - BATloop(b, p, q) { - dbl value = (dbl) *(@1*) BUNtloc(bi, p); - value -= avg; /* diff from avg */ - value *= value; /* square */ - stdev += value; /* sum of squares */ - } - - /* finaly, divide by the cnt and compute the square root */ - *res = sqrt(stdev/cnt); - } else { - *res = dbl_nil; + hasnull = FALSE; + bi = bat_iterator(b); + x = 0; + sum = 0; + sumsqr = 0; + stdev = 0; + if (b->T->nonil) { + BATloop(b, p, q) { + x = (dbl) *(@1*) BUNtloc(bi, p); + sum += x; + x *= x; + sumsqr += x; + } + } else { + BATloop(b, p, q) { + value = *(@1*) BUNtloc(bi, p); + if (value == @1_nil) { + hasnull = TRUE; + break; + } else { + x = (dbl) value; + sum += x; + x *= x; + sumsqr += x; + } + } } + if(!hasnull) { + stdev = sumsqr - (sum*sum)/cnt; + if(stdev < 0) { // theoretically, that is impossible, but here it is a safegard against potential accumulation error + *res = 0; + } + else { + *res = sqrt(stdev/cnt); + } + } + else { + *res = dbl_nil; + } } else { *res = dbl_nil; } ## Comment 17941 Date: 2012-11-13 21:50:08 +0100 From: Yin &lt;<yinhqiao>&gt; Created attachment 158 compute stdev with one scan of BAT > Attached file: [proposed_fix_bug3178.txt](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3178_proposed_fix_bug3178.txt_158) (text/plain, 3102 bytes) > Description: compute stdev with one scan of BAT ## Comment 17960 Date: 2012-11-20 13:36:41 +0100 From: @grobian Hi Yin, This is nice! However, I'm wondering what the error bound of this approach is. Agreed this would be faster, but if it is less "correct" we might want to introduce a variant of stddev that uses your implementation. If this is a very broadly accepted way of computing stddev, we might also drop our current "exact" implementation, or make it available under another name, such that the user can choose from the two. ## Comment 17967 Date: 2012-11-20 20:26:54 +0100 From: Yin &lt;<yinhqiao>&gt; Thank you very much for your comments, Fabian. I had the same concern about the accumulation error of one-scan approach as you do, even though mathematically they should be exactly the same. I remember about 10 years ago, I did some experimentations on both of the approaches and I did not found any noticeable differences between the results, but the sample size I tried then is not huge. For the sample size of the order 1 trillion, I have the same concern even with the two-scan approach. For example, After 500 billion entries have been added to the sum of square, the rest may not be able to be added up anymore, since it may well with the range of accumulation errors! For a huge BAT, if the precision is top priority, we may need to use an hierarchical approach: divide the huge sample into some manageable block, compute it for each block first, and then aggregate the results. ## Comment 17968 Date: 2012-11-20 23:19:15 +0100 From: @sjoerdmullender The sentiment of doing a single scan calculation is good, but I don't think this is the right way to do it. The problem is with the (large) potential for overflow and for large errors in the result. The overflow can arise easily because you calculate the sum of the squares (note that this is not different from the current implementation). When calculating this sum (and also the normal sum), the order in which the calculation is done can cause errors. If the first values are large and later values are small, the small ones may get ignored because they don't register. Try e.g. a table that starts with one large number (1e8 will probably do) that is followed by millions of small (but not zero, e.g. 1) numbers. I am currently investigating a different single scan approach (see http://en.wikipedia.org/wiki/Algorithms_for_calculating_varianceOnline_algorithm). ## Comment 17977 Date: 2012-11-21 19:05:42 +0100 From: Yin &lt;<yinhqiao>&gt; Definitely, there are a lot of rooms for improvement over the naive implementation. If the data are approximately coming from a normal distribution where the absolute value of mean is not too big compared with its stddev, then the naive implementation will yield reasonable results. For the data sampling from Cauchy distribution, the mean and stddev are not well defined anyway, no matter what algorithm you use, the computed value of stddev does not have much meaning. The situations are similar for other long tail distributions such as power law distribution, where stddev is not a description for the dataset. ## Comment 18035 Date: 2012-11-27 11:43:48 +0100 From: @yzchang Test added in monetdb5/tests/BugTracker/Tests/stdev.Bug-3178.mal test results are different from spreadsheet results ## Comment 18162 Date: 2012-11-27 17:42:30 +0100 From: Yin &lt;<yinhqiao>&gt; Adding a test is definitely very helpful. In the spreadsheet you used for the result comparison, what kind of estimator is used, unbiased or biased? The original implementation in MonetDB (or the proposed one scan implementation) is the population variance of a finite population of size N, that is different from that of unbiased sample variance. Please see the link for the definition: http://en.wikipedia.org/wiki/Variance For a large sample size (a large value of N), the difference should not be significant. ## Comment 18187 Date: 2012-11-28 13:44:59 +0100 From: @yzchang Changeset [19a439c07ec9](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=19a439c07ec9) made by Jennie Zhang <y.zhang@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=19a439c07ec9](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=19a439c07ec9) Changeset description: Added test for Bug #3178 ## Comment 18219 Date: 2012-11-29 10:54:04 +0100 From: @sjoerdmullender Changeset [bfb1f607de02](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=bfb1f607de02) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=bfb1f607de02](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=bfb1f607de02) Changeset description: Implemented standard deviation (sample and population) in single scan. This implementation is currently not yet used by SQL. See bug #3178. ## Comment 18450 Date: 2013-01-29 14:47:50 +0100 From: @sjoerdmullender Since changeset [498738535dfe](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=498738535dfe) the single scan implementation is used for the stddev_samp and stddev_pop (and var_samp and var_pop) aggregates in SQL. ## Comment 18507 Date: 2013-02-19 13:17:56 +0100 From: @sjoerdmullender Feb2013 has been released.
one scan is enough to implement ALGstdev_@1 in monetdb5/modules/kernel/algebra.mx
https://api.github.com/repos/MonetDB/MonetDB/issues/3178/comments
0
2020-11-30T12:14:50Z
2024-06-27T11:58:03Z
https://github.com/MonetDB/MonetDB/issues/3178
753,428,343
3,178
[ "MonetDB", "MonetDB" ]
Date: 2012-11-06 20:58:23 +0100 From: Yin &lt;<yinhqiao>&gt; To: MonetDB5 devs &lt;<bugs-monetdb5>&gt; Version: -- development CC: @yzchang Last updated: 2012-11-27 11:47:29 +0100 ## Comment 17879 Date: 2012-11-06 20:58:23 +0100 From: Yin &lt;<yinhqiao>&gt; User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:2.0) Gecko/20100101 Firefox/4.0 Build Identifier: configure option used: configure --enable-optimize --enable-crackers --enable-jdbc when make, it failed with the following messages: cc1: warnings being treated as errors /home/yinhe/stdev/monetdb5/optimizer/opt_mitosis.c: In function ‘OPTmitosisImplementation’: /home/yinhe/stdev/monetdb5/optimizer/opt_mitosis.c:141:20: error: ‘rtpe’ may be used uninitialized in this function Reproducible: Always ### Steps to Reproduce: 1. bootstrap 2. configure --enable-optimize --enable-crackers --enable-jdbc 3. make ### Actual Results: when make, it failed with the following messages: cc1: warnings being treated as errors /home/yinhe/stdev/monetdb5/optimizer/opt_mitosis.c: In function ‘OPTmitosisImplementation’: /home/yinhe/stdev/monetdb5/optimizer/opt_mitosis.c:141:20: error: ‘rtpe’ may be used uninitialized in this function ### Expected Results: compile successful Fix available with the diff: --- a/monetdb5/optimizer/opt_mitosis.c Tue Nov 06 12:42:05 2012 +0100 +++ b/monetdb5/optimizer/opt_mitosis.c Tue Nov 06 11:53:11 2012 -0800 @@ -138,7 +138,7 @@ schema = getVarConstant(mb, getArg(target,2)).val.sval; table = getVarConstant(mb, getArg(target,3)).val.sval; for(i=0;i<limit;i++){ - int upd=0, qtpe, rtpe, qv, rv; + int upd, qtpe, rtpe, qv, rv = 0; InstrPtr matq, matr = NULL; p= old[i]; ## Comment 17880 Date: 2012-11-06 22:06:21 +0100 From: @grobian said commit is on development branch ## Comment 17921 Date: 2012-11-08 14:08:30 +0100 From: @grobian Not giving upd a default is wrong, because it's used uninitialised then lateron. ## Comment 17922 Date: 2012-11-08 14:09:30 +0100 From: @grobian Changeset [55231afa24fc](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=55231afa24fc) made by Fabian Groffen <fabian@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=55231afa24fc](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=55231afa24fc) Changeset description: OPTmitosisImplementation: ‘rtpe’ may be used uninitialized in this function http://monetdb.cwi.nl/testweb/logs/45838:179d5960abe9/GNU-Darwin-powerpc/make.htmll958 fixes bug #3177 ## Comment 18036 Date: 2012-11-27 11:47:29 +0100 From: @yzchang Compilation issue
changeset: 45833:c70a21e6200e failed to compile on ubuntu natty when cc1: warnings being treated as errors
https://api.github.com/repos/MonetDB/MonetDB/issues/3177/comments
0
2020-11-30T12:14:48Z
2024-06-27T11:58:02Z
https://github.com/MonetDB/MonetDB/issues/3177
753,428,323
3,177
[ "MonetDB", "MonetDB" ]
Date: 2012-11-05 11:30:23 +0100 From: matthieu.guamis To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.3 (Oct2012) CC: matthieu.guamis, meduri, @mlkersten, @drstmane Last updated: 2013-01-22 09:29:11 +0100 ## Comment 17876 Date: 2012-11-05 11:30:23 +0100 From: matthieu.guamis User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:16.0) Gecko/20100101 Firefox/16.0 Build Identifier: Same query, different results Running the same query on the same data leeds to different results. select temps_mois.rfoperyea as c0, sum((case when dwhinv.dwhinv___rfodomide = 'PMSI' and dwhinv.dwhinv___rfoindide = 'recN1_entrees_reel' then dwhinv.dwhinvqte else 0 end)) as m0 from rfoper_temps_mois as temps_mois, dwhinv as dwhinv where temps_mois.rfoper___rforefide = dwhinv.dwhinv___rforefide and dwhinv.dwhinv___rforefide = 'CHCL' and dwhinv.dwhinv___rfodomide = 'PMSI' and dwhinv.dwhinv___rfoindide = 'recN1_entrees_reel' and dwhinv.dwhinvdtd = temps_mois.rfoperdtd group by c0 order by c0 +------+----------------------+ | c0 | m0 | +======+======================+ | 2009 | 14691.000000 | | 2010 | 8454.000000 | +------+----------------------+ 2 tuples (44.973ms) Here is the explain out: +------------------------------------------------------------------------------------------------+ | mal | +================================================================================================+ | function user.s7_3{autoCommit=true}(A0:str,A1:str,A2:bte,A3:str,A4:str,A5:str):void; | | X_167 := nil:bat[:oid,:str]; | | X_205 := nil:bat[:oid,:lng]; | | barrier X_311 := language.dataflow(); | | X_8 := sql.mvc(); | | X_9:bat[:oid,:str] := sql.bind(X_8,"axabas","rfoper_temps_mois","rfoper___rforefide",0); | | X_14:bat[:oid,:str] := sql.bind(X_8,"axabas","rfoper_temps_mois","rfoper___rforefide",2); | | X_16 := algebra.kdifference(X_9,X_14); | | X_17 := algebra.kunion(X_16,X_14); | | X_18:bat[:oid,:str] := sql.bind(X_8,"axabas","rfoper_temps_mois","rfoper___rforefide",1); | | X_20 := algebra.kunion(X_17,X_18); | | X_21:bat[:oid,:oid] := sql.bind_dbat(X_8,"axabas","rfoper_temps_mois",1); | | X_22 := bat.reverse(X_21); | | X_23 := algebra.kdifference(X_20,X_22); | | X_24 := algebra.markT(X_23,40@0:oid); | | X_25 := bat.reverse(X_23); | | X_26 := algebra.markT(X_25,40@0:oid); | | X_27 := bat.reverse(X_26); | | X_28:bat[:oid,:wrd] := batcalc.hash(X_27); | | X_29 := bat.reverse(X_24); | | X_30:bat[:oid,:timestamp] := sql.bind(X_8,"axabas","rfoper_temps_mois","rfoperdtd",0); | | X_32:bat[:oid,:timestamp] := sql.bind(X_8,"axabas","rfoper_temps_mois","rfoperdtd",2); | | X_35 := algebra.kdifference(X_30,X_32); | | X_36 := algebra.kunion(X_35,X_32); | | X_37:bat[:oid,:timestamp] := sql.bind(X_8,"axabas","rfoper_temps_mois","rfoperdtd",1); | | X_38 := algebra.kunion(X_36,X_37); | | X_39 := algebra.leftjoin(X_29,X_38); | | X_40:bat[:oid,:wrd] := mkey.bulk_rotate_xor_hash(X_28,22:int,X_39); | | X_41:bat[:oid,:str] := sql.bind(X_8,"axabas","dwhinv","dwhinv___rforefide",0); | | X_45:bat[:oid,:str] := sql.bind(X_8,"axabas","dwhinv","dwhinv___rforefide",2); | | X_47 := algebra.kdifference(X_41,X_45); | | X_48 := algebra.kunion(X_47,X_45); | | X_49:bat[:oid,:str] := sql.bind(X_8,"axabas","dwhinv","dwhinv___rforefide",1); | | X_51 := algebra.kunion(X_48,X_49); | | X_52:bat[:oid,:oid] := sql.bind_dbat(X_8,"axabas","dwhinv",1); | | X_53 := bat.reverse(X_52); | | X_54 := algebra.kdifference(X_51,X_53); | | X_55:bat[:oid,:str] := sql.bind(X_8,"axabas","dwhinv","dwhinv___rfodomide",0); | | X_57:bat[:oid,:str] := sql.bind(X_8,"axabas","dwhinv","dwhinv___rfodomide",2); | | X_58 := algebra.kdifference(X_55,X_57); | | X_59 := algebra.kunion(X_58,X_57); | | X_60:bat[:oid,:str] := sql.bind(X_8,"axabas","dwhinv","dwhinv___rfodomide",1); | | X_61 := algebra.kunion(X_59,X_60); | | X_62 := algebra.kdifference(X_61,X_53); | | X_63:bat[:oid,:str] := sql.bind(X_8,"axabas","dwhinv","dwhinv___rfoindide",0); | | X_66 := algebra.uselect(X_63,A5); | | X_67:bat[:oid,:str] := sql.bind(X_8,"axabas","dwhinv","dwhinv___rfoindide",2); | | X_68 := algebra.kdifference(X_66,X_67); | | X_69 := algebra.uselect(X_67,A5); | | X_70 := algebra.kunion(X_68,X_69); | | X_71:bat[:oid,:str] := sql.bind(X_8,"axabas","dwhinv","dwhinv___rfoindide",1); | | X_73 := algebra.uselect(X_71,A5); | | X_74 := algebra.kunion(X_70,X_73); | | X_75 := algebra.kdifference(X_74,X_53); | | X_76 := algebra.semijoin(X_62,X_75); | | X_77 := algebra.uselect(X_76,A4); | | X_78 := algebra.kdifference(X_77,X_57); | | X_79 := algebra.semijoin(X_57,X_75); | | X_80 := algebra.uselect(X_79,A4); | | X_81 := algebra.kunion(X_78,X_80); | | X_82 := algebra.semijoin(X_60,X_75); | | X_83 := algebra.uselect(X_82,A4); | | X_84 := algebra.kunion(X_81,X_83); | | X_85 := algebra.kdifference(X_84,X_53); | | X_86 := algebra.semijoin(X_54,X_85); | | X_87 := algebra.uselect(X_86,A3); | | X_88 := algebra.kdifference(X_87,X_45); | | X_89 := algebra.semijoin(X_45,X_85); | | X_90 := algebra.uselect(X_89,A3); | | X_91 := algebra.kunion(X_88,X_90); | | X_92 := algebra.semijoin(X_49,X_85); | | X_93 := algebra.uselect(X_92,A3); | | X_94 := algebra.kunion(X_91,X_93); | | X_95 := algebra.kdifference(X_94,X_53); | | X_96 := algebra.markT(X_95,0@0:oid); | | X_97 := bat.reverse(X_96); | | X_98 := algebra.kdifference(X_54,X_45); | | X_99 := algebra.kunion(X_98,X_45); | | X_100 := algebra.kunion(X_99,X_49); | | X_101 := algebra.leftjoin(X_97,X_100); | | X_102 := algebra.markT(X_101,40@0:oid); | | X_103 := bat.reverse(X_101); | | X_104 := algebra.markT(X_103,40@0:oid); | | X_105 := bat.reverse(X_104); | | X_106:bat[:oid,:wrd] := batcalc.hash(X_105); | | X_107 := bat.reverse(X_102); | | X_108:bat[:oid,:timestamp] := sql.bind(X_8,"axabas","dwhinv","dwhinvdtd",0); | | X_113:bat[:oid,:timestamp] := sql.bind(X_8,"axabas","dwhinv","dwhinvdtd",2); | | X_115 := algebra.kdifference(X_108,X_113); | | X_116 := algebra.kunion(X_115,X_113); | | X_117:bat[:oid,:timestamp] := sql.bind(X_8,"axabas","dwhinv","dwhinvdtd",1); | | X_119 := algebra.kunion(X_116,X_117); | | X_120 := algebra.leftjoin(X_97,X_119); | | X_121 := algebra.leftjoin(X_107,X_120); | | X_122:bat[:oid,:wrd] := mkey.bulk_rotate_xor_hash(X_106,22:int,X_121); | | X_123 := algebra.join(X_102,X_122); | | X_124 := bat.reverse(X_123); | | X_125:bat[:oid,:oid] := algebra.joinPath(X_24,X_40,X_124); | | X_129 := bat.reverse(X_125); | | X_130 := algebra.markT(X_129,4@0:oid); | | X_131 := bat.reverse(X_130); | | X_126 := algebra.markT(X_125,4@0:oid); | | X_127 := bat.reverse(X_126); | | X_128 := algebra.leftjoin(X_127,X_20); | | X_132 := algebra.leftjoin(X_131,X_101); | | X_133:bat[:oid,:bit] := batcalc.==(X_128,X_132); | | X_134 := algebra.uselect(X_133,true:bit); | | X_137 := algebra.semijoin(X_131,X_134); | | X_138 := algebra.leftjoin(X_137,X_120); | | X_135 := algebra.semijoin(X_127,X_134); | | X_136 := algebra.leftjoin(X_135,X_38); | | X_139:bat[:oid,:bit] := batcalc.==(X_136,X_138); | | X_140 := algebra.uselect(X_139,true:bit); | | X_141 := algebra.semijoin(X_135,X_140); | | X_142 := bat.reverse(X_141); | | X_143 := algebra.semijoin(X_137,X_140); | | X_144 := algebra.join(X_142,X_143); | | X_145 := algebra.markT(X_144,0@0:oid); | | X_146 := bat.reverse(X_145); | | X_147:bat[:oid,:str] := sql.bind(X_8,"axabas","rfoper_temps_mois","rfoperyea",0); | | X_152:bat[:oid,:str] := sql.bind(X_8,"axabas","rfoper_temps_mois","rfoperyea",2); | | X_154 := algebra.kdifference(X_147,X_152); | | X_155 := algebra.kunion(X_154,X_152); | | X_156:bat[:oid,:str] := sql.bind(X_8,"axabas","rfoper_temps_mois","rfoperyea",1); | | X_158 := algebra.kunion(X_155,X_156); | | X_159 := algebra.leftjoin(X_146,X_158); | | (ext265,grp263) := group.done(X_159); | | X_162 := bat.mirror(ext265); | | X_163 := algebra.join(X_162,X_159); | | X_168 := bat.reverse(X_144); | | X_169 := algebra.markT(X_168,0@0:oid); | | X_170 := bat.reverse(X_169); | | X_310 := algebra.leftjoin(X_170,X_97); | | X_171 := algebra.kdifference(X_62,X_57); | | X_172 := algebra.kunion(X_171,X_57); | | X_173 := algebra.kunion(X_172,X_60); | | X_174:bat[:oid,:str] := algebra.leftjoin(X_310,X_173); | | X_176:bat[:oid,:bit] := batcalc.==(X_174,A0); | | X_177 := algebra.kdifference(X_63,X_67); | | X_178 := algebra.kunion(X_177,X_67); | | X_179 := algebra.kunion(X_178,X_71); | | X_180:bat[:oid,:str] := algebra.leftjoin(X_310,X_179); | | X_181:bat[:oid,:bit] := batcalc.==(X_180,A1); | | X_185:bat[:oid,:lng] := sql.bind(X_8,"axabas","dwhinv","dwhinvqte",0); | | X_189:bat[:oid,:lng] := sql.bind(X_8,"axabas","dwhinv","dwhinvqte",2); | | X_192 := algebra.kdifference(X_185,X_189); | | X_193 := algebra.kunion(X_192,X_189); | | X_194:bat[:oid,:lng] := sql.bind(X_8,"axabas","dwhinv","dwhinvqte",1); | | X_196 := algebra.kunion(X_193,X_194); | | X_197:bat[:oid,:lng] := algebra.leftjoin(X_310,X_196); | | X_182:bat[:oid,:bit] := batcalc.and(X_176,X_181); | | X_183:bat[:oid,:bit] := batcalc.isnil(X_182); | | X_184:bat[:oid,:bit] := batcalc.ifthenelse(X_183,false:bit,X_182); | | X_198 := calc.lng(A2,18,6); | | X_201:bat[:oid,:lng] := batcalc.ifthenelse(X_184,X_197,X_198); | | X_202 := algebra.selectNotNil(X_201); | | X_203:bat[:oid,:lng] := aggr.sum(X_202,grp263,X_162); | | X_164 := algebra.sortTail(X_163); | | X_165 := algebra.markT(X_164,0@0:oid); | | X_166 := bat.reverse(X_165); | | X_167 := algebra.leftjoin(X_166,X_163); | | X_205 := algebra.leftjoin(X_166,X_203); | | exit X_311; | | X_206 := sql.resultSet(2,1,X_167); | | sql.rsColumn(X_206,"axabas.temps_mois","c0","varchar",32,0,X_167); | | sql.rsColumn(X_206,"axabas.","m0","decimal",18,6,X_205); | | X_216 := io.stdout(); | | sql.exportResult(X_216,X_206); | | end s7_3; | +------------------------------------------------------------------------------------------------+ 169 tuples (22.405ms) Replacing where clause "emps_mois.rfoper___rforefide = dwhinv.dwhinv___rforefide" by "temps_mois.rfoper___rforefide = 'CHCL'" which is the same because of the "dwhinv.dwhinv___rforefide = 'CHCL'": select temps_mois.rfoperyea as c0, sum((case when dwhinv.dwhinv___rfodomide = 'PMSI' and dwhinv.dwhinv___rfoindide = 'recN1_entrees_reel' then dwhinv.dwhinvqte else 0 end)) as m0 from rfoper_temps_mois as temps_mois, dwhinv as dwhinv where temps_mois.rfoper___rforefide = 'CHCL' and -- OLD line: temps_mois.rfoper___rforefide = dwhinv.dwhinv___rforefide and dwhinv.dwhinv___rforefide = 'CHCL' and dwhinv.dwhinv___rfodomide = 'PMSI' and dwhinv.dwhinv___rfoindide = 'recN1_entrees_reel' and dwhinv.dwhinvdtd = temps_mois.rfoperdtd group by c0 order by c0 +------+----------------------+ | c0 | m0 | +======+======================+ | 2009 | 1.000000 | | 2010 | 1.000000 | +------+----------------------+ 2 tuples (31.901ms) Here is the explain out: +------------------------------------------------------------------------------------------------+ | mal | +================================================================================================+ | function user.s5_3{autoCommit=true}(A0:str,A1:str,A2:bte,A3:str,A4:str,A5:str,A6:str):void; | | X_86 := nil:bat[:oid,:str]; | | X_108 := nil:bat[:oid,:lng]; | | barrier X_427 := language.dataflow(); | | X_9 := sql.mvc(); | | X_151:bat[:oid,:str] := sql.bind(X_9,"axabas","dwhinv","dwhinv___rforefide",0,0,2); | | X_158:bat[:oid,:str] := sql.bind(X_9,"axabas","dwhinv","dwhinv___rforefide",2,0,2); | | X_187 := algebra.kdifference(X_151,X_158); | | X_189 := algebra.kunion(X_187,X_158); | | X_17:bat[:oid,:oid] := sql.bind_dbat(X_9,"axabas","dwhinv",1); | | X_18 := bat.reverse(X_17); | | X_192 := algebra.kdifference(X_189,X_18); | | X_160:bat[:oid,:str] := sql.bind(X_9,"axabas","dwhinv","dwhinv___rfodomide",0,0,2); | | X_163:bat[:oid,:str] := sql.bind(X_9,"axabas","dwhinv","dwhinv___rfodomide",2,0,2); | | X_195 := algebra.kdifference(X_160,X_163); | | X_197 := algebra.kunion(X_195,X_163); | | X_199 := algebra.kdifference(X_197,X_18); | | X_165:bat[:oid,:str] := sql.bind(X_9,"axabas","dwhinv","dwhinv___rfoindide",0,0,2); | | X_202 := algebra.uselect(X_165,A6); | | X_168:bat[:oid,:str] := sql.bind(X_9,"axabas","dwhinv","dwhinv___rfoindide",2,0,2); | | X_204 := algebra.kdifference(X_202,X_168); | | X_206 := algebra.uselect(X_168,A6); | | X_208 := algebra.kunion(X_204,X_206); | | X_212 := algebra.kdifference(X_208,X_18); | | X_216 := algebra.semijoin(X_199,X_212); | | X_220 := algebra.uselect(X_216,A5); | | X_223 := algebra.kdifference(X_220,X_163); | | X_225 := algebra.semijoin(X_163,X_212); | | X_229 := algebra.uselect(X_225,A5); | | X_232 := algebra.kunion(X_223,X_229); | | X_235 := algebra.kdifference(X_232,X_18); | | X_240 := algebra.semijoin(X_192,X_235); | | X_243 := algebra.uselect(X_240,A4); | | X_248 := algebra.kdifference(X_243,X_158); | | X_252 := algebra.semijoin(X_158,X_235); | | X_254 := algebra.uselect(X_252,A4); | | X_256 := algebra.kunion(X_248,X_254); | | X_261 := algebra.kdifference(X_256,X_18); | | X_266 := algebra.markT(X_261,4,0); | | X_279 := bat.reverse(X_266); | | X_170:bat[:oid,:timestamp] := sql.bind(X_9,"axabas","dwhinv","dwhinvdtd",0,0,2); | | X_174:bat[:oid,:timestamp] := sql.bind(X_9,"axabas","dwhinv","dwhinvdtd",2,0,2); | | X_286 := algebra.kdifference(X_170,X_174); | | X_288 := algebra.kunion(X_286,X_174); | | X_290 := algebra.leftjoin(X_279,X_288); | | X_40:bat[:oid,:str] := sql.bind(X_9,"axabas","rfoper_temps_mois","rfoper___rforefide",0); | | X_43 := algebra.uselect(X_40,A3); | | X_44:bat[:oid,:str] := sql.bind(X_9,"axabas","rfoper_temps_mois","rfoper___rforefide",2); | | X_45 := algebra.kdifference(X_43,X_44); | | X_46 := algebra.uselect(X_44,A3); | | X_47 := algebra.kunion(X_45,X_46); | | X_48:bat[:oid,:str] := sql.bind(X_9,"axabas","rfoper_temps_mois","rfoper___rforefide",1); | | X_49 := algebra.uselect(X_48,A3); | | X_50 := algebra.kunion(X_47,X_49); | | X_51:bat[:oid,:oid] := sql.bind_dbat(X_9,"axabas","rfoper_temps_mois",1); | | X_53 := bat.reverse(X_51); | | X_54 := algebra.kdifference(X_50,X_53); | | X_55 := algebra.markT(X_54,0@0:oid); | | X_56 := bat.reverse(X_55); | | X_57:bat[:oid,:timestamp] := sql.bind(X_9,"axabas","rfoper_temps_mois","rfoperdtd",0); | | X_60:bat[:oid,:timestamp] := sql.bind(X_9,"axabas","rfoper_temps_mois","rfoperdtd",2); | | X_62 := algebra.kdifference(X_57,X_60); | | X_63 := algebra.kunion(X_62,X_60); | | X_64:bat[:oid,:timestamp] := sql.bind(X_9,"axabas","rfoper_temps_mois","rfoperdtd",1); | | X_66 := algebra.kunion(X_63,X_64); | | X_67 := algebra.leftjoin(X_56,X_66); | | X_68 := bat.reverse(X_67); | | X_297 := algebra.join(X_290,X_68); | | X_301 := bat.reverse(X_297); | | X_308 := algebra.markT(X_301,4,0); | | X_319 := bat.reverse(X_308); | | X_69:bat[:oid,:str] := sql.bind(X_9,"axabas","rfoper_temps_mois","rfoperyea",0); | | X_72:bat[:oid,:str] := sql.bind(X_9,"axabas","rfoper_temps_mois","rfoperyea",2); | | X_73 := algebra.kdifference(X_69,X_72); | | X_74 := algebra.kunion(X_73,X_72); | | X_75:bat[:oid,:str] := sql.bind(X_9,"axabas","rfoper_temps_mois","rfoperyea",1); | | X_77 := algebra.kunion(X_74,X_75); | | X_78 := algebra.leftjoin(X_56,X_77); | | X_323 := algebra.leftjoin(X_319,X_78); | | (X_327,X_328) := group.done(X_323); | | X_335 := bat.mirror(X_327); | | X_337 := algebra.leftjoin(X_335,X_323); | | X_156:bat[:oid,:str] := sql.bind(X_9,"axabas","dwhinv","dwhinv___rforefide",0,1,2); | | X_159:bat[:oid,:str] := sql.bind(X_9,"axabas","dwhinv","dwhinv___rforefide",2,1,2); | | X_188 := algebra.kdifference(X_156,X_159); | | X_190 := algebra.kunion(X_188,X_159); | | X_193 := algebra.kdifference(X_190,X_18); | | X_162:bat[:oid,:str] := sql.bind(X_9,"axabas","dwhinv","dwhinv___rfodomide",0,1,2); | | X_164:bat[:oid,:str] := sql.bind(X_9,"axabas","dwhinv","dwhinv___rfodomide",2,1,2); | | X_196 := algebra.kdifference(X_162,X_164); | | X_198 := algebra.kunion(X_196,X_164); | | X_200 := algebra.kdifference(X_198,X_18); | | X_167:bat[:oid,:str] := sql.bind(X_9,"axabas","dwhinv","dwhinv___rfoindide",0,1,2); | | X_203 := algebra.uselect(X_167,A6); | | X_169:bat[:oid,:str] := sql.bind(X_9,"axabas","dwhinv","dwhinv___rfoindide",2,1,2); | | X_205 := algebra.kdifference(X_203,X_169); | | X_207 := algebra.uselect(X_169,A6); | | X_211 := algebra.kunion(X_205,X_207); | | X_213 := algebra.kdifference(X_211,X_18); | | X_217 := algebra.semijoin(X_200,X_213); | | X_221 := algebra.uselect(X_217,A5); | | X_224 := algebra.kdifference(X_221,X_164); | | X_228 := algebra.semijoin(X_164,X_213); | | X_230 := algebra.uselect(X_228,A5); | | X_233 := algebra.kunion(X_224,X_230); | | X_236 := algebra.kdifference(X_233,X_18); | | X_241 := algebra.semijoin(X_193,X_236); | | X_246 := algebra.uselect(X_241,A4); | | X_249 := algebra.kdifference(X_246,X_159); | | X_253 := algebra.semijoin(X_159,X_236); | | X_255 := algebra.uselect(X_253,A4); | | X_257 := algebra.kunion(X_249,X_255); | | X_262 := algebra.kdifference(X_257,X_18); | | X_270 := algebra.markT(X_262,4,1); | | X_282 := bat.reverse(X_270); | | X_172:bat[:oid,:timestamp] := sql.bind(X_9,"axabas","dwhinv","dwhinvdtd",0,1,2); | | X_175:bat[:oid,:timestamp] := sql.bind(X_9,"axabas","dwhinv","dwhinvdtd",2,1,2); | | X_287 := algebra.kdifference(X_172,X_175); | | X_289 := algebra.kunion(X_287,X_175); | | X_291 := algebra.leftjoin(X_282,X_289); | | X_298 := algebra.join(X_291,X_68); | | X_303 := bat.reverse(X_298); | | X_312 := algebra.markT(X_303,4,1); | | X_320 := bat.reverse(X_312); | | X_324 := algebra.leftjoin(X_320,X_78); | | (X_329,X_330) := group.done(X_324); | | X_338 := bat.mirror(X_329); | | X_340 := algebra.leftjoin(X_338,X_324); | | X_15:bat[:oid,:str] := sql.bind(X_9,"axabas","dwhinv","dwhinv___rforefide",1); | | X_194 := algebra.kdifference(X_15,X_18); | | X_20:bat[:oid,:str] := sql.bind(X_9,"axabas","dwhinv","dwhinv___rfodomide",1); | | X_201 := algebra.kdifference(X_20,X_18); | | X_22:bat[:oid,:str] := sql.bind(X_9,"axabas","dwhinv","dwhinv___rfoindide",1); | | X_25 := algebra.uselect(X_22,A6); | | X_215 := algebra.kdifference(X_25,X_18); | | X_218 := algebra.semijoin(X_201,X_215); | | X_222 := algebra.uselect(X_218,A5); | | X_237 := algebra.kdifference(X_222,X_18); | | X_26 := mat.pack(X_212,X_213,X_215); | | X_27 := algebra.semijoin(X_20,X_26); | | X_28 := algebra.uselect(X_27,A5); | | X_238 := algebra.kdifference(X_28,X_18); | | X_239 := algebra.kunion(X_237,X_238); | | X_242 := algebra.semijoin(X_194,X_239); | | X_247 := algebra.uselect(X_242,A4); | | X_263 := algebra.kdifference(X_247,X_18); | | X_273 := algebra.markT(X_263,4,2); | | X_283 := bat.reverse(X_273); | | X_37:bat[:oid,:timestamp] := sql.bind(X_9,"axabas","dwhinv","dwhinvdtd",1); | | X_292 := algebra.leftjoin(X_283,X_37); | | X_299 := algebra.join(X_292,X_68); | | X_305 := bat.reverse(X_299); | | X_314 := algebra.markT(X_305,4,2); | | X_321 := bat.reverse(X_314); | | X_325 := algebra.leftjoin(X_321,X_78); | | (X_331,X_332) := group.done(X_325); | | X_341 := bat.mirror(X_331); | | X_343 := algebra.leftjoin(X_341,X_325); | | X_30 := mat.pack(X_235,X_236,X_237,X_238); | | X_31 := algebra.semijoin(X_15,X_30); | | X_32 := algebra.uselect(X_31,A4); | | X_265 := algebra.kdifference(X_32,X_18); | | X_276 := algebra.markT(X_265,4,3); | | X_285 := bat.reverse(X_276); | | X_293 := algebra.leftjoin(X_285,X_37); | | X_300 := algebra.join(X_293,X_68); | | X_307 := bat.reverse(X_300); | | X_316 := algebra.markT(X_307,4,3); | | X_322 := bat.reverse(X_316); | | X_326 := algebra.leftjoin(X_322,X_78); | | (X_333,X_334) := group.done(X_326); | | X_344 := bat.mirror(X_333); | | X_345 := algebra.leftjoin(X_344,X_326); | | X_346 := mat.pack(X_337,X_340,X_343,X_345); | | (ext208,grp206) := group.done(X_346); | | X_81 := bat.mirror(ext208); | | X_350 := algebra.join(X_81,X_323); | | X_351 := algebra.join(X_81,X_324); | | X_352 := algebra.join(X_81,X_325); | | X_353 := algebra.join(X_81,X_326); | | X_349 := mat.pack(X_350,X_351,X_352,X_353); | | X_82 := algebra.join(X_81,X_349); | | X_355 := algebra.markT(X_297,4,0); | | X_364 := bat.reverse(X_355); | | X_423 := algebra.leftjoin(X_364,X_279); | | X_371 := algebra.kdifference(X_199,X_163); | | X_375 := algebra.kunion(X_371,X_163); | | X_379:bat[:oid,:str] := algebra.leftjoin(X_423,X_375); | | X_385 := batcalc.==(X_379,A0); | | X_391 := algebra.kdifference(X_165,X_168); | | X_393 := algebra.kunion(X_391,X_168); | | X_398:bat[:oid,:str] := algebra.leftjoin(X_423,X_393); | | X_403 := batcalc.==(X_398,A1); | | X_176:bat[:oid,:lng] := sql.bind(X_9,"axabas","dwhinv","dwhinvqte",0,0,2); | | X_181:bat[:oid,:lng] := sql.bind(X_9,"axabas","dwhinv","dwhinvqte",2,0,2); | | X_408 := algebra.kdifference(X_176,X_181); | | X_412 := algebra.kunion(X_408,X_181); | | X_417:bat[:oid,:lng] := algebra.leftjoin(X_423,X_412); | | X_358 := algebra.markT(X_298,4,1); | | X_366 := bat.reverse(X_358); | | X_424 := algebra.leftjoin(X_366,X_282); | | X_373 := algebra.kdifference(X_200,X_164); | | X_377 := algebra.kunion(X_373,X_164); | | X_380:bat[:oid,:str] := algebra.leftjoin(X_424,X_377); | | X_386 := batcalc.==(X_380,A0); | | X_392 := algebra.kdifference(X_167,X_169); | | X_394 := algebra.kunion(X_392,X_169); | | X_400:bat[:oid,:str] := algebra.leftjoin(X_424,X_394); | | X_404 := batcalc.==(X_400,A1); | | X_178:bat[:oid,:lng] := sql.bind(X_9,"axabas","dwhinv","dwhinvqte",0,1,2); | | X_185:bat[:oid,:lng] := sql.bind(X_9,"axabas","dwhinv","dwhinvqte",2,1,2); | | X_410 := algebra.kdifference(X_178,X_185); | | X_413 := algebra.kunion(X_410,X_185); | | X_419:bat[:oid,:lng] := algebra.leftjoin(X_424,X_413); | | X_360 := algebra.markT(X_299,4,2); | | X_368 := bat.reverse(X_360); | | X_425 := algebra.leftjoin(X_368,X_283); | | X_381:bat[:oid,:str] := algebra.leftjoin(X_425,X_201); | | X_387 := batcalc.==(X_381,A0); | | X_382:bat[:oid,:str] := algebra.leftjoin(X_425,X_20); | | X_388 := batcalc.==(X_382,A0); | | X_401:bat[:oid,:str] := algebra.leftjoin(X_425,X_22); | | X_405 := batcalc.==(X_401,A1); | | X_98:bat[:oid,:lng] := sql.bind(X_9,"axabas","dwhinv","dwhinvqte",1); | | X_420:bat[:oid,:lng] := algebra.leftjoin(X_425,X_98); | | X_362 := algebra.markT(X_300,4,3); | | X_370 := bat.reverse(X_362); | | X_426 := algebra.leftjoin(X_370,X_285); | | X_383:bat[:oid,:str] := algebra.leftjoin(X_426,X_201); | | X_389 := batcalc.==(X_383,A0); | | X_384:bat[:oid,:str] := algebra.leftjoin(X_426,X_20); | | X_390 := batcalc.==(X_384,A0); | | X_402:bat[:oid,:str] := algebra.leftjoin(X_426,X_22); | | X_406 := batcalc.==(X_402,A1); | | X_421:bat[:oid,:lng] := algebra.leftjoin(X_426,X_98); | | X_100 := mat.pack(X_417,X_419,X_420,X_421); | | X_88:bat[:oid,:bit] := mat.pack(X_385,X_386,X_387,X_388,X_389,X_390); | | X_89:bat[:oid,:bit] := mat.pack(X_403,X_404,X_405,X_406); | | X_90:bat[:oid,:bit] := batcalc.and(X_88,X_89); | | X_91:bat[:oid,:bit] := batcalc.isnil(X_90); | | X_92:bat[:oid,:bit] := batcalc.ifthenelse(X_91,false:bit,X_90); | | X_101 := calc.lng(A2,18,6); | | X_104:bat[:oid,:lng] := batcalc.ifthenelse(X_92,X_100,X_101); | | X_105 := algebra.selectNotNil(X_104); | | X_106:bat[:oid,:lng] := aggr.sum(X_105,grp206,X_81); | | X_83 := algebra.sortTail(X_82); | | X_84 := algebra.markT(X_83,0@0:oid); | | X_85 := bat.reverse(X_84); | | X_86 := algebra.leftjoin(X_85,X_82); | | X_108 := algebra.leftjoin(X_85,X_106); | | exit X_427; | | X_109 := sql.resultSet(2,1,X_86); | | sql.rsColumn(X_109,"axabas.temps_mois","c0","varchar",32,0,X_86); | | sql.rsColumn(X_109,"axabas.","m0","decimal",18,6,X_108); | | X_119 := io.stdout(); | | sql.exportResult(X_119,X_109); | | end s5_3; | +------------------------------------------------------------------------------------------------+ 257 tuples (26.460ms) Do you admaxg@monetdb:~$ mclient --version mclient, the MonetDB interactive terminal (Jul2012-SP2) support for command-line editing compiled-in character encoding: UTF-8 admaxg@monetdb:~$ monetdb version MonetDB Database Server Toolkit v1.0 (Jul2012-SP2) admaxg@monetdb:~$ monetdbd version MonetDB Database Server v1.6 (Jul2012-SP2) admaxg@monetdb:~$ cat /etc/lsb-release DISTRIB_ID=Ubuntu DISTRIB_RELEASE=12.04 DISTRIB_CODENAME=precise DISTRIB_DESCRIPTION="Ubuntu 12.04.1 LTS" Reproducible: Always ### Steps to Reproduce: I am trying to build a simple test case without success for now ### Actual Results: +------+----------------------+ | c0 | m0 | +======+======================+ | 2009 | 1.000000 | | 2010 | 1.000000 | +------+----------------------+ ### Expected Results: +------+----------------------+ | c0 | m0 | +======+======================+ | 2009 | 14691.000000 | | 2010 | 8454.000000 | +------+----------------------+ Postgresql 9.1 computes the same result for this queries ## Comment 17878 Date: 2012-11-06 10:25:12 +0100 From: matthieu.guamis Here is the dump with the two tables to reproduce the problem: http://ubuntuone.com/1LuEvyOcu2XtislVYpuM3g Those two queries must have the same result but only the first works as expected. select temps_mois.rfoperyea as c0, sum((case when dwhinv.dwhinv___rfodomide = 'PMSI' and dwhinv.dwhinv___rfoindide = 'recN1_entrees_reel' then dwhinv.dwhinvqte else 0 end)) as m0 from rfoper_temps_mois as temps_mois, dwhinv as dwhinv where temps_mois.rfoper___rforefide = dwhinv.dwhinv___rforefide and dwhinv.dwhinv___rforefide = 'CHCL' and dwhinv.dwhinv___rfodomide = 'PMSI' and dwhinv.dwhinv___rfoindide = 'recN1_entrees_reel' and dwhinv.dwhinvdtd = temps_mois.rfoperdtd group by c0 order by c0 select temps_mois.rfoperyea as c0, sum((case when dwhinv.dwhinv___rfodomide = 'PMSI' and dwhinv.dwhinv___rfoindide = 'recN1_entrees_reel' then dwhinv.dwhinvqte else 0 end)) as m0 from rfoper_temps_mois as temps_mois, dwhinv as dwhinv where temps_mois.rfoper___rforefide = 'CHCL' and dwhinv.dwhinv___rforefide = 'CHCL' and dwhinv.dwhinv___rfodomide = 'PMSI' and dwhinv.dwhinv___rfoindide = 'recN1_entrees_reel' and dwhinv.dwhinvdtd = temps_mois.rfoperdtd group by c0 order by c0 ## Comment 17923 Date: 2012-11-08 15:47:47 +0100 From: @mlkersten The problem does not appear on the default (=DEVELOPMENT) branch sql>select temps_mois.rfoperyea as c0, sum((case when dwhinv.dwhinv___rfodomide = more>'PMSI' and dwhinv.dwhinv___rfoindide = 'recN1_entrees_reel' then more>dwhinv.dwhinvqte else 0 more>end)) as m0 more> from rfoper_temps_mois as temps_mois, dwhinv as dwhinv more> where temps_mois.rfoper___rforefide = dwhinv.dwhinv___rforefide and more> dwhinv.dwhinv___rforefide = 'CHCL' and more> dwhinv.dwhinv___rfodomide = 'PMSI' and more> dwhinv.dwhinv___rfoindide = 'recN1_entrees_reel' and more> dwhinv.dwhinvdtd = temps_mois.rfoperdtd more> group by c0 order by c0 ; +------+----------------------+ | c0 | m0 | +======+======================+ | 2009 | 14691.000000 | | 2010 | 8454.000000 | +------+----------------------+ 2 tuples (36.442ms) sql>select temps_mois.rfoperyea as c0, sum((case when dwhinv.dwhinv___rfodomide = more>'PMSI' and dwhinv.dwhinv___rfoindide = 'recN1_entrees_reel' then more>dwhinv.dwhinvqte else 0 more>end)) as m0 more> from rfoper_temps_mois as temps_mois, dwhinv as dwhinv more> where temps_mois.rfoper___rforefide = 'CHCL' and more> dwhinv.dwhinv___rforefide = 'CHCL' and more> dwhinv.dwhinv___rfodomide = 'PMSI' and more> dwhinv.dwhinv___rfoindide = 'recN1_entrees_reel' and more> dwhinv.dwhinvdtd = temps_mois.rfoperdtd more> group by c0 order by c0; +------+----------------------+ | c0 | m0 | +======+======================+ | 2009 | 14691.000000 | | 2010 | 8454.000000 | +------+----------------------+ 2 tuples (31.012ms) ## Comment 17924 Date: 2012-11-08 16:38:24 +0100 From: @drstmane I suspect the bug is already in the relational plan generation / optimization in Oct2012. ## Comment 17971 Date: 2012-11-21 10:43:20 +0100 From: matthieu.guamis (In reply to comment 3) > I suspect the bug is already in the relational plan generation / optimization > in Oct2012. I tested it on Oct2012 compiled on Ubuntu 12.04 x64 and it works as expected ## Comment 18311 Date: 2012-12-27 22:19:32 +0100 From: @mlkersten I interpret your comment as a guidance to close the bug. ## Comment 18369 Date: 2013-01-22 09:29:11 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
Same query and different results
https://api.github.com/repos/MonetDB/MonetDB/issues/3176/comments
0
2020-11-30T12:14:44Z
2024-06-27T11:58:01Z
https://github.com/MonetDB/MonetDB/issues/3176
753,428,280
3,176
[ "MonetDB", "MonetDB" ]
Date: 2012-11-05 02:56:34 +0100 From: Inho Kim &lt;<georgios.kim>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.3 (Oct2012) CC: @mlkersten Last updated: 2012-11-08 05:56:56 +0100 ## Comment 17869 Date: 2012-11-05 02:56:34 +0100 From: Inho Kim &lt;<georgios.kim>&gt; User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.94 Safari/537.4 Build Identifier: there are two sql files, each file has 1,000 inserts statement. run two sql files in same time, insert statements always succeed. but result of query table is less than 2,000 rows.. Reproducible: Always ### Steps to Reproduce: 1. create table test ( id int, name varchar(20)); 2. create two sql files( test1.sql, test2.sql ) - test1.sql contains following.. insert into test values ( 1, '0001' ); .... insert into test values ( 1, '0999'); - test2.sql contains following.. insert into test values ( 2, '0001'); ... insert into test values ( 2, '0999'); 3. run sqls in same time ( with other terminal ) (terminal 1) mclient -u monetdb -d test < test1.sql (terminal 2) mclient -u monetdb -d test < test2.sql 4. query test table ### Actual Results: lost inserted rows.. sql> select count(*) from test; +------+ | L1 | +------+ | 1463 | +------+ ### Expected Results: sql> select count(*) from test; +------+ | L1 | +------+ | 2000 | +------+ ## Comment 17891 Date: 2012-11-07 18:47:52 +0100 From: @grobian did you see any errors produced by any of the clients? ## Comment 17918 Date: 2012-11-08 05:54:27 +0100 From: Inho Kim &lt;<georgios.kim>&gt; there are no error. just display following messages. 1000 times.. 1 affected row ## Comment 17919 Date: 2012-11-08 05:56:56 +0100 From: @mlkersten This is a consequence of the transaction management scheme deployed by MonetDB. See http://www.monetdb.org/Documentation/Manuals/SQLreference/Transactions and http://en.wikipedia.org/wiki/Optimistic_concurrency_control
lost inserted data if concurrent insert into same table
https://api.github.com/repos/MonetDB/MonetDB/issues/3175/comments
0
2020-11-30T12:14:41Z
2024-06-28T13:17:33Z
https://github.com/MonetDB/MonetDB/issues/3175
753,428,244
3,175
[ "MonetDB", "MonetDB" ]
Date: 2012-11-04 23:23:36 +0100 From: Carst Vaartjes &lt;<carstvaartjes>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.3 (Oct2012) CC: carstvaartjes Last updated: 2012-11-05 10:43:20 +0100 ## Comment 17868 Date: 2012-11-04 23:23:36 +0100 From: Carst Vaartjes &lt;<carstvaartjes>&gt; User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.96 Safari/537.4 Build Identifier: Hi, to give an example: "select est_revenue, round(est_revenue, 3) from vw_store;" gives | 1.98660839 | 1.98699999 | | 7.94599295 | 7.9460001 | | 3.96715069 | 3.96700001 | | 5.12517929 | 5.125 | | 3.71785045 | 3.71799994 | | 9.15974426 | 9.15999985 | | 5.10812902 | 5.1079998 | Only the 5.125 row gives the expected result. I have the same behaviour also for other rounds. Only Round(x, 0) works correctly. I tried a workaround with Round(x * 10, 0) / 10, but that doesn't work either unfortunately. Running Ubuntu 12.04 LTE on a i7, 6gb run-of-the-mill machine. Reproducible: Always ### Steps to Reproduce: 1. Have a table with a real value 2. Select the real value with a round(x, y) with y > 0 ### Actual Results: See details, it "nearly" rounds... ### Expected Results: See the 5.125 row ## Comment 17870 Date: 2012-11-05 08:31:00 +0100 From: @grobian It looks like it's put in a double, but instead you want a number as result. ## Comment 17871 Date: 2012-11-05 09:35:48 +0100 From: Carst Vaartjes &lt;<carstvaartjes>&gt; Hi, thanks for your response! Well, yes: i'm trying to round them to present them in a nicer way (the added detail will only confuse more users). For instance from my examples, I would expect 5.10812902 to round to 5.108 (or 5.10800000) and not to 5.10799980. Same goes for the other examples (except for 5.125) Now it seems like it does round but with some small error in it, creating the x.xxx999999 etc like results. Kind regards, Carst ## Comment 17872 Date: 2012-11-05 10:03:04 +0100 From: @grobian That's the artifacts of double representation, IMO. Perhaps if you cast the result to a NUMBER(5,3) you get what you expect. ## Comment 17873 Date: 2012-11-05 10:25:38 +0100 From: Carst Vaartjes &lt;<carstvaartjes>&gt; thanks! Casting doesn't really round though (it truncates basically). To explain myself: select est_revenue as org, round(est_revenue, 3) as to_round, cast(est_revenue as numeric(8,3)) as to_cast, round(cast(est_revenue as numeric(13,8)),3) as to_round_cast, truncate( round(cast(est_revenue as numeric(13,8)),3), length(round(cast(est_revenue as numeric(13,8)),3)) - 5 ) as to_trunc_round_cast from vw_store limit 10; +-----------------+-----------------+------------+---------------+-------------+ | org | to_round | to_cast | to_round_cast | to_trunc_ro | : : : : : und_cast : +=================+=================+============+===============+=============+ | 0 | 0 | 0.000 | 0.00000000 | 0.000 | | 6.56450558 | 6.56500006 | 6.564 | 6.56500000 | 6.565 | | 5.28324842 | 5.28299999 | 5.283 | 5.28300000 | 5.283 | | 7.08326483 | 7.08300018 | 7.083 | 7.08300000 | 7.083 | | 5.73857832 | 5.73899984 | 5.738 | 5.73900000 | 5.739 | | 2.90740895 | 2.90700006 | 2.907 | 2.90700000 | 2.907 | | 4.53935146 | 4.53900003 | 4.539 | 4.53900000 | 4.539 | | 4.53935146 | 4.53900003 | 4.539 | 4.53900000 | 4.539 | | 4.39657831 | 4.39699984 | 4.396 | 4.39700000 | 4.397 | | 2.90098786 | 2.90100002 | 2.900 | 2.90100000 | 2.901 | +-----------------+-----------------+------------+---------------+-------------+ so the last one works, but is a rather ugly workaround (and I can imagine heavy on the calculative side compared to a more optimized function?). Anyway, i'll work with that then, but really I think that round should give the last result directly... Thanks for your help! ## Comment 17874 Date: 2012-11-05 10:31:54 +0100 From: @sjoerdmullender round() rounds the value to the specified number of decimals, but it doesn't change the type of the argument. So, if you put in a floating point number (real, float), then the result is still a floating point number. The thing with floating point numbers is, they cannot represent all values exactly. There is just no way that, for instance, 0.1 can be represented exactly in a (binary) floating point number (try select cast(0.1 as real);). If you start off with, e.g., a decimal(10,8) and use round to round it to 3 decimals, you will still get a decimal(10,8), but with a bunch of trailing zeros. It seems to me, what you're after is something like select cast(est_revenue + 0.0005 as decimal(5,3)) from vw_store; casting to decimal(5,3) will truncate, so add 0.0005 to round. ## Comment 17875 Date: 2012-11-05 10:43:20 +0100 From: Carst Vaartjes &lt;<carstvaartjes>&gt; Ah, thanks! Feeling a bit blond now :) Thanks for the explanation
Round(a, x) doesn't round correctly
https://api.github.com/repos/MonetDB/MonetDB/issues/3174/comments
0
2020-11-30T12:14:39Z
2024-06-28T13:17:32Z
https://github.com/MonetDB/MonetDB/issues/3174
753,428,207
3,174
[ "MonetDB", "MonetDB" ]
Date: 2012-11-02 17:17:18 +0100 From: Percy Wegmann &lt;<percy>&gt; To: @njnes Version: 11.13.3 (Oct2012) CC: bugs-sql, @njnes, s.idreos Last updated: 2013-01-22 09:29:18 +0100 ## Comment 17866 Date: 2012-11-02 17:17:18 +0100 From: Percy Wegmann &lt;<percy>&gt; User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_5) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.94 Safari/537.4 Build Identifier: I'm running MonetDB on Ubuntu 10.04, with Monet built from the Oct2012_release tag. I have a client program that connects using the JDBC driver and issues a simple SQL query using limit and offset. I see that: - limit and offset work when using literal parameters in the SQL string - limit works by itself when using a bind parameter - offset works by itself when using a bind parameter - when specifying both limit and offset and using a bind parameter for either or both, the merovingian segfaults with a message like this: database 'click' (2428) was killed by signal SIGSEGV Examples of queries that work: SELECT * FROM the_table LIMIT 5 OFFSET 100; SELECT * FROM the_table LIMIT ?; SELECT * FROM the_table OFFSET ?; Example of queries that don't work: SELECT * FROM the_table LIMIT ? OFFSET ?; SELECT * FROM the_table LIMIT 5 OFFSET ?; SELECT * FROM the_table LIMIT ? OFFSET 100; I've tried passing in the limit and offset as 64 bit integers (long), 32 bit integers (int) and strings, and none of these work. I also tried downgrading to MonetDB Database Server v1.6 (Jul2012-SP2) but had the same issue. Reproducible: Always ### Steps to Reproduce: Issue a query like this: Issue a query like any of the following: SELECT * FROM the_table LIMIT ? OFFSET ?; SELECT * FROM the_table LIMIT 5 OFFSET ?; SELECT * FROM the_table LIMIT ? OFFSET 100; ### Actual Results: the merovingian segfaults with a message like this: database 'click' (2428) was killed by signal SIGSEGV ### Expected Results: It should have executed the query with the appropriate LIMIT and OFFSET set The workaround for this bug is to not use bind parameters for limit and offset clauses in queries. The downside to this is that differ limit/offset combinations result in different query strings, which I presume prevents Monet from effectively caching what is really just 1 query. ## Comment 17867 Date: 2012-11-02 18:36:29 +0100 From: Percy Wegmann &lt;<percy>&gt; Sounds like the inability to use bind parameters may not be a performance issue. Per Fabian: "The SQL compiler already factors out constants for queries before it caches them, e.g. select x from t where a > 10 uses the same plan as select x from t where a > 3." ## Comment 18034 Date: 2012-11-27 11:38:42 +0100 From: Stratos Idreos &lt;<s.idreos>&gt; In order to use bind variables and possibly prepare statements such as you avoid optimization cost in future queries you may use the PREPARE statement as follows: PREPARE SELECT * FROM the_table LIMIT ? OFFSET ?; monetdb will reply: execute prepared statement using: EXEC Z(...) where Z is a numeric id for this statement you can later execute this prepared statement using EXEC Z(variable1,variable2); ## Comment 18059 Date: 2012-11-27 13:35:34 +0100 From: Percy Wegmann &lt;<percy>&gt; This doesn't work. I tried on the Oct 2012 release and the Oct 2012 SP1 release. Welcome to mclient, the MonetDB/SQL interactive terminal (Oct2012-SP1) Database: MonetDB v11.13.5 (Oct2012-SP1), 'mapi:monetdb://percy-sandbox:50000/click' Type \q to quit, \? for a list of available commands auto commit mode: on sql>CREATE TABLE test_table(id BIGINT); operation successful (29.824ms) sql>PREPARE SELECT * FROM test_table LIMIT ? OFFSET ?; Connection terminated From merovingian.log: 2012-11-27 06:29:35 MSG merovingian[13398]: database 'click' (13403) was killed by signal SIGSEGV GDB Output: Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x7f524a0fa700 (LWP 13750)] 0x00007f524adbc9dd in ?? () from /usr/lib/monetdb5/lib_sql.so (gdb) where 0 0x00007f524adbc9dd in ?? () from /usr/lib/monetdb5/lib_sql.so 1 0x00007f524adbe4a8 in ?? () from /usr/lib/monetdb5/lib_sql.so 2 0x00007f524adbbaf5 in ?? () from /usr/lib/monetdb5/lib_sql.so 3 0x00007f524adc50af in ?? () from /usr/lib/monetdb5/lib_sql.so 4 0x00007f524ad3b5e9 in sql_symbol2relation () from /usr/lib/monetdb5/lib_sql.so 5 0x00007f524ad2a6ed in SQLparser () from /usr/lib/monetdb5/lib_sql.so 6 0x00007f5252d4a50c in runPhase (phase=1, c=0x7f5253758338) at mal_scenario.c:522 7 runScenarioBody (c=0x7f5253758338) at mal_scenario.c:564 8 0x00007f5252d4b29f in runScenario (c=0x7f5253758338) at mal_scenario.c:601 9 0x00007f5252d4b348 in MSserveClient (dummy=0x7f5253758338) at mal_session.c:430 10 0x00007f52522fee9a in start_thread (arg=0x7f524a0fa700) at pthread_create.c:308 11 0x00007f525202bcbd in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 12 0x0000000000000000 in ?? () ## Comment 18070 Date: 2012-11-27 14:07:31 +0100 From: @grobian Yes, this needs a test (and a fix) ## Comment 18099 Date: 2012-11-27 14:55:08 +0100 From: @njnes crashed in the optimizer. Now we handle the limit/offset expressions with more care (ie we don't assume values, but expressions). So we generate an addition expression instead of a direct value addition. ## Comment 18103 Date: 2012-11-27 15:03:20 +0100 From: @njnes Changeset [ba23cef882fc](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=ba23cef882fc) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=ba23cef882fc](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=ba23cef882fc) Changeset description: fixed bug #3173 ## Comment 18383 Date: 2013-01-22 09:29:18 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
SQL queries with limit and offset clauses are unable to use bind parameters for either
https://api.github.com/repos/MonetDB/MonetDB/issues/3173/comments
0
2020-11-30T12:14:36Z
2024-06-27T11:57:58Z
https://github.com/MonetDB/MonetDB/issues/3173
753,428,179
3,173
[ "MonetDB", "MonetDB" ]
Date: 2012-11-02 14:39:48 +0100 From: @swingbit To: @njnes Version: 11.13.3 (Oct2012) CC: bugs-sql, @mlkersten, @njnes, y.kargin Last updated: 2013-07-31 15:55:17 +0200 ## Comment 17864 Date: 2012-11-02 14:39:48 +0100 From: @swingbit User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.94 Safari/537.4 Build Identifier: The following (pretty useless, but allowed) SQL, crashes mserver: create function x(a int, b int) returns table (c int,d int) external name sql.x; select * from x((select id from _tables), (select schema_id from _tables)); The external function sql.x is not even implemented, the crash happens before it is even called. Reproducible: Always ### Steps to Reproduce: 1. issue the SQL above 2. 3. ### Actual Results: SIGFAULT MonetDB 5 server v11.11.12 (64-bit, 64-bit oids) This is an unreleased version Copyright (c) 1993-July 2008 CWI Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved Visit http://www.monetdb.org/ for further information Found 2.0GiB available memory, 1 available cpu core Libraries: libpcre: 8.12 2011-01-15 (compiled with 8.12) openssl: OpenSSL 1.0.0j 10 May 2012 (compiled with OpenSSL 1.0.0j-fips 10 May 2012) libxml2: 2.7.8 (compiled with 2.7.8) Compiled by: roberto@localhost.localdomain (x86_64-unknown-linux-gnu) Compilation: gcc -g -Werror -Wall -Wextra -W -Werror-implicit-function-declaration -Wpointer-arith -Wdeclaration-after-statement -Wundef -Wformat=2 -Wno-format-nonliteral -Winit-self -Winvalid-pch -Wmissing-declarations -Wmissing-format-attribute -Wmissing-prototypes -Wold-style-definition -Wpacked -Wunknown-pragmas -Wvariadic-macros -fstack-protector-all -Wstack-protector -Wpacked-bitfield-compat -Wsync-nand -Wjump-misses-init -Wmissing-include-dirs -Wlogical-op -Wunreachable-code Linking : /usr/bin/ld -m elf_x86_64 ## Comment 17865 Date: 2012-11-02 14:43:43 +0100 From: @swingbit Correction, it does not crash, it fails on an assertion: mserver5: /home/roberto/svn.spinque.com/MonetDBServer/MonetDB.Spinque_Jul2012/src/sql/server/rel_bin.c:1233: rel2bin_table: Assertion `0' failed. ## Comment 18004 Date: 2012-11-26 11:16:01 +0100 From: @njnes what would be the expected result. Sofar we do not support multi value inputs in table returning functions. ## Comment 18006 Date: 2012-11-26 14:03:30 +0100 From: @swingbit That's ok, I reported it just because it abruptly stops the server. I think an error message would do. ## Comment 18044 Date: 2012-11-27 12:47:20 +0100 From: @njnes working on a partial (sql side) fix. Yagiz could just add the test? ## Comment 18085 Date: 2012-11-27 14:35:11 +0100 From: @njnes Changeset [89a9ebc92eda](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=89a9ebc92eda) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=89a9ebc92eda](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=89a9ebc92eda) Changeset description: added tests for Bugs 3193, 3179 and 3172 Fixed bug #3191, we now allow the order by column expressions to refer to the lower level projection. This is very limited support voor order by with expressions. Aliases is still preferred. Fixed bug #3179 (or feature request). We now rewrite batstr.*like + subselect into *likeselect. Also some cleanup of pushselect optimizer and mergetable related helper functions in opt_support.c Fixed bug #3172. We still don't allow multi row input in table functions. But we now don't crash on it anymore. Still work on mal.multiplex needed (requires multiple outputs)! ## Comment 18192 Date: 2012-11-28 13:45:16 +0100 From: Yagiz &lt;<y.kargin>&gt; Changeset [9b297e5dc99d](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=9b297e5dc99d) made by Yagiz Kargin <y.kargin@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=9b297e5dc99d](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=9b297e5dc99d) Changeset description: bug-3172 test ## Comment 18505 Date: 2013-02-19 13:17:55 +0100 From: @sjoerdmullender Feb2013 has been released. ## Comment 18898 Date: 2013-07-02 23:37:37 +0200 From: @mlkersten Improved the error message and make it more robust against mal.multiplex calls with multiple return values. ## Comment 18903 Date: 2013-07-03 14:03:47 +0200 From: MonetDB Mercurial Repository &lt;<hg>&gt; Changeset [d681c9a9e056](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=d681c9a9e056) made by Stefan Manegold <Stefan.Manegold@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=d681c9a9e056](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=d681c9a9e056) Changeset description: treat varying (with threads) ID in err.msg. as minor difference tests table_function_with_column_subselects.Bug-3172 & create_function.Bug-3172 ## Comment 18968 Date: 2013-07-31 15:55:17 +0200 From: MonetDB Mercurial Repository &lt;<hg>&gt; Changeset [e0999294bd15](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=e0999294bd15) made by Stefan Manegold <Stefan.Manegold@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=e0999294bd15](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=e0999294bd15) Changeset description: table_function_with_column_subselects.Bug-3172: approve new variable IDs in error message
assertion fails on table function with subselects as parameters
https://api.github.com/repos/MonetDB/MonetDB/issues/3172/comments
0
2020-11-30T12:14:34Z
2024-06-27T11:57:57Z
https://github.com/MonetDB/MonetDB/issues/3172
753,428,147
3,172
[ "MonetDB", "MonetDB" ]
Date: 2012-10-31 08:26:32 +0100 From: @drstmane To: SQL devs &lt;<bugs-sql>&gt; Version: -- development Last updated: 2012-11-01 10:17:44 +0100 ## Comment 17860 Date: 2012-10-31 08:26:32 +0100 From: @drstmane The introduction of the "storage cost calculator" (changeset [523120729e8d](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=523120729e8d) plus changeset [bfd558546498](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=bfd558546498) to fix compilation, plus changeset [0735f6e1ddfc](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=0735f6e1ddfc) to fix administration), makes the difference for SQL testing between !ERROR: Testing FAILED SIGNIFICANTLY (2 out of 1246 tests failed) 40 out of 1246 tests could not be executed 2 out of 1246 tests produced SIGNIFICANTLY different output and !ERROR: Testing FAILED SIGNIFICANTLY (30 out of 1246 tests failed) 40 out of 1246 tests could not be executed 30 out of 1246 tests produced SIGNIFICANTLY different output See also http://monetdb.cwi.nl/testweb/web/status.php ## Comment 17861 Date: 2012-11-01 10:17:44 +0100 From: @drstmane Fixed by Sjoerd (changeset [f4e6658a6c22](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=f4e6658a6c22) "Approvals after changesets [523120729e8d](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=523120729e8d) and 0735f6e1ddfc.". Thanks!
storage cost calculator (changeset 523120729e8d) makes 28 tests fail
https://api.github.com/repos/MonetDB/MonetDB/issues/3171/comments
0
2020-11-30T12:14:31Z
2024-06-27T11:57:56Z
https://github.com/MonetDB/MonetDB/issues/3171
753,428,110
3,171
[ "MonetDB", "MonetDB" ]
Date: 2012-10-30 11:28:20 +0100 From: Ashish Kumar Singh &lt;<ashishk>&gt; To: Merovingian devs &lt;<bugs-merovingian>&gt; Version: 11.13.3 (Oct2012) CC: ashishk Last updated: 2012-11-07 18:57:44 +0100 ## Comment 17855 Date: 2012-10-30 11:28:20 +0100 From: Ashish Kumar Singh &lt;<ashishk>&gt; User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.94 Safari/537.4 Build Identifier: As of now Monetdb tries to take more than 80% of available RAM in the system by default which is not desirable in certain cases. Can we make it as a configuration in Monetdb where we can specify in percentage or absolute value max amount of RAM which Monetdb should try to consume. This will help in general installation of monetdb during evaluations. Reproducible: Always ## Comment 17856 Date: 2012-10-30 11:31:06 +0100 From: @grobian MonetDB is a main-memory database, reducing the amount of memory it consumes defeats the purpose of the system. ## Comment 17857 Date: 2012-10-30 11:34:20 +0100 From: Ashish Kumar Singh &lt;<ashishk>&gt; I understand but that makes it complex if I want certain fixed memory amount to be dedicated to monetdb and rest for some other purposes? consider a 16 core 32 GB RAM installation and I want to make sure that : 16 GB RAM is only which MonetDB can take up at max is not possible as of now. In my opinion it will be a nice feature. ## Comment 17862 Date: 2012-11-02 12:13:22 +0100 From: Ashish Kumar Singh &lt;<ashishk>&gt; Any suggestions on the use case I presented ? ## Comment 17863 Date: 2012-11-02 12:24:15 +0100 From: @grobian Not really. If you have 32GiB of RAM, I don't see why you would only want to use half of it. MonetDB should behave well enough that if another process wants a lot of memory, MonetDB takes less. We tested this in the past, and that worked fine. ## Comment 17894 Date: 2012-11-07 18:57:44 +0100 From: @grobian We won't implement memory limiting anywhere near soon, as it requires a complete rewrite and redesign of monetdb.
Allow for configurable amount of RAM which should be used by monetdb
https://api.github.com/repos/MonetDB/MonetDB/issues/3170/comments
0
2020-11-30T12:14:29Z
2024-06-28T13:40:07Z
https://github.com/MonetDB/MonetDB/issues/3170
753,428,072
3,170
[ "MonetDB", "MonetDB" ]
Date: 2012-10-23 14:50:18 +0200 From: @grobian To: clients devs &lt;<bugs-clients>&gt; Version: 11.13.3 (Oct2012) CC: @hannesmuehleisen Last updated: 2013-01-22 09:29:19 +0100 ## Comment 17851 Date: 2012-10-23 14:50:18 +0200 From: @grobian on PHP 5.4: Fatal error: Call-time pass-by-reference has been removed in /usr/local/monetdb/share/php/monetdb/php_monetdb.php on line 302 ## Comment 18079 Date: 2012-11-27 14:25:04 +0100 From: @hannesmuehleisen From http://nl1.php.net/manual/en/language.references.pass.php : "Note: There is no reference sign on a function call - only on function definitions. Function definitions alone are enough to correctly pass the argument by reference. As of PHP 5.3.0, you will get a warning saying that "call-time pass-by-reference" is deprecated when you use & in foo(&$a);. And as of PHP 5.4.0, call-time pass-by-reference was removed, so using it will raise a fatal error." Hence, if (($row_array = monetdb_fetch_assoc(&$hdl, $row)) == FALSE) { was changed to if (($row_array = monetdb_fetch_assoc($hdl, $row)) == FALSE) { in revision :03ae7968ce97 Tested and found to be effective using PHP 5.4.9 ## Comment 18198 Date: 2012-11-28 13:45:31 +0100 From: @hannesmuehleisen Changeset [ac97c97f512e](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=ac97c97f512e) made by Hannes Muehleisen <hannes@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=ac97c97f512e](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=ac97c97f512e) Changeset description: Fixed PHP client to no longer produce a fatal error in PHP 5.4 - Bug #3169 ## Comment 18385 Date: 2013-01-22 09:29:19 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
php driver uses call-time pass-by-reference
https://api.github.com/repos/MonetDB/MonetDB/issues/3169/comments
0
2020-11-30T12:14:26Z
2024-06-27T11:57:54Z
https://github.com/MonetDB/MonetDB/issues/3169
753,428,035
3,169
[ "MonetDB", "MonetDB" ]
Date: 2012-10-23 08:36:46 +0200 From: Inho Kim &lt;<georgios.kim>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.5 (Oct2012-SP1) CC: @bartscheers, @drstmane Last updated: 2013-01-22 09:29:12 +0100 ## Comment 17848 Date: 2012-10-23 08:36:46 +0200 From: Inho Kim &lt;<georgios.kim>&gt; User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.94 Safari/537.4 Build Identifier: If table has varchar/char/clob column with default null option, insert statement cause server crash.. Reproducible: Always ### Steps to Reproduce: 1.create table test ( id int, name varchar(20) default null); 2.insert into test ( id ) values ( 1 ); ## Comment 17849 Date: 2012-10-23 10:47:01 +0200 From: @drstmane I can reproduce the segfault (with Oct2012 v11.13.3). Thanks for reporting! ## Comment 17850 Date: 2012-10-23 11:24:44 +0200 From: @drstmane The problem is that sql2str() in sql/common/sql_string.c is called with str_nil as argument, but is unable to handle that correctly: Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 0x7fffed14d700 (LWP 2421)] 0x00007fffee2a9702 in sql2str (s=0x7ffff6a93290 "\200") at /ufs/manegold/_/Monet/HG/Jul2012/source/MonetDB/sql/common/sql_string.c:130 130 *p++ = *cur; Missing separate debuginfos, use: debuginfo-install bzip2-libs-1.0.6-3.fc15.x86_64 cfitsio-3.280-2.fc16.x86_64 cyrus-sasl-lib-2.1.23-27.fc16.x86_64 geos-3.3.1-1.fc16.x86_64 glibc-2.14.90-24.fc16.9.x86_64 keyutils-libs-1.5.2-1.fc16.x86_64 krb5-libs-1.9.4-3.fc16.x86_64 libcom_err-1.41.14-2.fc15.x86_64 libcurl-7.21.7-7.fc16.x86_64 libgcc-4.6.3-2.fc16.x86_64 libidn-1.22-3.fc16.x86_64 libselinux-2.1.6-6.fc16.x86_64 libssh2-1.2.7-4.fc16.x86_64 libstdc++-4.6.3-2.fc16.x86_64 libuuid-2.20.1-2.3.fc16.x86_64 libxml2-2.7.8-6.fc16.x86_64 ncurses-libs-5.9-2.20110716.fc16.x86_64 nspr-4.9.1-2.fc16.x86_64 nss-3.13.5-1.fc16.x86_64 nss-softokn-freebl-3.13.5-1.fc16.x86_64 nss-util-3.13.5-1.fc16.x86_64 openldap-2.4.26-8.fc16.x86_64 openssl-1.0.0j-1.fc16.x86_64 pcre-8.12-9.fc16.x86_64 readline-6.2-2.fc16.x86_64 zlib-1.2.5-7.fc16.x86_64 (gdb) bt 0 0x00007fffee2a9702 in sql2str (s=0x7ffff6a93290 "\200") at /ufs/manegold/_/Monet/HG/Jul2012/source/MonetDB/sql/common/sql_string.c:130 1 0x00007fffee1e59b8 in stmt_atom_string (sa=0x7fffe01d5c00, S=0x7ffff6a93290 "\200") at /ufs/manegold/_/Monet/HG/Jul2012/source/MonetDB/sql/server/sql_statement.c:158 2 0x00007fffee1e9d7c in stmt_alias (sa=0x7fffe01d5c00, op1=0x7fffe00a4700, tname=0x7ffff6a93290 "\200", alias=0x7fffe00a4780 "L2") at /ufs/manegold/_/Monet/HG/Jul2012/source/MonetDB/sql/server/sql_statement.c:1610 3 0x00007fffee244ee8 in stmt_rename (sql=0x7fffe0005470, rel=0x7fffe00a3880, exp=0x7fffe00a3c10, s=0x7fffe00a4700) at /ufs/manegold/_/Monet/HG/Jul2012/source/MonetDB/sql/server/rel_bin.c:1109 4 0x00007fffee24a43d in rel2bin_project (sql=0x7fffe0005470, rel=0x7fffe00a3880, refs=0x7fffe00a4360, topn=0x0) at /ufs/manegold/_/Monet/HG/Jul2012/source/MonetDB/sql/server/rel_bin.c:2191 5 0x00007fffee25431b in subrel_bin (sql=0x7fffe0005470, rel=0x7fffe00a3880, refs=0x7fffe00a4360) at /ufs/manegold/_/Monet/HG/Jul2012/source/MonetDB/sql/server/rel_bin.c:4360 6 0x00007fffee24ddac in rel2bin_insert (sql=0x7fffe0005470, rel=0x7fffe00a4330, refs=0x7fffe00a4360) at /ufs/manegold/_/Monet/HG/Jul2012/source/MonetDB/sql/server/rel_bin.c:2992 7 0x00007fffee254401 in subrel_bin (sql=0x7fffe0005470, rel=0x7fffe00a4330, refs=0x7fffe00a4360) at /ufs/manegold/_/Monet/HG/Jul2012/source/MonetDB/sql/server/rel_bin.c:4380 8 0x00007fffee25465a in output_rel_bin (sql=0x7fffe0005470, rel=0x7fffe00a4330) at /ufs/manegold/_/Monet/HG/Jul2012/source/MonetDB/sql/server/rel_bin.c:4428 9 0x00007fffee171b17 in sql_relation2stmt (c=0x7fffe0005470, r=0x7fffe00a4330) at /ufs/manegold/_/Monet/HG/Jul2012/source/MonetDB/sql/backends/monet5/sql.mx:1678 10 0x00007fffee160e3b in SQLparser (c=0x7fffef130348) at /ufs/manegold/_/Monet/HG/Jul2012/source/MonetDB/sql/backends/monet5/sql_scenario.c:1504 11 0x00007ffff703df24 in runPhase (c=0x7fffef130348, phase=1) at /ufs/manegold/_/Monet/HG/Jul2012/source/MonetDB/monetdb5/mal/mal_scenario.c:522 12 0x00007ffff703e07f in runScenarioBody (c=0x7fffef130348) at /ufs/manegold/_/Monet/HG/Jul2012/source/MonetDB/monetdb5/mal/mal_scenario.c:564 13 0x00007ffff703e316 in runScenario (c=0x7fffef130348) at /ufs/manegold/_/Monet/HG/Jul2012/source/MonetDB/monetdb5/mal/mal_scenario.c:601 14 0x00007ffff703f3b8 in MSserveClient (dummy=0x7fffef130348) at /ufs/manegold/_/Monet/HG/Jul2012/source/MonetDB/monetdb5/mal/mal_session.c:438 15 0x0000003cf3c07d90 in start_thread () from /lib64/libpthread.so.0 16 0x0000003cf30f119d in clone () from /lib64/libc.so.6 (gdb) li 125 } 126 escaped = FALSE; 127 } else if (*cur == '\\') { 128 escaped = TRUE; 129 } else { 130 *p++ = *cur; 131 } 132 } 133 *p = '\0'; 134 return s; (gdb) p s $1 = 0x7ffff6a93290 "\200" (gdb) p *s $2 = -128 '\200' (gdb) p p $3 = 0x7ffff6a93290 "\200" (gdb) p *p $4 = -128 '\200' (gdb) p cur $5 = 0x7ffff6a93290 "\200" (gdb) p *cur $6 = -128 '\200' (gdb) p str_nil $7 = "\200" (gdb) p &str_nil $8 = (const char (*)[2]) 0x7ffff6a93290 (gdb) ## Comment 17972 Date: 2012-11-21 14:39:50 +0100 From: @grobian Changeset [e798c1a1af8b](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=e798c1a1af8b) made by Fabian Groffen <fabian@monetdb.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=e798c1a1af8b](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=e798c1a1af8b) Changeset description: sql2str: handle str_nil Detect str_nil early instead of crashing on it lateron. Return same str_nil, so we end up with nil/NULL afterwards. Bug #3168 ## Comment 18371 Date: 2013-01-22 09:29:12 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
crash when insert varchar/char/clob with default NULL
https://api.github.com/repos/MonetDB/MonetDB/issues/3168/comments
0
2020-11-30T12:14:24Z
2024-06-27T11:57:53Z
https://github.com/MonetDB/MonetDB/issues/3168
753,428,002
3,168
[ "MonetDB", "MonetDB" ]
Date: 2012-10-21 17:21:42 +0200 From: Yagiz &lt;<y.kargin>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: -- development CC: y.kargin Last updated: 2012-11-07 19:01:45 +0100 ## Comment 17847 Date: 2012-10-21 17:21:42 +0200 From: Yagiz &lt;<y.kargin>&gt; User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.1 (KHTML, like Gecko) Chrome/21.0.1180.79 Safari/537.1 Build Identifier: When SQLstatementIntern is called for a schema change (CREATE FUNCTION), and then more than once for querying internally, a segmentation fault is received in the next external query (by mclient). This is because the o->qc begins showing freed space, and then m->qc is assigned to o->qc. Reproducible: Always ### Steps to Reproduce: 1. Call SQLstatementIntern for a schema change internally from C code. 2. Then call it again multiple times for SELECT queries. 3. After execution of that C code, send any query through interactive mclient. ### Actual Results: Segmentation fault. ### Expected Results: Query answer. Injecting this: "o->qc = m->qc; if (!o->qc) o->qc = qc_create(o->clientid, 0);" before this: "*m = *o;" line at function SQLstatementIntern in sql_scenario.c solves the problem for this case. ## Comment 17895 Date: 2012-11-07 19:01:45 +0100 From: @grobian Fixed in DVframework branch.
Query cache becomes broken, if SQLstatementIntern is called multiple times after a schema change.
https://api.github.com/repos/MonetDB/MonetDB/issues/3167/comments
0
2020-11-30T12:14:21Z
2024-06-28T13:17:31Z
https://github.com/MonetDB/MonetDB/issues/3167
753,427,971
3,167
[ "MonetDB", "MonetDB" ]
Date: 2012-10-18 14:03:23 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; To: Merovingian devs &lt;<bugs-merovingian>&gt; Version: 11.13.3 (Oct2012) CC: ashishk Last updated: 2012-10-19 19:28:15 +0200 ## Comment 17823 Date: 2012-10-18 14:03:23 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.94 Safari/537.4 Build Identifier: I am able to compile Monetdb successfully but running it fails with FPE. Reproducible: Always ### Steps to Reproduce: 1.monetdb compliles successfully 2. ON running monetdbd it gives Flaoting Point Exception ## Comment 17824 Date: 2012-10-18 14:25:17 +0200 From: @grobian and what OS is this on? ## Comment 17825 Date: 2012-10-18 14:27:20 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; SLES 10 SP4 64 bit ## Comment 17826 Date: 2012-10-18 14:29:35 +0200 From: @grobian I'd like to see an error trace, or anything else produced by the OS (dmesg output?) ## Comment 17827 Date: 2012-10-18 15:10:59 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; monetdbd mono-find-provides linux-jvbr:~ strace monetdbd execve("/root/bin/monetdbd", ["monetdbd"], [/* 84 vars */]) = 0 brk(0) = 0x61f000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2b0 80e93e000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2b0 80e93f000 access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory) open("/usr/local/lib/tls/x86_64/libstream.so.3", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/tls/libstream.so.3", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/x86_64/libstream.so.3", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libstream.so.3", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\240%\0\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=101028, ...}) = 0 mmap(NULL, 1078464, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080ea3f000 madvise(0x2b080ea3f000, 1078464, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080ea47000, 1044480, PROT_NONE) = 0 mmap(0x2b080eb46000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYW RITE, 3, 0x7000) = 0x2b080eb46000 close(3) = 0 open("/usr/local/lib/tls/x86_64/libmapi.so.6", O_RDONLY) = -1 ENOENT (No such fi le or directory) open("/usr/local/lib/tls/libmapi.so.6", O_RDONLY) = -1 ENOENT (No such file or d irectory) open("/usr/local/lib/x86_64/libmapi.so.6", O_RDONLY) = -1 ENOENT (No such file o r directory) open("/usr/local/lib/libmapi.so.6", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\240A\0\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=201383, ...}) = 0 mmap(NULL, 1125104, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080eb47000 madvise(0x2b080eb47000, 1125104, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080eb5a000, 1044480, PROT_NONE) = 0 mmap(0x2b080ec59000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYW RITE, 3, 0x12000) = 0x2b080ec59000 close(3) = 0 open("/usr/local/lib/tls/x86_64/libssl.so.6", O_RDONLY) = -1 ENOENT (No such fil e or directory) open("/usr/local/lib/tls/libssl.so.6", O_RDONLY) = -1 ENOENT (No such file or di rectory) open("/usr/local/lib/x86_64/libssl.so.6", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libssl.so.6", O_RDONLY) = -1 ENOENT (No such file or direct ory) open("/etc/ld.so.cache", O_RDONLY) = 3 fstat(3, {st_mode=S_IFREG|0644, st_size=78210, ...}) = 0 mmap(NULL, 78210, PROT_READ, MAP_PRIVATE, 3, 0) = 0x2b080ec5a000 close(3) = 0 open("/lib64/tls/x86_64/libssl.so.6", O_RDONLY) = -1 ENOENT (No such file or dir ectory) open("/lib64/tls/libssl.so.6", O_RDONLY) = -1 ENOENT (No such file or directory) open("/lib64/x86_64/libssl.so.6", O_RDONLY) = -1 ENOENT (No such file or directo ry) open("/lib64/libssl.so.6", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/lib64/tls/x86_64/libssl.so.6", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/lib64/tls/libssl.so.6", O_RDONLY) = -1 ENOENT (No such file or direct ory) open("/usr/lib64/x86_64/libssl.so.6", O_RDONLY) = -1 ENOENT (No such file or dir ectory) open("/usr/lib64/libssl.so.6", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\20\221\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=225952, ...}) = 0 mmap(NULL, 1273728, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080ec6e000 madvise(0x2b080ec6e000, 1273728, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080eca2000, 1044480, PROT_NONE) = 0 mmap(0x2b080eda1000, 16384, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENY WRITE, 3, 0x33000) = 0x2b080eda1000 close(3) = 0 open("/usr/local/lib/tls/x86_64/libcrypto.so.6", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/tls/libcrypto.so.6", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/x86_64/libcrypto.so.6", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libcrypto.so.6", O_RDONLY) = -1 ENOENT (No such file or dir ectory) open("/lib64/tls/x86_64/libcrypto.so.6", O_RDONLY) = -1 ENOENT (No such file or directory) open("/lib64/tls/libcrypto.so.6", O_RDONLY) = -1 ENOENT (No such file or directo ry) open("/lib64/x86_64/libcrypto.so.6", O_RDONLY) = -1 ENOENT (No such file or dire ctory) open("/lib64/libcrypto.so.6", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/lib64/tls/x86_64/libcrypto.so.6", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/lib64/tls/libcrypto.so.6", O_RDONLY) = -1 ENOENT (No such file or dir ectory) open("/usr/lib64/x86_64/libcrypto.so.6", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/lib64/libcrypto.so.6", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\320\350"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0555, st_size=1458544, ...}) = 0 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2b0 80eda5000 mmap(NULL, 2500888, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080eda6000 madvise(0x2b080eda6000, 2500888, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080eee4000, 1044480, PROT_NONE) = 0 mmap(0x2b080efe3000, 139264, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DEN YWRITE, 3, 0x13d000) = 0x2b080efe3000 mmap(0x2b080f005000, 14616, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANON YMOUS, -1, 0) = 0x2b080f005000 close(3) = 0 open("/usr/local/lib/tls/x86_64/libdl.so.2", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/tls/libdl.so.2", O_RDONLY) = -1 ENOENT (No such file or dir ectory) open("/usr/local/lib/x86_64/libdl.so.2", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libdl.so.2", O_RDONLY) = -1 ENOENT (No such file or directo ry) open("/lib64/libdl.so.2", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\240\20\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=19635, ...}) = 0 mmap(NULL, 1061152, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080f009000 madvise(0x2b080f009000, 1061152, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080f00b000, 1048576, PROT_NONE) = 0 mmap(0x2b080f10b000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYW RITE, 3, 0x2000) = 0x2b080f10b000 close(3) = 0 open("/usr/local/lib/tls/x86_64/libz.so.1", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/tls/libz.so.1", O_RDONLY) = -1 ENOENT (No such file or dire ctory) open("/usr/local/lib/x86_64/libz.so.1", O_RDONLY) = -1 ENOENT (No such file or d irectory) open("/usr/local/lib/libz.so.1", O_RDONLY) = -1 ENOENT (No such file or director y) open("/lib64/libz.so.1", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0000 \0\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=83976, ...}) = 0 mmap(NULL, 1130088, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080f10d000 madvise(0x2b080f10d000, 1130088, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080f121000, 1044480, PROT_NONE) = 0 mmap(0x2b080f220000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYW RITE, 3, 0x13000) = 0x2b080f220000 close(3) = 0 open("/usr/local/lib/tls/x86_64/libcrypt.so.1", O_RDONLY) = -1 ENOENT (No such f ile or directory) open("/usr/local/lib/tls/libcrypt.so.1", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/x86_64/libcrypt.so.1", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libcrypt.so.1", O_RDONLY) = -1 ENOENT (No such file or dire ctory) open("/lib64/libcrypt.so.1", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\360\f\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=49501, ...}) = 0 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2b0 80f221000 mmap(NULL, 1278624, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080f222000 madvise(0x2b080f222000, 1278624, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080f22b000, 1044480, PROT_NONE) = 0 mmap(0x2b080f32a000, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENY WRITE, 3, 0x8000) = 0x2b080f32a000 mmap(0x2b080f32d000, 184992, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANO NYMOUS, -1, 0) = 0x2b080f32d000 close(3) = 0 open("/usr/local/lib/tls/x86_64/libuuid.so.1", O_RDONLY) = -1 ENOENT (No such fi le or directory) open("/usr/local/lib/tls/libuuid.so.1", O_RDONLY) = -1 ENOENT (No such file or d irectory) open("/usr/local/lib/x86_64/libuuid.so.1", O_RDONLY) = -1 ENOENT (No such file o r directory) open("/usr/local/lib/libuuid.so.1", O_RDONLY) = -1 ENOENT (No such file or direc tory) open("/lib64/libuuid.so.1", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\20\25\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=13488, ...}) = 0 mmap(NULL, 1059544, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080f35b000 madvise(0x2b080f35b000, 1059544, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080f35e000, 1044480, PROT_NONE) = 0 mmap(0x2b080f45d000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYW RITE, 3, 0x2000) = 0x2b080f45d000 close(3) = 0 open("/usr/local/lib/tls/x86_64/libpthread.so.0", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/tls/libpthread.so.0", O_RDONLY) = -1 ENOENT (No such file o r directory) open("/usr/local/lib/x86_64/libpthread.so.0", O_RDONLY) = -1 ENOENT (No such fil e or directory) open("/usr/local/lib/libpthread.so.0", O_RDONLY) = -1 ENOENT (No such file or di rectory) open("/lib64/libpthread.so.0", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0 Z\0\0\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=123893, ...}) = 0 mmap(NULL, 1147768, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080f45e000 madvise(0x2b080f45e000, 1147768, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080f472000, 1044480, PROT_NONE) = 0 mmap(0x2b080f571000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYW RITE, 3, 0x13000) = 0x2b080f571000 mmap(0x2b080f573000, 13176, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANON YMOUS, -1, 0) = 0x2b080f573000 close(3) = 0 open("/usr/local/lib/tls/x86_64/libc.so.6", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/tls/libc.so.6", O_RDONLY) = -1 ENOENT (No such file or dire ctory) open("/usr/local/lib/x86_64/libc.so.6", O_RDONLY) = -1 ENOENT (No such file or d irectory) open("/usr/local/lib/libc.so.6", O_RDONLY) = -1 ENOENT (No such file or director y) open("/lib64/libc.so.6", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\0\324\1"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=1570886, ...}) = 0 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2b0 80f577000 mmap(NULL, 2355560, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080f578000 madvise(0x2b080f578000, 2355560, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080f6af000, 1044480, PROT_NONE) = 0 mmap(0x2b080f7ae000, 20480, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENY WRITE, 3, 0x136000) = 0x2b080f7ae000 mmap(0x2b080f7b3000, 16744, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANON YMOUS, -1, 0) = 0x2b080f7b3000 close(3) = 0 open("/usr/local/lib/tls/x86_64/libbz2.so.1", O_RDONLY) = -1 ENOENT (No such fil e or directory) open("/usr/local/lib/tls/libbz2.so.1", O_RDONLY) = -1 ENOENT (No such file or di rectory) open("/usr/local/lib/x86_64/libbz2.so.1", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libbz2.so.1", O_RDONLY) = -1 ENOENT (No such file or direct ory) open("/usr/local/lib/tls/x86_64/libbz2.so.1", O_RDONLY) = -1 ENOENT (No such fil e or directory) open("/usr/local/lib/tls/libbz2.so.1", O_RDONLY) = -1 ENOENT (No such file or di rectory) open("/usr/local/lib/x86_64/libbz2.so.1", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libbz2.so.1", O_RDONLY) = -1 ENOENT (No such file or direct ory) open("/lib64/libbz2.so.1", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\260\27\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=67416, ...}) = 0 mmap(NULL, 1113576, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080f7b8000 madvise(0x2b080f7b8000, 1113576, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080f7c7000, 1044480, PROT_NONE) = 0 mmap(0x2b080f8c6000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYW RITE, 3, 0xe000) = 0x2b080f8c6000 close(3) = 0 open("/usr/local/lib/tls/x86_64/libssl.so.0.9.8", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/tls/libssl.so.0.9.8", O_RDONLY) = -1 ENOENT (No such file o r directory) open("/usr/local/lib/x86_64/libssl.so.0.9.8", O_RDONLY) = -1 ENOENT (No such fil e or directory) open("/usr/local/lib/libssl.so.0.9.8", O_RDONLY) = -1 ENOENT (No such file or di rectory) open("/usr/local/lib/tls/x86_64/libssl.so.0.9.8", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/tls/libssl.so.0.9.8", O_RDONLY) = -1 ENOENT (No such file o r directory) open("/usr/local/lib/x86_64/libssl.so.0.9.8", O_RDONLY) = -1 ENOENT (No such fil e or directory) open("/usr/local/lib/libssl.so.0.9.8", O_RDONLY) = -1 ENOENT (No such file or di rectory) open("/usr/lib64/libssl.so.0.9.8", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0 \1\0\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0555, st_size=295104, ...}) = 0 mmap(NULL, 1339936, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080f8c8000 madvise(0x2b080f8c8000, 1339936, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080f90a000, 1044480, PROT_NONE) = 0 mmap(0x2b080fa09000, 28672, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENY WRITE, 3, 0x41000) = 0x2b080fa09000 close(3) = 0 open("/usr/local/lib/tls/x86_64/libnss3.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/tls/libnss3.so", O_RDONLY) = -1 ENOENT (No such file or dir ectory) open("/usr/local/lib/x86_64/libnss3.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libnss3.so", O_RDONLY) = -1 ENOENT (No such file or directo ry) open("/usr/local/lib/tls/x86_64/libnss3.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/tls/libnss3.so", O_RDONLY) = -1 ENOENT (No such file or dir ectory) open("/usr/local/lib/x86_64/libnss3.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libnss3.so", O_RDONLY) = -1 ENOENT (No such file or directo ry) open("/usr/lib64/libnss3.so", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\240\214"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=1241720, ...}) = 0 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2b0 80fa10000 mmap(NULL, 2288040, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080fa11000 madvise(0x2b080fa11000, 2288040, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080fb38000, 1048576, PROT_NONE) = 0 mmap(0x2b080fc38000, 28672, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENY WRITE, 3, 0x127000) = 0x2b080fc38000 mmap(0x2b080fc3f000, 2472, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONY MOUS, -1, 0) = 0x2b080fc3f000 close(3) = 0 open("/usr/local/lib/tls/x86_64/libnssutil3.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/tls/libnssutil3.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/x86_64/libnssutil3.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libnssutil3.so", O_RDONLY) = -1 ENOENT (No such file or dir ectory) open("/usr/local/lib/tls/x86_64/libnssutil3.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/tls/libnssutil3.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/x86_64/libnssutil3.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libnssutil3.so", O_RDONLY) = -1 ENOENT (No such file or dir ectory) open("/usr/lib64/libnssutil3.so", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0`\207\0\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=122272, ...}) = 0 mmap(NULL, 1169104, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080fc40000 madvise(0x2b080fc40000, 1169104, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080fc59000, 1044480, PROT_NONE) = 0 mmap(0x2b080fd58000, 24576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENY WRITE, 3, 0x18000) = 0x2b080fd58000 close(3) = 0 open("/usr/local/lib/tls/x86_64/libplc4.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/tls/libplc4.so", O_RDONLY) = -1 ENOENT (No such file or dir ectory) open("/usr/local/lib/x86_64/libplc4.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libplc4.so", O_RDONLY) = -1 ENOENT (No such file or directo ry) open("/usr/local/lib/tls/x86_64/libplc4.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/tls/libplc4.so", O_RDONLY) = -1 ENOENT (No such file or dir ectory) open("/usr/local/lib/x86_64/libplc4.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libplc4.so", O_RDONLY) = -1 ENOENT (No such file or directo ry) open("/usr/lib64/libplc4.so", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\220\25\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=16928, ...}) = 0 mmap(NULL, 1062832, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080fd5e000 madvise(0x2b080fd5e000, 1062832, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080fd62000, 1044480, PROT_NONE) = 0 mmap(0x2b080fe61000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYW RITE, 3, 0x3000) = 0x2b080fe61000 close(3) = 0 open("/usr/local/lib/tls/x86_64/libplds4.so", O_RDONLY) = -1 ENOENT (No such fil e or directory) open("/usr/local/lib/tls/libplds4.so", O_RDONLY) = -1 ENOENT (No such file or di rectory) open("/usr/local/lib/x86_64/libplds4.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libplds4.so", O_RDONLY) = -1 ENOENT (No such file or direct ory) open("/usr/local/lib/tls/x86_64/libplds4.so", O_RDONLY) = -1 ENOENT (No such fil e or directory) open("/usr/local/lib/tls/libplds4.so", O_RDONLY) = -1 ENOENT (No such file or di rectory) open("/usr/local/lib/x86_64/libplds4.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libplds4.so", O_RDONLY) = -1 ENOENT (No such file or direct ory) open("/usr/lib64/libplds4.so", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\360\17\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=12312, ...}) = 0 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2b0 80fe62000 mmap(NULL, 1058760, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080fe63000 madvise(0x2b080fe63000, 1058760, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080fe66000, 1044480, PROT_NONE) = 0 mmap(0x2b080ff65000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYW RITE, 3, 0x2000) = 0x2b080ff65000 close(3) = 0 open("/usr/local/lib/tls/x86_64/libnspr4.so", O_RDONLY) = -1 ENOENT (No such fil e or directory) open("/usr/local/lib/tls/libnspr4.so", O_RDONLY) = -1 ENOENT (No such file or di rectory) open("/usr/local/lib/x86_64/libnspr4.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libnspr4.so", O_RDONLY) = -1 ENOENT (No such file or direct ory) open("/usr/local/lib/tls/x86_64/libnspr4.so", O_RDONLY) = -1 ENOENT (No such fil e or directory) open("/usr/local/lib/tls/libnspr4.so", O_RDONLY) = -1 ENOENT (No such file or di rectory) open("/usr/local/lib/x86_64/libnspr4.so", O_RDONLY) = -1 ENOENT (No such file or directory) open("/usr/local/lib/libnspr4.so", O_RDONLY) = -1 ENOENT (No such file or direct ory) open("/usr/lib64/libnspr4.so", O_RDONLY) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\260\324"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=233360, ...}) = 0 mmap(NULL, 1288032, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x2b 080ff66000 madvise(0x2b080ff66000, 1288032, MADV_SEQUENTIAL|0x1) = 0 mprotect(0x2b080ff9c000, 1048576, PROT_NONE) = 0 mmap(0x2b081009c000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYW RITE, 3, 0x36000) = 0x2b081009c000 mmap(0x2b081009e000, 10080, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANON YMOUS, -1, 0) = 0x2b081009e000 close(3) = 0 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2b0 8100a1000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2b0 8100a2000 mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x2b0 8100a3000 arch_prctl(ARCH_SET_FS, 0x2b08100a29c0) = 0 --- SIGFPE (Floating point exception) @ 0 (0) --- +++ killed by SIGFPE +++ linux-jvbr:~ ## Comment 17828 Date: 2012-10-18 16:16:33 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; hi, if you are looking for specific types for logs can you provide steps for generating that? Ashish ## Comment 17829 Date: 2012-10-18 17:51:09 +0200 From: @grobian Well, your strace suggests you have a problem either in your compilation or your system at whole. How did you compile it? ## Comment 17830 Date: 2012-10-18 17:55:24 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; Thanks, Procedure I was following was : 1. Resolve dependencies for openssl, pcre, ant etc.. using packages available in SLES 10 SP4. 2. ./configure 3. make 4. make install Thanks for your attention this platform is very important for us. ## Comment 17831 Date: 2012-10-18 17:56:05 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; Also its was a vanila SLES 10 SP4 install. ## Comment 17832 Date: 2012-10-18 18:03:06 +0200 From: @grobian does mserver5 --version run? if so, please post its output where did you get the sources from? ## Comment 17833 Date: 2012-10-18 18:09:24 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; Sources are from release area. mserver --version is also giving floating point exception ## Comment 17834 Date: 2012-10-18 18:11:48 +0200 From: @grobian please run "file" on monetdbd or mserver5 binary in your build environment, run grep CFLAGS Makefile and post the output ## Comment 17835 Date: 2012-10-18 18:19:32 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; Here you go! linux-jvbr:~ file /usr/local/bin/monetdb /usr/local/bin/monetdb: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), for GNU/Linux 2.6.4, dynamically linked (uses shared libs), not stripped linux-jvbr:~ file /usr/local/bin/monetdbd /usr/local/bin/monetdbd: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), for GNU/Linux 2.6.4, dynamically linked (uses shared libs), not stripped linux-jvbr:~ file /usr/local/bin/mserver5 /usr/local/bin/mserver5: ELF 64-bit LSB executable, x86-64, version 1 (SYSV), for GNU/Linux 2.6.4, dynamically linked (uses shared libs), not stripped linux-jvbr:/opt/MonetDB-11.11.11 grep CFLAGS Makefile BZ_CFLAGS = CFLAGS = -g -O2 $(X_CFLAGS) JAVACFLAGS = -g:none -O MSEED_CFLAGS = SPHINXCLIENT_CFLAGS = X_CFLAGS = cfitsio_CFLAGS = curl_CFLAGS = libxml2_CFLAGS = -I/usr/include/libxml2 openssl_CFLAGS = pcre_CFLAGS = raptor_CFLAGS = valgrind_CFLAGS = zlib_CFLAGS = ## Comment 17836 Date: 2012-10-19 07:12:26 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; HI Fabian , Let me know if you need any additional info on this, any pointers will be greatly appreciated. Regards, Ashish ## Comment 17837 Date: 2012-10-19 07:27:07 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; Also what is the minimal version of glibc required for monetdb? ## Comment 17838 Date: 2012-10-19 09:32:53 +0200 From: @grobian If mclient --version does also generate a SIGFPE, I'm affraid there is nothing we can do. Since you have built with debugging symbols, perhaps you can try running mserver5 using gdb (gdb --args mserver5) and get some useful stacktrace. ## Comment 17839 Date: 2012-10-19 09:45:37 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; Hi GDB out put attached for mserver5, monetdbd linux-jvbr:~ gdb mserver5 GNU gdb (GDB) SUSE (7.1-8.9.1) Copyright (C) 2010 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-suse-linux". For bug reporting instructions, please see: <http://www.gnu.org/software/gdb/bugs/>... Reading symbols from /root/bin/mserver5...done. (gdb) run Starting program: /root/bin/mserver5 Missing separate debuginfo for /lib64/ld-linux-x86-64.so.2 Program received signal SIGFPE, Arithmetic exception. 0x00002aaaaaab363f in do_lookup_x () from /lib64/ld-linux-x86-64.so.2 linux-jvbr:~ gdb monetdbd GNU gdb (GDB) SUSE (7.1-8.9.1) Copyright (C) 2010 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-suse-linux". For bug reporting instructions, please see: <http://www.gnu.org/software/gdb/bugs/>... Reading symbols from /root/bin/monetdbd...done. (gdb) run Starting program: /root/bin/monetdbd Missing separate debuginfo for /lib64/ld-linux-x86-64.so.2 Program received signal SIGFPE, Arithmetic exception. 0x00002aaaaaab363f in do_lookup_x () from /lib64/ld-linux-x86-64.so.2 (gdb) ## Comment 17840 Date: 2012-10-19 09:50:49 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; linux-jvbr:~ gdb monetdbd GNU gdb (GDB) SUSE (7.1-8.9.1) Copyright (C) 2010 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html> This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-suse-linux". For bug reporting instructions, please see: <http://www.gnu.org/software/gdb/bugs/>... Reading symbols from /root/bin/monetdbd...done. (gdb) run Starting program: /root/bin/monetdbd Missing separate debuginfo for /lib64/ld-linux-x86-64.so.2 Program received signal SIGFPE, Arithmetic exception. 0x00002aaaaaab363f in do_lookup_x () from /lib64/ld-linux-x86-64.so.2 (gdb) bt 0 0x00002aaaaaab363f in do_lookup_x () from /lib64/ld-linux-x86-64.so.2 1 0x00002aaaaaab3a27 in _dl_lookup_symbol_x () from /lib64/ld-linux-x86-64.so.2 2 0x00002aaaaaab4fd8 in _dl_relocate_object () from /lib64/ld-linux-x86-64.so.2 3 0x00002aaaaaaae69a in dl_main () from /lib64/ld-linux-x86-64.so.2 4 0x00002aaaaaabcf62 in _dl_sysdep_start () from /lib64/ld-linux-x86-64.so.2 5 0x00002aaaaaaac246 in _dl_start () from /lib64/ld-linux-x86-64.so.2 6 0x00002aaaaaaaba88 in _start () from /lib64/ld-linux-x86-64.so.2 7 0x0000000000000001 in ?? () 8 0x00007fffffffcf30 in ?? () 9 0x0000000000000000 in ?? () ## Comment 17841 Date: 2012-10-19 10:02:12 +0200 From: @grobian I'm sorry to say, but this is deep down in your system, before our code is actually started (it's loading the shared libraries). There is nothing we can do about this. Your system seems broken to me (or impaired by security measures that make it unable to run any self-compiled code). ## Comment 17842 Date: 2012-10-19 10:25:14 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; Sorry but I tried running a sample c program and worked fine for me. So problem is something different? IS something like this the reasoning? http://fixunix.com/unix/379047-fpe-ld-linux-x86-64-so-loading-custome-dso-apache.html ## Comment 17843 Date: 2012-10-19 10:32:40 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; http://www.sublimetext.com/forum/viewtopic.php?f=3&t=3743&start=0 ## Comment 17844 Date: 2012-10-19 10:40:28 +0200 From: @grobian If -Wl,--hash-style=both in your LDFLAGS resolves this issue for you (do a full CLEAN recompile) then be happy. Still, this is not a MonetDB issue, but more a broken toolchain configuration on your host system. MonetDB build-system is not calling the compiler/linker with any special flags here that would change the DT_HASH/DT_GNU_HASH fields of the ELF objects created. ## Comment 17845 Date: 2012-10-19 18:55:30 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; Thanks for your help! after upgrading some libraries pcre,automake, bison etc.. I am able to get mclient package run so clearly something was wrong with library dependencies. Any idea what might be causing below error? make[7]: Leaving directory `/opt/MonetDB-11.11.11/monetdb5/extras/compiler' make[6]: Leaving directory `/opt/MonetDB-11.11.11/monetdb5/extras/compiler' Making all in jaql make[6]: Entering directory `/opt/MonetDB-11.11.11/monetdb5/extras/jaql' make all-recursive make[7]: Entering directory `/opt/MonetDB-11.11.11/monetdb5/extras/jaql' Making all in parser make[8]: Entering directory `/opt/MonetDB-11.11.11/monetdb5/extras/jaql/parser' touch waiting.$$ && until ln waiting.$$ waiting 2>/dev/null; do sleep 1; done && rm waiting.$$ bison -y -d -p jaql jaql.y || { rm -f waiting ; exit 1 ; } conflicts: 11 shift/reduce if [ -f y.tab.c ]; then mv y.tab.c jaql.tab.c ; fi [ ! -f y.tab.h ] || rm -f y.tab.h rm -f waiting touch waiting.$$ && until ln waiting.$$ waiting 2>/dev/null; do sleep 1; done && rm waiting.$$ bison -y -d -p jaql jaql.y || { rm -f waiting ; exit 1 ; } conflicts: 11 shift/reduce if [ -f y.tab.h ]; then mv y.tab.h jaql.tab.h ; fi [ ! -f y.tab.c ] || rm -f y.tab.c rm -f waiting touch waiting.$$ && until ln waiting.$$ waiting 2>/dev/null; do sleep 1; done && rm waiting.$$ flex -ojaql.yy.c --header-file=jaql.yy.h -P jaql jaql.l || { rm -f waiting ; exit 1 ; } jaql.l:42: unrecognized %option: extra-type make[8]: *** [jaql.yy.c] Error 1 make[8]: Leaving directory `/opt/MonetDB-11.11.11/monetdb5/extras/jaql/parser' make[7]: *** [all-recursive] Error 1 make[7]: Leaving directory `/opt/MonetDB-11.11.11/monetdb5/extras/jaql' make[6]: *** [all] Error 2 make[6]: Leaving directory `/opt/MonetDB-11.11.11/monetdb5/extras/jaql' make[5]: *** [all-recursive] Error 1 make[5]: Leaving directory `/opt/MonetDB-11.11.11/monetdb5/extras' make[4]: *** [all] Error 2 make[4]: Leaving directory `/opt/MonetDB-11.11.11/monetdb5/extras' make[3]: *** [all-recursive] Error 1 make[3]: Leaving directory `/opt/MonetDB-11.11.11/monetdb5' make[2]: *** [all] Error 2 make[2]: Leaving directory `/opt/MonetDB-11.11.11/monetdb5' make[1]: *** [all-recursive] Error 1 make[1]: Leaving directory `/opt/MonetDB-11.11.11' make: *** [all] Error 2 ## Comment 17846 Date: 2012-10-19 19:28:15 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; Hi Fabian, Now I am able to successfully compile and run monetdb on SLES 10 SP4. Thanks for all your help!
getting floating point exception while running monetdb
https://api.github.com/repos/MonetDB/MonetDB/issues/3166/comments
0
2020-11-30T12:14:18Z
2024-06-28T13:17:30Z
https://github.com/MonetDB/MonetDB/issues/3166
753,427,915
3,166
[ "MonetDB", "MonetDB" ]
Date: 2012-10-17 21:56:32 +0200 From: gordon &lt;<gordon>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: -- development CC: duc, @njnes, @skinkie Duplicates: #3198 Last updated: 2012-11-28 11:17:10 +0100 ## Comment 17821 Date: 2012-10-17 21:56:32 +0200 From: gordon &lt;<gordon>&gt; User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/535.19 (KHTML, like Gecko) Chrome/18.0.1025.151 Safari/535.19 Build Identifier: The following query crashes the server: mclient -d voc -s "copy select * from bc251 where length>25 into '/tmp/foo5';" Without the "where", it works: mclient -d voc -s "copy select * from bc251 into '/tmp/foo5';" The log file says: 2012-10-17 15:46:18 MSG merovingian[4714]: database 'voc' (12393) was killed by signal SIGSEGV Reproducible: Always Running with unreleased version 11.14.0 (45564:14983b3e103e). Didn't test with other versions. Fabian Groffen has the actual data (of table "bc251"), if need to reproduce. ## Comment 17822 Date: 2012-10-18 11:34:50 +0200 From: @grobian 11.14 is development code ## Comment 18014 Date: 2012-11-26 16:51:39 +0100 From: @njnes seems to crash on Oct2012 but no longer on default. ## Comment 18023 Date: 2012-11-27 10:57:25 +0100 From: duc &lt;<duc>&gt; Cannot be fixed now because the data "bc251" is confidential. ## Comment 18024 Date: 2012-11-27 11:01:39 +0100 From: duc &lt;<duc>&gt; No need to test because the data "bc251" is confidential. ## Comment 18174 Date: 2012-11-28 11:09:27 +0100 From: @njnes *** Bug #3198 has been marked as a duplicate of this bug. *** ## Comment 18180 Date: 2012-11-28 11:17:10 +0100 From: @njnes *** This bug has been marked as a duplicate of bug #3198 ***
Running "copy into file" with specific "where" crashes the server
https://api.github.com/repos/MonetDB/MonetDB/issues/3165/comments
0
2020-11-30T12:14:15Z
2024-06-28T13:17:30Z
https://github.com/MonetDB/MonetDB/issues/3165
753,427,871
3,165
[ "MonetDB", "MonetDB" ]
Date: 2012-10-16 16:29:54 +0200 From: John &lt;<j.m.lium27>&gt; To: clients devs &lt;<bugs-clients>&gt; Version: 11.13.3 (Oct2012) Last updated: 2012-11-22 13:58:49 +0100 ## Comment 17820 Date: 2012-10-16 16:29:54 +0200 From: John &lt;<j.m.lium27>&gt; User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_5) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.94 Safari/537.4 Build Identifier: I have a remote server hosting a monetdb instance. To access this server, I foward the monetdb port over ssh to the local machine. When I try to login to a working database with the jdbc client or through java code, I recieve the error: Database connect failed: Unsupported password hash: RIPEMD160 Reproducible: Always ### Steps to Reproduce: 1. From OSX, attempt to login to a password protected monetdb instance 2. Read the error message 3. ### Actual Results: Database connect failed: Unsupported password hash: RIPEMD160 ### Expected Results: Made a connection with the database ## Comment 17890 Date: 2012-11-07 18:46:48 +0100 From: @grobian How did you configure/install monetdb?
Database connect failed: Unsupported password hash: RIPEMD160
https://api.github.com/repos/MonetDB/MonetDB/issues/3164/comments
0
2020-11-30T12:14:12Z
2024-06-27T11:57:49Z
https://github.com/MonetDB/MonetDB/issues/3164
753,427,839
3,164
[ "MonetDB", "MonetDB" ]
Date: 2012-10-13 17:18:36 +0200 From: Valerio Aimale &lt;<valerio>&gt; To: MonetDB5 devs &lt;<bugs-monetdb5>&gt; Version: 11.13.5 (Oct2012-SP1) CC: @mlkersten, @drstmane, valerio Last updated: 2013-01-22 09:29:07 +0100 ## Comment 17801 Date: 2012-10-13 17:18:36 +0200 From: Valerio Aimale &lt;<valerio>&gt; User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:15.0) Gecko/20100101 Firefox/15.0.1 Build Identifier: when a large number of clients perform concurrently select operations, mserver5 SIGSEGVs in the the MAL namespace allocation/counter function putName() in mal_namespace.c. The for(l= nme[0]; l && namespace.nme[l]; l= namespace.link[l]) {} loop needs thread isolation, but the return clause has to be brought out of the loop/ Reproducible: Always ### Steps to Reproduce: 1. create a db named crashdb, release it and start it 2. using the following python script, load 5,000,000 rows into the database --- !/usr/bin/env python by Valerio G. Aimale <valerio@aimale.com> import random import sys import time import string def main(): C = string.letters + string.digits random.seed(42) for i in range(long(sys.argv[1])): row = [ str(random.randint(0,2**31)), str(random.randint(0,2**31)), str(random.randint(0,2**31)), '"' + "".join([random.choice(C) for i in range(random.randint(1,100))]) + '"' , '"' + "".join([random.choice(C) for i in range(random.randint(1,128))]) + '"', '"' + "".join([random.choice(C) for i in range(random.randint(1,8000))]) + '"', time.strftime("%Y-%m-%d", time.localtime(random.randint(946710000, 1325401200))), time.strftime("%Y-%m-%d", time.localtime(random.randint(946710000, 1325401200))), time.strftime("%Y-%m-%d", time.localtime(random.randint(946710000, 1325401200))) ] print "|".join(row) if __name__ == "__main__": main() --- and load them into the database with python gen_bigdata 5000000 | mclient crashdb -s "COPY INTO big_data FROM STDIN USING DELIMITERS '|','\\n','\"' NULL AS ''" - 3. create a file containing 10,000 random queries with the following python script: --- !/usr/bin/env python by Valerio G. Aimale <valerio@aimale.com> import monetdb.sql import random import sys def main(): random.seed(42) connection = monetdb.sql.connect(username="analysis", password="analysis", hostname="localhost", database="crashdb") cursor = connection.cursor() cursor.arraysize = 10000 cursor.execute('SELECT B, E FROM big_data LIMIT ' + sys.argv[1] ) data = [] for row in cursor.fetchall(): data.append(row) for i in range(1, long(sys.argv[1])): r = data[random.randint(0,len(data)-1)] print "SELECT A, D from big_Data where B=" + str(r[0]) + " AND E ='" + str(r[1]) + "';" if __name__ == "__main__": main() --- run as python gen_bigdata_queries 10000 > big_data_queries.sql then execute the queries concurrently as for i in `seq 1 40`; do cat big_data_queries.sql | mclient -d crashdb > /dev/null & done [need username and password in ~/.monetdb The server, after a few seconds will crash, every time. This test needs a server with at least 64Gb of RAM and a large number of cores. ### Actual Results: crash as reported in merovingian.log --- 2012-10-13 08:47:42 MSG merovingian[59959]: database 'crashdb' (59996) was killed by signal SIGSEGV --- crash as reported in syslog --- Oct 13 08:47:40 tut kernel: [11059659.466492] mserver5[32149]: segfault at 53281 ip 00007fe0567d75e0 sp 00007fe03b7fa828 error 4 in libc-2.13.so[7fe056753000+197000] --- ### Expected Results: server should not be crashing The trouble arises in putName(). If you run mserver5 under gdb, after cmopiling with --enable-debug, you will see the server crash in line 235 of mal_namespace.c: for(l= nme[0]; l && namespace.nme[l]; l= namespace.link[l]){ Several concurrent threads are trying to define a new namespace and stomp on each others' toes, while doing that. The for(l= nme[0]; l && namespace.nme[l]; l= namespace.link[l]){} loop needs thread isolation, but the early termination return clause has to be taken out of the for loop, to avoid guaranteed deadlocks. The following patch does that and solves the problem, under any magnitude of concurrency: ========================== --- mal_namespace.c.orig 2012-10-12 16:06:51.970821824 -0600 +++ mal_namespace.c 2012-10-12 15:44:14.078131058 -0600 @@ -228,9 +228,11 @@ { size_t l,top; char buf[MAXIDENTLEN]; + str str_to_return = NULL; if( nme == NULL) return NULL; + mal_set_lock(mal_contextLock,"putName"); for(l= nme[0]; l && namespace.nme[l]; l= namespace.link[l]){ ifdef _BACKUP_ chkName(l); @@ -264,9 +266,13 @@ l=k; } */ - return namespace.nme[l]; + str_to_return = namespace.nme[l]; + break; } } + mal_unset_lock(mal_contextLock,"putName"); + + if (str_to_return) return str_to_return; /* protect this, as it will be updated by multiple threads */ mal_set_lock(mal_contextLock,"putName"); ==================== cd /path/to/MonetDB-11.11.11/monetdb5/mal patch < mal_namespace.c.patch ==================================================================== root@tut:~/MonetDB-11.11.11 /usr/local/pkg/MonetDB-11.11.11/bin/mserver5 --version MonetDB 5 server v11.11.11 "Jul2012-SP2" (64-bit, 64-bit oids) Copyright (c) 1993-July 2008 CWI Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved Visit http://www.monetdb.org/ for further information Found 126.2GiB available memory, 48 available cpu cores Libraries: libpcre: 8.12 2011-01-15 (compiled with 8.12) openssl: OpenSSL 1.0.0e 6 Sep 2011 (compiled with OpenSSL 1.0.0e 6 Sep 2011) libxml2: 2.7.8 (compiled with 2.7.8) Compiled by: root@tut (x86_64-unknown-linux-gnu) Compilation: gcc -O3 -fomit-frame-pointer -pipe -O3 -march=opteron -Wp,-D_FORTIFY_SOURCE=2 Linking : /usr/bin/ld -m elf_x86_64 ## Comment 17802 Date: 2012-10-13 17:20:09 +0200 From: Valerio Aimale &lt;<valerio>&gt; Created attachment 149 generate data required for the test > Attached file: [gen_bigdata](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3163_gen_bigdata_149) (application/octet-stream, 1008 bytes) > Description: generate data required for the test ## Comment 17803 Date: 2012-10-13 17:20:31 +0200 From: Valerio Aimale &lt;<valerio>&gt; Created attachment 150 generate queries required for the test > Attached file: [gen_bigdata_queries](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3163_gen_bigdata_queries_150) (application/octet-stream, 696 bytes) > Description: generate queries required for the test ## Comment 17804 Date: 2012-10-13 17:20:58 +0200 From: Valerio Aimale &lt;<valerio>&gt; Created attachment 151 patch for mal_namespace.c > Attached file: [mal_namespace.c.patch](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3163_mal_namespace.c.patch_151) (text/plain, 715 bytes) > Description: patch for mal_namespace.c ## Comment 17805 Date: 2012-10-13 17:27:26 +0200 From: @mlkersten Thank you for the detailed analysis and providing a solution. We will review it and merge it into the respective bug/feature releases. regards, Martin Kersten ## Comment 17807 Date: 2012-10-13 17:33:55 +0200 From: Valerio Aimale &lt;<valerio>&gt; Created attachment 152 Schema for the big_data table > Attached file: [big_data_table.sql](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3163_big_data_table.sql_152) (text/plain, 202 bytes) > Description: Schema for the big_data table ## Comment 17808 Date: 2012-10-13 17:37:36 +0200 From: Valerio Aimale &lt;<valerio>&gt; Forgot to say, after creating the database, create a user called 'analysis', with password 'analysis'. --- CREATE USER "analysis" WITH PASSWORD 'analysis' NAME 'Analysis Explorer' SCHEMA "sys"; CREATE SCHEMA "analysis" AUTHORIZATION "analysis"; ALTER USER "analysis" SET SCHEMA "analysis"; --- After that, logged in as 'analysis', create the following table, before loading the data: ==================================== -- crash test CREATE TABLE "big_data" ( A INT, B INT, C INT, D VARCHAR(100), E VARCHAR(128), F VARCHAR(8000), G DATE, H DATE, I DATE ); =================================== your ~/.monetdb should look like ---- user=analysis password=analysis ---- ## Comment 17852 Date: 2012-10-28 16:26:18 +0100 From: Valerio Aimale &lt;<valerio>&gt; Version 11.13.3 still crashes with the same test. This is the patch for version 11.13.3: =========================================================== --- mal_namespace.c.orig 2012-10-28 09:24:48.555393313 -0600 +++ mal_namespace.c 2012-10-28 09:16:16.892918629 -0600 @@ -228,9 +228,11 @@ { size_t l,top; char buf[MAXIDENTLEN]; + str retstr = NULL; if( nme == NULL) return NULL; + MT_lock_set(&mal_contextLock, "putName"); for(l= nme[0]; l && namespace.nme[l]; l= namespace.link[l]){ ifdef _BACKUP_ chkName(l); @@ -264,9 +266,13 @@ l=k; } */ - return namespace.nme[l]; + retstr = namespace.nme[l]; + break; } } + MT_lock_unset(&mal_contextLock, "putName"); + + if (retstr) return retstr; /* protect this, as it will be updated by multiple threads */ MT_lock_set(&mal_contextLock, "putName"); ====================================== ## Comment 17853 Date: 2012-10-28 16:37:21 +0100 From: @grobian Martin, can you please take a look at this, thanks. ## Comment 17854 Date: 2012-10-28 19:09:12 +0100 From: Valerio Aimale &lt;<valerio>&gt; The patch for 11.13.3 in my previous comment (and also the original patch for 11.11.11 in the original bug report) pays a significant performance price. The following patch (for 11.13.3, achieves the same result (i.e. preventing the SIGSEGV) without any noticeable performance impact ==================================================== --- mal_namespace.c.orig 2012-10-28 09:24:48.555393313 -0600 +++ mal_namespace.c 2012-10-28 11:53:40.792026089 -0600 @@ -231,7 +231,8 @@ if( nme == NULL) return NULL; - for(l= nme[0]; l && namespace.nme[l]; l= namespace.link[l]){ + l= nme[0]; + while(l && namespace.nme[l]) { ifdef _BACKUP_ chkName(l); endif @@ -266,6 +267,9 @@ */ return namespace.nme[l]; } + MT_lock_set(&mal_contextLock, "putName"); + l = namespace.link[l]; + MT_lock_unset(&mal_contextLock, "putName"); } /* protect this, as it will be updated by multiple threads */ ====================================================== it replaces the for loop with a while loop, protecting the atomic operation l = namespace.link[l]; which is the only operation needing thread-isolation. Valerio ## Comment 17889 Date: 2012-11-07 18:46:03 +0100 From: @grobian Martin, did your recent changes include a fix for this problem? We cannot build Oct2012-SP1 if this isn't fixed/committed. ## Comment 18133 Date: 2012-11-27 15:50:41 +0100 From: @mlkersten The concurrency conflict has been addressed in the namespace in Oct branch. Running on my desktop and a small version of the database (5000), which is enough the create the load and 100 concurrent users (of which 64 are accepted) does not crash the server. However, if you run the script with a naively large sequence (eg. 1000) you will encounter bash/OS fork/resource limitations. ## Comment 18136 Date: 2012-11-27 15:54:18 +0100 From: @mlkersten Changeset [24c408dcf765](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=24c408dcf765) made by Martin Kersten <mk@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=24c408dcf765](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=24c408dcf765) Changeset description: Concurrency on namespace This patch addresses the bug #3163 The concurrency conflict has been addressed in the namespace in Oct branch. Running on my desktop and a small version of the database (5000), which is enough the create the load and 100 concurrent users (of which 64 are accepted) does not crash the server. However, if you run the script with a naively large sequence (eg. 1000) you will encounter bash/OS fork/resource limitations. ## Comment 18138 Date: 2012-11-27 15:58:10 +0100 From: @mlkersten Downscale severity until more counterproofs of instability are reported. ## Comment 18242 Date: 2012-12-08 22:36:53 +0100 From: @mlkersten Considered resolved. ## Comment 18267 Date: 2012-12-18 21:50:53 +0100 From: Valerio Aimale &lt;<valerio>&gt; Martin, I'm sorry to report that with version 11.13.5, the crash still happens: valerio@tut:~$ ps fax [...] 625 ? Ssl 1:04 /usr/local/pkg/MonetDB-11.13.5/bin/monetdbd start /data1/monetdb/dbfarm/ 49170 ? Ssl 126:09 \_ /usr/local/pkg/MonetDB-11.13.5/bin/mserver5 --set gdk_dbfarm /data1/monetdb/dbfarm [...] valerio@tut:~$ for i in `seq 1 40`; do cat big_data_queries | mclient -d crashdb >/dev/null & done [1] 51568 [2] 51570 [3] 51572 [4] 51574 [5] 51576 [6] 51578 [7] 51580 [8] 51582 [9] 51585 [10] 51587 [11] 51589 [12] 51592 [13] 51594 [14] 51596 [15] 51600 [16] 51602 [17] 51605 [18] 51607 [19] 51611 [20] 51613 [21] 51617 [22] 51620 [23] 51623 [24] 51625 [25] 51627 [26] 51630 [27] 51633 [28] 51635 [29] 51638 [30] 51640 [31] 51642 [32] 51644 [33] 51646 [34] 51649 [35] 51652 [36] 51655 [37] 51658 [38] 51661 [39] 51663 [40] 51666 valerio@tut:~$ Connection terminated Connection terminated Connection terminated Connection terminatedConnection terminated Connection terminatedConnection terminated Connection terminated Connection terminated Connection terminatedConnection terminated Connection terminated Connection terminatedConnection terminated Connection terminated Connection terminated Connection terminatedConnection terminated Connection terminated Connection terminatedConnection terminated Connection terminated Connection terminated Connection terminated Connection terminated Connection terminated Connection terminated Connection terminated Connection terminatedConnection terminated Connection terminated Connection terminated Connection terminated Connection terminatedConnection terminated Connection terminated Connection terminated Connection terminated Connection terminated Connection terminated valerio@tut:~$ from the merovingian.log: [...] 2012-12-18 13:48:44 MSG merovingian[625]: database 'crashdb' (51556) was killed by signal SIGSEGV [...] ## Comment 18268 Date: 2012-12-18 22:10:13 +0100 From: @mlkersten That is a pitty to hear. You happen to be able to get the stack trace of the running threads? ## Comment 18269 Date: 2012-12-18 23:56:02 +0100 From: Valerio Aimale &lt;<valerio>&gt; I think it crashes only with -O3 or -O4 in CFLAGS. I had to cook the configure script in order to allow concurrently -g -O4 and this is the backtrace 0 __strncmp_sse2 () at ../sysdeps/x86_64/multiarch/../strcmp.S:1112 1 0x00007f0a3d837f55 in putName (nme=0x7f0a3dda023a "sunique", len=7) at mal_namespace.c:239 2 0x00007f0a3dcc3bb6 in ESevaluate (empty=0x7f08a0a0dd70 "", mb=0x7f08a0965470, cntxt=<optimized out>) at opt_emptySet.c:55 3 OPTemptySetImplementation (cntxt=0x7f0a3800b4b8, mb=0x7f08a0965470, stk=<optimized out>, p=<optimized out>) at opt_emptySet.c:264 4 0x00007f0a3dce530f in OPTwrapper (cntxt=0x7f0a3800b4b8, mb=0x7f08a0965470, stk=0x0, p=<optimized out>) at opt_wrapper.c:171 5 0x00007f0a3dce08bb in optimizeMALBlock (cntxt=0x7f0a3800b4b8, mb=0x7f08a0965470) at opt_support.c:290 6 0x00007f0a366cfcf8 in addQueryToCache (c=<optimized out>) at sql_optimizer.c:521 7 0x00007f0a366cf446 in backend_dumpproc (be=0x7f0a2c6eb180, c=0x7f0a3800b4b8, cq=0x7f08a09997e0, s=0x7f08a0a1c800) at sql_gencode.c:2355 8 0x00007f0a366c7e8e in SQLparser (c=0x7f0a3800b4b8) at sql_scenario.c:1601 9 0x00007f0a3d84d1e4 in runPhase (phase=1, c=0x7f0a3800b4b8) at mal_scenario.c:522 10 runScenarioBody (c=0x7f0a3800b4b8) at mal_scenario.c:564 11 0x00007f0a3d84e36f in runScenario (c=0x7f0a3800b4b8) at mal_scenario.c:601 12 0x00007f0a3d84e410 in MSserveClient (dummy=0x7f0a3800b4b8) at mal_session.c:430 13 0x00007f0a3cdb8efc in start_thread (arg=0x7f09f64ba700) at pthread_create.c:304 14 0x00007f0a3caf359d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 15 0x0000000000000000 in ?? () ## Comment 18270 Date: 2012-12-18 23:56:51 +0100 From: Valerio Aimale &lt;<valerio>&gt; this is how I compiled it CFLAGS="-g -O4 -march=opteron" CXXFLAGS="-g -O4 -march=opteron" ./configure --prefix=/usr/local/pkg/MonetDB-11.13.5-debug --with-readline=/usr --enable-odbc --with-pthread=/usr --enable-debug --enable-optimize ## Comment 18271 Date: 2012-12-19 00:11:12 +0100 From: Valerio Aimale &lt;<valerio>&gt; Same when compiled with -O4 -g ================================== [Thread debugging using libthread_db enabled] Core was generated by `/usr/local/pkg/MonetDB-11.13.5-debug/bin/mserver5 --set gdk_dbfarm /data1/monet'. Program terminated with signal 11, Segmentation fault. 0 __strncmp_sse2 () at ../sysdeps/x86_64/multiarch/../strcmp.S:214 214 ../sysdeps/x86_64/multiarch/../strcmp.S: No such file or directory. in ../sysdeps/x86_64/multiarch/../strcmp.S (gdb) bt 0 __strncmp_sse2 () at ../sysdeps/x86_64/multiarch/../strcmp.S:214 1 0x00007fe9a1c152f8 in putName (nme=0x7fe99a938c9b "stdout", len=6) at mal_namespace.c:239 2 0x00007fe9a1bf6ee6 in newStmt (mb=0x7fe851753e00, module=0x7fe99a93a58a "io", name=0x7fe99a938c9b "stdout") at mal_builder.c:59 3 0x00007fe99a850a0e in _dumpstmt (sql=<optimized out>, mb=0x7fe851753e00, s=0x7fe8517848c0) at sql_gencode.c:2016 4 0x00007fe99a851892 in _dumpstmt (s=<optimized out>, mb=<optimized out>, sql=<optimized out>) at sql_gencode.c:707 5 backend_dumpstmt (be=0x7fe988d89f60, mb=0x7fe851753e00, s=0x7fe8517848c0) at sql_gencode.c:2206 6 0x00007fe99a8521b6 in backend_dumpproc (be=0x7fe988d89f60, c=0x7fe99c18ed78, cq=0x7fe851751a90, s=0x7fe8517848c0) at sql_gencode.c:2330 7 0x00007fe99a84adf8 in SQLparser (c=0x7fe99c18ed78) at sql_scenario.c:1601 8 0x00007fe9a1c2c1e6 in runPhase (phase=1, c=0x7fe99a938a63) at mal_scenario.c:522 9 runScenarioBody (c=0x7fe99a938a63) at mal_scenario.c:564 10 0x00007fe9a1c2d325 in runScenario (c=0x7fe99c18ed78) at mal_scenario.c:601 11 0x00007fe9a1c2d3e0 in MSserveClient (dummy=0x7fe99c18ed78) at mal_session.c:430 12 0x00007fe99f69cefc in start_thread (arg=0x7fe959676700) at pthread_create.c:304 13 0x00007fe99f3d759d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 14 0x0000000000000000 in ?? ( ## Comment 18272 Date: 2012-12-19 00:11:55 +0100 From: Valerio Aimale &lt;<valerio>&gt; I mean to sat "sam when compiled with gcc 4.7.2 and -O4 -g" ## Comment 18273 Date: 2012-12-19 00:28:32 +0100 From: Valerio Aimale &lt;<valerio>&gt; Martin, this is compiled with -O -g with gcc 4.7.2. As you can see, there were two threads inside the __strncmp_sse2 (): threads 31 and 1. This causes, I think, the SIGSEGV (gdb) info threads Id Target Id Frame 44 Thread 0x7f93cb20c700 (LWP 45084) 0x00007f93d096c613 in select () at ../sysdeps/unix/syscall-template.S:82 43 Thread 0x7f93cdb85700 (LWP 45083) 0x00007f93d096c613 in select () at ../sysdeps/unix/syscall-template.S:82 42 Thread 0x7f93c91fc700 (LWP 45181) __lll_lock_wait () at ../nptl/sysdeps/unix/sysv/linux/x86_64/lowlevellock.S:136 41 Thread 0x7f93c93fd700 (LWP 45179) 0x00007f93d2c29028 in BATsample (b=0x7f92357de0f8, n=128) at gdk_sample.c:83 40 Thread 0x7f93c95fe700 (LWP 45168) 0x00007f93d3136540 in putName (nme=0x1620f90 "str", len=3) at mal_namespace.c:234 39 Thread 0x7f93c97ff700 (LWP 45158) 0x00007f93d2c29030 in BATsample (b=0x7f924de07478, n=128) at gdk_sample.c:79 38 Thread 0x7f93cb00b700 (LWP 45085) 0x00007f93d096c613 in select () at ../sysdeps/unix/syscall-template.S:82 37 Thread 0x7f93d3b26740 (LWP 45082) 0x00007f93d096c613 in select () at ../sysdeps/unix/syscall-template.S:82 36 Thread 0x7f93c9e02700 (LWP 45144) BATkdiff (l=0x807ee0, r=0x15c7300) at gdk_setop.mx:860 35 Thread 0x7f93c9c01700 (LWP 45152) 0x00007f93d2c28fe1 in BATsample (b=0x7f9252ba5688, n=128) at gdk_sample.c:83 34 Thread 0x7f93ca003700 (LWP 45141) 0x00007f93d2c29028 in BATsample (b=0x7f92357a8108, n=128) at gdk_sample.c:83 33 Thread 0x7f93ca204700 (LWP 45138) GDKfree_ (blk=0x7f92357dd640) at gdk_utils.c:887 32 Thread 0x7f93ca405700 (LWP 45135) 0x00007f93d2c29000 in BATsample (b=0x7f9252b99aa8, n=128) at gdk_sample.c:83 31 Thread 0x7f93ca606700 (LWP 45129) __strncmp_sse2 () at ../sysdeps/x86_64/multiarch/../strcmp.S:215 30 Thread 0x7f93ca807700 (LWP 45127) 0x00007f93d3136544 in putName (nme=0x1620f90 "str", len=3) at mal_namespace.c:234 29 Thread 0x7f93caa08700 (LWP 45125) 0x00007f93d2c29028 in BATsample (b=0x7f9239a6a9b8, n=128) at gdk_sample.c:83 28 Thread 0x7f93cac09700 (LWP 45120) 0x00007f93d31245d8 in setLifespan (mb=0x7f923dc39d40) at mal_function.c:704 27 Thread 0x7f93cae0a700 (LWP 45115) BATsample (b=0x7f924a0571c8, n=128) at gdk_sample.c:79 26 Thread 0x7f9388cad700 (LWP 45214) 0x00007f93d2c29028 in BATsample (b=0x7f925ba26cd8, n=128) at gdk_sample.c:83 25 Thread 0x7f9388eae700 (LWP 45213) 0x00007f93d3136540 in putName (nme=0x1620f90 "str", len=3) at mal_namespace.c:234 24 Thread 0x7f93bbdfe700 (LWP 45198) __lll_lock_wait () at ../nptl/sysdeps/unix/sysv/linux/x86_64/lowlevellock.S:136 23 Thread 0x7f93890af700 (LWP 45212) 0x00007f93d2c29028 in BATsample (b=0x7f924a057ec8, n=128) at gdk_sample.c:83 22 Thread 0x7f93892b0700 (LWP 45211) 0x00007f93d2c29030 in BATsample (b=0x7f9239a78958, n=128) at gdk_sample.c:79 21 Thread 0x7f93894b1700 (LWP 45210) 0x00007f93d2c29028 in BATsample (b=0x7f925ec105a8, n=128) at gdk_sample.c:83 20 Thread 0x7f93896b2700 (LWP 45209) 0x00007f93d2c2900a in BATsample (b=0x7f9231752df8, n=128) at gdk_sample.c:83 19 Thread 0x7f939eb13700 (LWP 45208) BATsample (b=0x7f925ba235a8, n=128) at gdk_sample.c:79 18 Thread 0x7f93babf5700 (LWP 45207) 0x00007f93d2c29028 in BATsample (b=0x7f922972e7f8, n=128) at gdk_sample.c:83 17 Thread 0x7f93baff7700 (LWP 45205) 0x00007f93d313652e in putName (nme=0x1620f90 "str", len=3) at mal_namespace.c:234 16 Thread 0x7f93badf6700 (LWP 45206) BATsample (b=0x7f923dc97618, n=128) at gdk_sample.c:80 15 Thread 0x7f93bb1f8700 (LWP 45204) 0x00007f93d2c29028 in BATsample (b=0x7f924a04bf18, n=128) at gdk_sample.c:83 14 Thread 0x7f93bb3f9700 (LWP 45203) __lll_lock_wait () at ../nptl/sysdeps/unix/sysv/linux/x86_64/lowlevellock.S:136 13 Thread 0x7f93bb9fc700 (LWP 45200) __lll_unlock_wake () at ../nptl/sysdeps/unix/sysv/linux/x86_64/lowlevellock.S:373 12 Thread 0x7f93bb5fa700 (LWP 45202) 0x00007f93d3136544 in putName (nme=0x1620f90 "str", len=3) at mal_namespace.c:234 11 Thread 0x7f93bb7fb700 (LWP 45201) 0x00007f93d2c29028 in BATsample (b=0x7f9239a70518, n=128) at gdk_sample.c:83 10 Thread 0x7f93bbbfd700 (LWP 45199) 0x00007f93d2c29030 in BATsample (b=0x7f923dc6f508, n=128) at gdk_sample.c:79 9 Thread 0x7f93bbfff700 (LWP 45197) 0x00007f93d2c29028 in BATsample (b=0x7f9229756508, n=128) at gdk_sample.c:83 8 Thread 0x7f93c83f5700 (LWP 45196) 0x00007f93d2c2900a in BATsample (b=0x7f925ec08ee8, n=128) at gdk_sample.c:83 7 Thread 0x7f93c85f6700 (LWP 45195) BATsample (b=0x7f923db22e48, n=128) at gdk_sample.c:80 6 Thread 0x7f93c87f7700 (LWP 45194) 0x00007f93d2c29028 in BATsample (b=0x7f925b994d88, n=128) at gdk_sample.c:83 5 Thread 0x7f93c89f8700 (LWP 45193) BATsample (b=0x7f9245e03078, n=128) at gdk_sample.c:79 4 Thread 0x7f93c8bf9700 (LWP 45192) BATsample (b=0x7f92568811c8, n=128) at gdk_sample.c:79 3 Thread 0x7f93c9a00700 (LWP 45155) exp_create (sa=<optimized out>, type=1) at rel_exp.c:39 2 Thread 0x7f93c8dfa700 (LWP 45190) __lll_unlock_wake () at ../nptl/sysdeps/unix/sysv/linux/x86_64/lowlevellock.S:373 * 1 Thread 0x7f93c8ffb700 (LWP 45183) __strncmp_sse2 () at ../sysdeps/x86_64/multiarch/../strcmp.S:214 (gdb) bt 0 __strncmp_sse2 () at ../sysdeps/x86_64/multiarch/../strcmp.S:214 1 0x00007f93d313650d in putName (nme=0x7f924a0fe700 "s884_16", len=7) at mal_namespace.c:239 2 0x00007f93cbe0d041 in backend_dumpproc (be=0x7f93c0bc1230, c=0x7f93cd7291a0, cq=0x7f924a056640, s=0x7f924a0f5120) at sql_gencode.c:2290 3 0x00007f93cbe0658d in SQLparser (c=0x7f93cd7291a0) at sql_scenario.c:1601 4 0x00007f93d31488e7 in runPhase (c=<optimized out>, phase=<optimized out>) at mal_scenario.c:522 5 0x00007f93d3148a30 in runScenarioBody (c=0x7f924a0fe4c8) at mal_scenario.c:564 6 0x00007f93d31495bd in runScenario (c=0x7f93cd7291a0) at mal_scenario.c:601 7 0x00007f93d3149705 in MSserveClient (dummy=0x7f93cd7291a0) at mal_session.c:430 8 0x00007f93d0c38efc in start_thread (arg=0x7f93c8ffb700) at pthread_create.c:304 9 0x00007f93d097359d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 10 0x0000000000000000 in ?? () ## Comment 18275 Date: 2012-12-19 11:23:11 +0100 From: @mlkersten Thank you for the detailed analysis. Attempting to reproduce the error on my desktop machine and Feb2013 code. I built the complete 5M row database as prescribed. I restarted the server and attached gdb. I ran the sequence of 40 concurrent users as prescribed, watching it using 'top' It all seems to run smoothly sofar (still running). One of the effects of this test is that namespace becomes polluted by a large number of query names, e.g. s884-16, which are never garbage collected. This leads to a call to expandNamespace, which does not re-alloc, but performs a malloc+copy+free. This could explain the SIGSEGV. Resolutions: 1) be more conservative in name generation in SQL 2) use proper re-alloc code. ## Comment 18276 Date: 2012-12-19 11:35:56 +0100 From: @mlkersten The test run finished without causing a segfault. 1) the code will be patched to avoid the possible conflict during expandNamespave. ## Comment 18277 Date: 2012-12-19 11:40:48 +0100 From: @drstmane Valerio, could you compile MonetDB such that it does not use the SSE2 version of strncmp, e.g., by not using --march=opteron, and see whether the problem (segfault) persists? Martin, if done correctly (incl. checking for success), and gracefully bailing out otherwise), malloc, copy, free (instead of realloc) by themselves should not cause any segfaults. ## Comment 18278 Date: 2012-12-19 11:43:32 +0100 From: @drstmane Valerio, would you have an option to upgrade to Oct2012-SP1 (http://dev.monetdb.org/downloads/sources/Oct2012-SP1/) or even the upcoming Oct2012-SP2 (http://dev.monetdb.org/downloads/testing/sources/Oct2012-SP2/), and check, whether the problem still persists (with --march=opteron, i.e., with __strncmp_sse2())? ## Comment 18279 Date: 2012-12-19 11:50:56 +0100 From: @drstmane Oops, I just saw that Valerio already tested Oct2012-SP1. ## Comment 18280 Date: 2012-12-19 17:15:08 +0100 From: Valerio Aimale &lt;<valerio>&gt; Re: crashing in __strncmp_sse2, my opinion is that is just an epiphenomenon, not the real cause. That is where two or more threads meet, just due to stochastic, non deterministic behavior (execution timing, cpu load, disk speed varying over time etc.) As a proof of that, at time, I would say 1 over 10 crashes, the problem manifests not as a crash, but as clients complaining of undefined namespaces; it's proof that threads might might meet elsewhere and "trash" namespace definitions. When there are undefined namespaces, this is what I get on the console of the clients [...] TypeException:user.s989_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s990_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s991_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s992_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s993_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s994_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s995_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s996_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s997_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s998_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s999_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1000_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1001_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1002_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1003_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1004_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1005_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1006_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1007_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1008_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1009_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1010_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1011_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1012_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1013_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1014_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1015_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s1016_24[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s947_15[85]:'io.stdout' undefined in: _114:any := io.stdout() program contains errors TypeException:user.s948_15[85]:'io.stdout' undefined in: _114:any := io.stdout() [...] I will try without march=opteron definition ## Comment 18281 Date: 2012-12-19 18:15:43 +0100 From: Valerio Aimale &lt;<valerio>&gt; compiled with CFLAGS="-g -O4" still crashes in __strncmp_sse2. I guess it is an optimization in libc. It probably checks where the cpu has sse2 instruction, and, if yes, it will use the strncmp_sse2() ================= [Thread debugging using libthread_db enabled] Core was generated by `/usr/local/pkg/MonetDB-11.13.5-debug/bin/mserver5 --set gdk_dbfarm /data1/monet'. Program terminated with signal 11, Segmentation fault. 0 __strncmp_sse2 () at ../sysdeps/x86_64/multiarch/../strcmp.S:214 214 ../sysdeps/x86_64/multiarch/../strcmp.S: No such file or directory. in ../sysdeps/x86_64/multiarch/../strcmp.S (gdb) info threads Id Target Id Frame 44 Thread 0x7f6bf60a4700 (LWP 46533) 0x00007f6bfa729613 in select () at ../sysdeps/unix/syscall-template.S:82 43 Thread 0x7f6be3fff700 (LWP 46660) BATsample (b=0x7f697ada3418, n=128) at gdk_sample.c:79 42 Thread 0x7f6bf02ef700 (LWP 46659) 0x00007f6bfb44f115 in putName (nme=0x1618000 "str", len=3) at mal_namespace.c:238 41 Thread 0x7f6bf04f0700 (LWP 46658) BATsample (b=0x7f696086c188, n=128) at gdk_sample.c:79 40 Thread 0x7f6bf06f1700 (LWP 46657) 0x00007f6bfaf2701a in BATsample (b=0x7f69871daa38, n=128) at gdk_sample.c:83 39 Thread 0x7f6bf08f2700 (LWP 46655) 0x00007f6bfaf27023 in BATsample (b=0x7f69608a6c78, n=128) at gdk_sample.c:83 38 Thread 0x7f6bf0af3700 (LWP 46654) 0x00007f6bfaf2702b in BATsample (b=0x7f697eba7298, n=128) at gdk_sample.c:79 37 Thread 0x7f6bf0cf4700 (LWP 46637) 0x00007f6bfaf27023 in BATsample (b=0x7f698716f128, n=128) at gdk_sample.c:83 36 Thread 0x7f6bf0ef5700 (LWP 46636) BATsample (b=0x7f6976920498, n=128) at gdk_sample.c:79 35 Thread 0x7f6bf10f6700 (LWP 46633) 0x00007f6bfb44f115 in putName (nme=0x1618000 "str", len=3) at mal_namespace.c:238 34 Thread 0x7f6bf12f7700 (LWP 46632) 0x00007f6bfaf2702b in BATsample (b=0x7f696e296f28, n=128) at gdk_sample.c:79 33 Thread 0x7f6bf14f8700 (LWP 46628) 0x00007f6bfaf27023 in BATsample (b=0x7f69768ca8d8, n=128) at gdk_sample.c:83 32 Thread 0x7f6bf3709700 (LWP 46534) 0x00007f6bfa729613 in select () at ../sysdeps/unix/syscall-template.S:82 31 Thread 0x7f6bf16f9700 (LWP 46625) BATsample (b=0x7f696a451628, n=128) at gdk_sample.c:82 30 Thread 0x7f6bf3508700 (LWP 46535) 0x00007f6bfa729613 in select () at ../sysdeps/unix/syscall-template.S:82 29 Thread 0x7f6bf18fa700 (LWP 46622) 0x00007f6bfaf27023 in BATsample (b=0x7f696086afb8, n=128) at gdk_sample.c:83 28 Thread 0x7f6bf1afb700 (LWP 46618) 0x00007f6bfaf27023 in BATsample (b=0x7f698fd898d8, n=128) at gdk_sample.c:83 27 Thread 0x7f6bf1cfc700 (LWP 46616) 0x00007f6bfb44f104 in putName (nme=0x1618000 "str", len=3) at mal_namespace.c:234 26 Thread 0x7f6bf1efd700 (LWP 46607) 0x00007f6bfaf27023 in BATsample (b=0x7f698be217c8, n=128) at gdk_sample.c:83 25 Thread 0x7f6bf20fe700 (LWP 46603) 0x00007f6bfb44f104 in putName (nme=0x1618000 "str", len=3) at mal_namespace.c:234 24 Thread 0x7f6bf22ff700 (LWP 46602) BATsample (b=0x7f6983c53e18, n=128) at gdk_sample.c:79 23 Thread 0x7f6bf2500700 (LWP 46599) 0x00007f6bfaf27023 in BATsample (b=0x7f696a40efa8, n=128) at gdk_sample.c:83 22 Thread 0x7f6bf2701700 (LWP 46595) BATsample (b=0x7f69643709f8, n=128) at gdk_sample.c:83 21 Thread 0x7f6bf2902700 (LWP 46591) 0x00007f6bfaf27023 in BATsample (b=0x3711bda8, n=128) at gdk_sample.c:83 20 Thread 0x7f6bf2b03700 (LWP 46589) 0x00007f6bfaf2702b in BATsample (b=0x7f697ebab318, n=128) at gdk_sample.c:79 19 Thread 0x7f6bf2d04700 (LWP 46585) BATsample (b=0x7f695842ab48, n=128) at gdk_sample.c:79 18 Thread 0x7f6bf2f05700 (LWP 46583) 0x00007f6bfaf2702b in BATsample (b=0x7f6960872cd8, n=128) at gdk_sample.c:79 17 Thread 0x7f6bf3106700 (LWP 46575) 0x00007f6bfaf27023 in BATsample (b=0x7f69642f2ed8, n=128) at gdk_sample.c:83 16 Thread 0x7f6bf3307700 (LWP 46573) 0x00007f6bfaf27023 in BATsample (b=0x7f696a40df28, n=128) at gdk_sample.c:83 15 Thread 0x7f6bfbeb2740 (LWP 46532) 0x00007f6bfa729613 in select () at ../sysdeps/unix/syscall-template.S:82 14 Thread 0x7f6be23f1700 (LWP 46674) 0x00007f6bfb44f0f0 in putName (nme=0x1618000 "str", len=3) at mal_namespace.c:234 13 Thread 0x7f6be25f2700 (LWP 46673) 0x00007f6bfb44f104 in putName (nme=0x1618000 "str", len=3) at mal_namespace.c:234 12 Thread 0x7f6be27f3700 (LWP 46672) BATsample (b=0x7f69871437f8, n=128) at gdk_sample.c:82 11 Thread 0x7f6be29f4700 (LWP 46671) 0x00007f6bfaf27023 in BATsample (b=0x7f696a412c88, n=128) at gdk_sample.c:83 10 Thread 0x7f6be2bf5700 (LWP 46670) BATsample (b=0x7f6972ad88b8, n=128) at gdk_sample.c:80 9 Thread 0x7f6be2df6700 (LWP 46669) 0x00007f6bfb44f104 in putName (nme=0x7f6bfb9bc26c "sortReverse", len=11) at mal_namespace.c:234 8 Thread 0x7f6be2ff7700 (LWP 46668) 0x00007f6bfaf27023 in BATsample (b=0x7f69642e6a58, n=128) at gdk_sample.c:83 7 Thread 0x7f6be31f8700 (LWP 46667) 0x00007f6bfaf27023 in BATsample (b=0x7f696e1ffcf8, n=128) at gdk_sample.c:83 6 Thread 0x7f6be33f9700 (LWP 46666) 0x00007f6bfaf27023 in BATsample (b=0x7f697ad9f4a8, n=128) at gdk_sample.c:83 5 Thread 0x7f6be35fa700 (LWP 46665) 0x00007f6bfaf27023 in BATsample (b=0x3711ddb8, n=128) at gdk_sample.c:83 4 Thread 0x7f6be37fb700 (LWP 46664) 0x00007f6bfb44f104 in putName (nme=0x7f6bf43ed597 "stdout", len=6) at mal_namespace.c:234 3 Thread 0x7f6be39fc700 (LWP 46663) BATsample (b=0x7f69583af298, n=128) at gdk_sample.c:79 2 Thread 0x7f6be3bfd700 (LWP 46662) BATsample (b=0x7f6964370018, n=128) at gdk_sample.c:83 * 1 Thread 0x7f6be3dfe700 (LWP 46661) __strncmp_sse2 () at ../sysdeps/x86_64/multiarch/../strcmp.S:214 gdb) bt 0 __strncmp_sse2 () at ../sysdeps/x86_64/multiarch/../strcmp.S:214 1 0x00007f6bfb44f125 in putName (nme=0x7f6bf43ed597 "stdout", len=6) at mal_namespace.c:239 2 0x00007f6bfb430da7 in newStmt (mb=0x7f698be1bec0, module=0x7f6bf43eeeba "io", name=0x7f6bf43ed597 "stdout") at mal_builder.c:59 3 0x00007f6bf430cd37 in _dumpstmt (sql=<optimized out>, mb=0x7f698be1bec0, s=0x7f698be33820) at sql_gencode.c:2016 4 0x00007f6bf430d9f2 in _dumpstmt (s=<optimized out>, mb=<optimized out>, sql=<optimized out>) at sql_gencode.c:707 5 backend_dumpstmt (be=0x7f6be8a3c460, mb=0x7f698be1bec0, s=0x7f698be33820) at sql_gencode.c:2206 6 0x00007f6bf430e55c in backend_dumpproc (be=0x7f6be8a3c460, c=0x7f6bf5c4a3a8, cq=0x7f698be1b090, s=0x7f698be33820) at sql_gencode.c:2330 7 0x00007f6bf4306f36 in SQLparser (c=0x7f6bf5c4a3a8) at sql_scenario.c:1601 8 0x00007f6bfb463bbc in runPhase (phase=1, c=0x7f6bf5c4a3a8) at mal_scenario.c:522 9 runScenarioBody (c=0x7f6bf5c4a3a8) at mal_scenario.c:564 10 0x00007f6bfb464d0f in runScenario (c=0x7f6bf5c4a3a8) at mal_scenario.c:601 11 0x00007f6bfb464db8 in MSserveClient (dummy=0x7f6bf5c4a3a8) at mal_session.c:430 12 0x00007f6bfa9f5efc in start_thread (arg=0x7f6be3dfe700) at pthread_create.c:304 13 0x00007f6bfa73059d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 14 0x0000000000000000 in ?? () ## Comment 18282 Date: 2012-12-19 18:46:18 +0100 From: @drstmane Thanks! Since we cannot yet reproduce the segfault, could you try whether you can reproduce it also with a non-optimized build (from scratch), preferably configured without setting CFLAGS and using options --disable-optimize --enable-debug --enable-assert ? If that does not trigger a segfault, also an optimized build (from scratch) with CFLAGS="-g -O4 -mno-sse2" would be interesting ... ## Comment 18283 Date: 2012-12-19 18:51:34 +0100 From: @grobian The libc is compiled with SSE support, so it seems unlikely compilation settings for mserver5 will make any difference in it (libc) using the sse-optimised strcmp. ## Comment 18284 Date: 2012-12-19 18:54:28 +0100 From: Valerio Aimale &lt;<valerio>&gt; I agree. The sse2 optimization is in libc. ## Comment 18285 Date: 2012-12-19 19:02:07 +0100 From: @drstmane good point. my fault. thanks. ## Comment 18286 Date: 2012-12-19 19:42:24 +0100 From: Valerio Aimale &lt;<valerio>&gt; I want you guys to have the full log of clients' stderr when the crash manifests as undefined namespaces. You can download it from http://www.aimale.com/log.xz it is 10Mb compressed and 0.5GB when uncompressed. I'm not sure it is that informative. ## Comment 18287 Date: 2012-12-19 19:46:57 +0100 From: Valerio Aimale &lt;<valerio>&gt; Compiled with --disable-optimize --enable-debug --enable-assert from a pristine source tarball, as requested. This crashes as: (gdb) info threads Id Target Id Frame 44 Thread 0x7f227e215700 (LWP 17952) 0x00007f22854b9613 in select () at ../sysdeps/unix/syscall-template.S:82 43 Thread 0x7f228745d740 (LWP 17949) 0x00007f22854b9613 in select () at ../sysdeps/unix/syscall-template.S:82 42 Thread 0x7f22759ec700 (LWP 18089) 0x00007f22854bcac7 in mprotect () at ../sysdeps/unix/syscall-template.S:82 41 Thread 0x7f2280e2e700 (LWP 17950) 0x00007f22854b9613 in select () at ../sysdeps/unix/syscall-template.S:82 40 Thread 0x7f227ca09700 (LWP 18039) BATsample (b=0x7f22636d4508, n=128) at gdk_sample.c:79 39 Thread 0x7f227cc0a700 (LWP 18036) 0x00007f2285d414aa in BATsample (b=0x7f21fc114b08, n=128) at gdk_sample.c:83 38 Thread 0x7f227ce0b700 (LWP 18035) 0x00007f2285d414ba in BATsample (b=0x7f21fc0c68c8, n=128) at gdk_sample.c:79 37 Thread 0x7f227d00c700 (LWP 18023) 0x00007f2285d4147e in BATsample (b=0x7f21f85941a8, n=128) at gdk_sample.c:83 36 Thread 0x7f227d20d700 (LWP 18021) BATsample (b=0x7f21f8548158, n=128) at gdk_sample.c:80 35 Thread 0x7f227e416700 (LWP 17951) 0x00007f22854b9613 in select () at ../sysdeps/unix/syscall-template.S:82 34 Thread 0x7f227d40e700 (LWP 18019) 0x00007f2285d414aa in BATsample (b=0x7f21fc13c2f8, n=128) at gdk_sample.c:83 33 Thread 0x7f227d60f700 (LWP 18015) 0x00007f2285d41451 in BATsample (b=0x7f22672b64d8, n=128) at gdk_sample.c:83 32 Thread 0x7f227d810700 (LWP 18008) 0x00007f2285d414c5 in BATsample (b=0x7339c98, n=128) at gdk_sample.c:79 31 Thread 0x7f227da11700 (LWP 18007) 0x00007f2285d4149e in BATsample (b=0x7f225f2b4898, n=128) at gdk_sample.c:83 30 Thread 0x7f227dc12700 (LWP 18002) 0x00007f2285d41451 in BATsample (b=0x7f225f3992f8, n=128) at gdk_sample.c:83 29 Thread 0x7f227de13700 (LWP 17999) 0x00007f2285d414c7 in BATsample (b=0x7f2257890a68, n=128) at gdk_sample.c:79 28 Thread 0x7f227e014700 (LWP 17994) 0x00007f2285d41472 in BATsample (b=0x7f2257866748, n=128) at gdk_sample.c:83 27 Thread 0x7f22751e8700 (LWP 18093) 0x00007f2285d41483 in BATsample (b=0x7f2200b2ee28, n=128) at gdk_sample.c:83 26 Thread 0x7f22753e9700 (LWP 18092) 0x00007f2285d414aa in BATsample (b=0x7f225783d4d8, n=128) at gdk_sample.c:83 25 Thread 0x7f22755ea700 (LWP 18091) 0x00007f2285d414aa in BATsample (b=0x7f224f7925f8, n=128) at gdk_sample.c:83 24 Thread 0x7f22757eb700 (LWP 18090) 0x00007f2285d4149e in BATsample (b=0x7f22672baa78, n=128) at gdk_sample.c:83 23 Thread 0x7f2275bed700 (LWP 18088) 0x00007f2285d414ba in BATsample (b=0x7f225774ca48, n=128) at gdk_sample.c:79 22 Thread 0x7f2275dee700 (LWP 18087) 0x00007f2285d41483 in BATsample (b=0x7f2213d2e9c8, n=128) at gdk_sample.c:83 21 Thread 0x7f2275fef700 (LWP 18086) 0x00007f2285d41472 in BATsample (b=0x7f226aed1ee8, n=128) at gdk_sample.c:83 20 Thread 0x7f22761f0700 (LWP 18085) 0x00007f2285d4149a in BATsample (b=0x7f2267301c08, n=128) at gdk_sample.c:83 19 Thread 0x7f22763f1700 (LWP 18084) BATsample (b=0x7f22637c83a8, n=128) at gdk_sample.c:79 18 Thread 0x7f22765f2700 (LWP 18083) 0x00007f2285d4147e in BATsample (b=0x7f226aef7858, n=128) at gdk_sample.c:83 17 Thread 0x7f22767f3700 (LWP 18082) 0x00007f2285d4149e in BATsample (b=0x7f22637cf848, n=128) at gdk_sample.c:83 16 Thread 0x7f22769f4700 (LWP 18081) 0x00007f2285d4147e in BATsample (b=0x7f224f792da8, n=128) at gdk_sample.c:83 15 Thread 0x7f2276bf5700 (LWP 18080) 0x00007f2285d414ba in BATsample (b=0x7f226fe67428, n=128) at gdk_sample.c:79 14 Thread 0x7f2276df6700 (LWP 18079) 0x00007f2285d414ba in BATsample (b=0x7f2200a6fc28, n=128) at gdk_sample.c:79 13 Thread 0x7f2276ff7700 (LWP 18078) 0x00007f2285d414c7 in BATsample (b=0x7f2213cdf6f8, n=128) at gdk_sample.c:79 12 Thread 0x7f22771f8700 (LWP 18075) 0x00007f2285d4149e in BATsample (b=0x7f226fe93278, n=128) at gdk_sample.c:83 11 Thread 0x7f22773f9700 (LWP 18073) 0x00007f2285d41451 in BATsample (b=0x7f2213ce6ce8, n=128) at gdk_sample.c:83 10 Thread 0x7f22775fa700 (LWP 18072) 0x00007f2285d414aa in BATsample (b=0x7f224f688ec8, n=128) at gdk_sample.c:83 9 Thread 0x7f22777fb700 (LWP 18068) 0x00007f2285d4149e in BATsample (b=0x7f2263664388, n=128) at gdk_sample.c:83 8 Thread 0x7f22779fc700 (LWP 18064) 0x00007f2285d414c2 in BATsample (b=0x7f226fe3fe28, n=128) at gdk_sample.c:79 7 Thread 0x7f2277bfd700 (LWP 18058) 0x00007f2285d4149a in BATsample (b=0x7f224f7b3f78, n=128) at gdk_sample.c:83 6 Thread 0x7f2277dfe700 (LWP 18054) 0x00007f2285d414ba in BATsample (b=0x7f22672dc928, n=128) at gdk_sample.c:79 5 Thread 0x7f2277fff700 (LWP 18051) BATsample (b=0x7f221544b358, n=128) at gdk_sample.c:80 4 Thread 0x7f227c205700 (LWP 18049) 0x00007f2285d414c7 in BATsample (b=0x73615c8, n=128) at gdk_sample.c:79 3 Thread 0x7f227c406700 (LWP 18046) 0x00007f2285d4149a in BATsample (b=0x7f2263750628, n=128) at gdk_sample.c:83 2 Thread 0x7f227c607700 (LWP 18044) 0x00007f2285d4149e in BATsample (b=0x7f21fc0eb918, n=128) at gdk_sample.c:83 * 1 Thread 0x7f227c808700 (LWP 18042) 0x00007f22864366e7 in putName (nme=0x2cd5fc0 "str", len=3) at mal_namespace.c:234 (gdb) bt 0 0x00007f22864366e7 in putName (nme=0x2cd5fc0 "str", len=3) at mal_namespace.c:234 1 0x00007f228640a5d2 in newStmt1 (mb=0x7f22154734a0, module=0x1f32f10 "calc", name=0x2cd5fc0 "str") at mal_builder.c:71 2 0x00007f227f022578 in _dumpstmt (sql=0x7f22709be8e0, mb=0x7f22154734a0, s=0x7f22154a6700) at sql_gencode.c:1765 3 0x00007f227f024720 in backend_dumpstmt (be=0x7f22709be8e0, mb=0x7f22154734a0, s=0x7f221549eb20) at sql_gencode.c:2206 4 0x00007f227f02503a in backend_dumpproc (be=0x7f22709be8e0, c=0x7f22809d1858, cq=0x7f22153d3170, s=0x7f221549eb20) at sql_gencode.c:2330 5 0x00007f227f018bcc in SQLparser (c=0x7f22809d1858) at sql_scenario.c:1601 6 0x00007f2286451549 in runPhase (c=0x7f22809d1858, phase=1) at mal_scenario.c:522 7 0x00007f2286451681 in runScenarioBody (c=0x7f22809d1858) at mal_scenario.c:564 8 0x00007f22864518fa in runScenario (c=0x7f22809d1858) at mal_scenario.c:601 9 0x00007f228645282e in MSserveClient (dummy=0x7f22809d1858) at mal_session.c:430 10 0x00007f2285785efc in start_thread (arg=0x7f227c808700) at pthread_create.c:304 11 0x00007f22854c059d in clone () at ../sysdeps/unix/sysv/linux/x86_64/clone.S:112 12 0x0000000000000000 in ?? () This crash is solved by the patch I previously posted: ==================================================== --- mal_namespace.c.orig 2012-10-28 09:24:48.555393313 -0600 +++ mal_namespace.c 2012-10-28 11:53:40.792026089 -0600 @@ -231,7 +231,8 @@ if( nme == NULL) return NULL; - for(l= nme[0]; l && namespace.nme[l]; l= namespace.link[l]){ + l= nme[0]; + while(l && namespace.nme[l]) { ifdef _BACKUP_ chkName(l); endif @@ -266,6 +267,9 @@ */ return namespace.nme[l]; } + MT_lock_set(&mal_contextLock, "putName"); + l = namespace.link[l]; + MT_lock_unset(&mal_contextLock, "putName"); } /* protect this, as it will be updated by multiple threads */ ====================================================== ## Comment 18288 Date: 2012-12-19 20:01:38 +0100 From: @drstmane As far as I know, a similar patch is in the upcoming Oct2012-SP2 release cf., http://dev.monetdb.org/hg/MonetDB/rev/24c408dcf765 Could you try that one? cf., http://dev.monetdb.org/downloads/testing/sources/Oct2012-SP2/ ## Comment 18289 Date: 2012-12-19 20:25:13 +0100 From: Valerio Aimale &lt;<valerio>&gt; Stefan, I think I've tried something similar. If you look at Comment 7 above, that was my first attempt at a fix. However, bracketing the whole loop for(l= nme[0]; l && namespace.nme[l]; l= namespace.link[l]){ with thread isolation, pays a significant performance price. All threads pile up at the loop entrance. Instead, by bracketing only l = namespace.link[l]; performance is virtually unmodified. Seeing the crashes we saw with -O4, strncmp(nme,namespace.nme[l],len) == 0 might have to be bracketed too with thread isolation too. ## Comment 18290 Date: 2012-12-19 20:46:47 +0100 From: @mlkersten I am preparing a different solution to the namespace implementation to tackle the two problems noted before. It requires a different approach to be safe under such stress situations. regards, Martin ## Comment 18291 Date: 2012-12-20 21:57:49 +0100 From: @mlkersten Changeset [bd3853eda3ee](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=bd3853eda3ee) made by Martin Kersten <mk@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=bd3853eda3ee](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=bd3853eda3ee) Changeset description: Make namespace more resilient A new namespace manager has been introduced, which allows for concurrent reads without locks. Writes in the structure are protected with locks. It significantly improves the running time of the test mentioned in bug #3163 . The server startup seems slightly longer (20ms), because now we use separate malloced structures. The patch does not address the current SQL limitation to produce unique persistent names for all queries once cached. ## Comment 18292 Date: 2012-12-20 21:58:14 +0100 From: @mlkersten A new namespace manager has been introduced, which allows for concurrent reads without locks. Writes in the structure are protected with locks. It significantly improves the running time of this test case. The startup cost is slightly longer, because now we use separate malloced structures. The patch does not address the current SQL limitation to produce unique persistent names for all queries once cached. Please confirm effectiveness of this patch. ## Comment 18293 Date: 2012-12-20 22:03:12 +0100 From: @mlkersten triple run of the experiment with the new namespace manager does not lead to SEGFAULTs on my desktop machine. ## Comment 18294 Date: 2012-12-20 22:04:15 +0100 From: Valerio Aimale &lt;<valerio>&gt; Thanks, Martin. I will test and report ## Comment 18295 Date: 2012-12-20 22:49:33 +0100 From: Valerio Aimale &lt;<valerio>&gt; Martin, I have plugged in this file http://dev.monetdb.org/hg/MonetDB/raw-file/bd3853eda3ee/monetdb5/mal/mal_namespace.c into a pristine source tree of MonetDB 11.13.5 The variable mal_namespaceLock is used but not defined in the new mal_namespace.c , preventing compilation. ## Comment 18296 Date: 2012-12-20 22:56:37 +0100 From: @mlkersten I had patched the Feb2013 branch. This includes the following code. mal.c:MT_Lock mal_namespaceLock; mal.c: MT_lock_init( &mal_namespaceLock, "mal_namespaceLock"); mal.h:mal_export MT_Lock mal_namespaceLock; mal_namespace.c: MT_lock_set(&mal_namespaceLock, "finishNamespace"); mal_namespace.c: MT_lock_unset(&mal_namespaceLock, "finishNamespace"); mal_namespace.c: MT_lock_set(&mal_namespaceLock, "putName"); mal_namespace.c: MT_lock_unset(&mal_namespaceLock, "putName"); ## Comment 18297 Date: 2012-12-21 01:06:44 +0100 From: Valerio Aimale &lt;<valerio>&gt; Martin, the first tests are very good. I ran the usual 40 concurrent clients 4 times. Only once I had a crash: 2012-12-20 15:32:01 ERR crashdb[35830]: mserver5: opt_pipes.c:520: compileOptimizer: Assertion `c != ((void *)0)' failed. 2012-12-20 15:32:01 ERR crashdb[35830]: mserver5: opt_pipes.c:520: compileOptimizer: Assertion `c != ((void *)0)' failed. 2012-12-20 15:32:01 ERR crashdb[35830]: mserver5: opt_pipes.c:520: compileOptimizer: Assertion `c != ((void *)0)' failed. 2012-12-20 15:32:01 ERR crashdb[35830]: mserver5: opt_pipes.c:520: compileOptimizer: Assertion `c != ((void *)0)' failed. 2012-12-20 15:32:01 ERR crashdb[35830]: mserver5: opt_pipes.c:520: compileOptimizer: Assertion `c != ((void *)0)' failed. 2012-12-20 15:32:01 ERR crashdb[35830]: mserver5: opt_pipes.c:520: compileOptimizer: Assertion `c != ((void *)0)' failed. 2012-12-20 15:32:01 MSG merovingian[33044]: database 'crashdb' (35830) was killed by signal SIGABRT The other three 3 times it worked very well without a glitch. ## Comment 18298 Date: 2012-12-21 08:30:06 +0100 From: @mlkersten Indeed. Internally a client record was taken from the pool for compilation. With the stress test under consideration, there may not be left a client slot by the time you reach that point. A patch is in testing. ## Comment 18299 Date: 2012-12-21 09:17:29 +0100 From: @mlkersten Patch committed. It uses a static client record instead now. The (single) test run passes. ## Comment 18364 Date: 2013-01-22 09:29:07 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
mserver5 crashes with large number of concurrent clients
https://api.github.com/repos/MonetDB/MonetDB/issues/3163/comments
0
2020-11-30T12:14:08Z
2024-06-27T11:57:48Z
https://github.com/MonetDB/MonetDB/issues/3163
753,427,791
3,163
[ "MonetDB", "MonetDB" ]
Date: 2012-10-13 16:05:58 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; To: GDK devs &lt;<bugs-common>&gt; Version: -- development CC: ashishk, y.kargin Depends on: #2541 Last updated: 2016-04-11 11:43:16 +0200 ## Comment 17800 Date: 2012-10-13 16:05:58 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.94 Safari/537.4 Build Identifier: 5098 ashish 20 0 1690m 915m 5044 S 0 45.7 1:04.30 mserver5 Reproducible: Always ### Steps to Reproduce: 1.Create Schema : CREATE TABLE test ( res_id bigint ); 2. Insert 10K records to it 3.Delete them from 300 MB (original database size) RAM , RAM size grows to very high like 900M+ which is never released until Monetdb is restarted. This looks to be consistently reproducible in centos 5.8 and sless 11 64 bit Swap: 2104472k total, 0k used, 2104472k free, 301808k cached PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND 5098 ashish 20 0 1690m 915m 5044 S 0 45.7 1:04.46 mserver5 4597 ashish 20 0 1355m 207m 13m S 0 10.4 0:35.07 java If you reach the limit of memory program hangs the system. Some hints on how to accomplish cleaning of unused data will be really helpful ! ## Comment 17806 Date: 2012-10-13 17:33:05 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; setting 1.5 GB ulimit for memory and VM makes database to crash, any help will be ighly appreciated! 2012-10-13 11:29:18 MSG pbsworksdb[5592]: GDKmalloc(176128) fails, try to free up space [memory in use=1452667512,virtual memory in use=1452667512] 2012-10-13 11:29:18 MSG pbsworksdb[5592]: GDKmalloc(176128) result [mem=1444680136,vm=1444680136] 2012-10-13 11:29:18 MSG pbsworksdb[5592]: GDKmallocmax: recovery ok. Continuing.. 2012-10-13 11:29:18 MSG pbsworksdb[5592]: GDKmalloc(178176) fails, try to free up space [memory in use=1451281704,virtual memory in use=1451281704] 2012-10-13 11:29:18 MSG pbsworksdb[5592]: GDKmalloc(178176) result [mem=1451090816,vm=1451090816] 2012-10-13 11:29:18 MSG pbsworksdb[5592]: GDKmallocmax: recovery ok. Continuing.. 2012-10-13 11:29:18 MSG pbsworksdb[5592]: GDKmalloc(178176) fails, try to free up space [memory in use=1451253576,virtual memory in use=1451253576] 2012-10-13 11:29:18 MSG pbsworksdb[5592]: GDKmalloc(178176) result [mem=1451062688,vm=1451062688] 2012-10-13 11:29:18 MSG pbsworksdb[5592]: GDKmallocmax: recovery ok. Continuing.. 2012-10-13 11:29:18 MSG pbsworksdb[5592]: GDKmalloc(178176) fails, try to free up space [memory in use=1451240880,virtual memory in use=1451240880] 2012-10-13 11:29:18 MSG pbsworksdb[5592]: GDKmalloc(178176) result [mem=1451240880,vm=1451240880] 2012-10-13 11:29:18 MSG pbsworksdb[5592]: GDKmmap(196608) fails, try to free up space [memory in use=1451240880,virtual memory in use=1451240880] 2012-10-13 11:29:18 MSG pbsworksdb[5592]: GDKmmap(196608) result [mem=1451240880,vm=1451240880] 2012-10-13 11:29:44 MSG merovingian[5526]: proxying client 192.168.152.1:51510 for database 'pbsworksdb' to mapi:monetdb:///opt/pbsworks/12.0/portal/thirdparty/monetdb/pbsworksdata/pbsworksdb/.mapi.sock?database=pbsworksdb 2012-10-13 11:29:44 MSG merovingian[5526]: target connection is on local UNIX domain socket, passing on filedescriptor instead of proxying 2012-10-13 11:29:44 MSG merovingian[5526]: database 'pbsworksdb' (5592) was killed by signal SIGSEGV ## Comment 17892 Date: 2012-11-07 18:50:39 +0100 From: @grobian Deleting from a table in MonetDB doesn't really remove the data (just makes it inaccesible). The only way to really free up here is to drop the table and recreate it. We need VACUUM to clean up data that has been removed.
If we insert and delete a set of records monet db is not freeing up memory
https://api.github.com/repos/MonetDB/MonetDB/issues/3162/comments
0
2020-11-30T12:14:05Z
2024-06-28T13:40:06Z
https://github.com/MonetDB/MonetDB/issues/3162
753,427,751
3,162
[ "MonetDB", "MonetDB" ]
Date: 2012-10-13 14:38:28 +0200 From: Anthony Damico &lt;<ajdamico>&gt; To: clients devs &lt;<bugs-clients>&gt; Version: 11.13.3 (Oct2012) CC: ajdamico, @mlkersten, @drstmane Last updated: 2012-11-21 14:49:41 +0100 ## Comment 17797 Date: 2012-10-13 14:38:28 +0200 From: Anthony Damico &lt;<ajdamico>&gt; User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:16.0) Gecko/20100101 Firefox/16.0 Build Identifier: When the command SELECT * FROM TABLENAME LIMIT 5 ; gets run on a table with a large number of columns (or SELECT COL1, COL2..., COL100, COL101, .. COL150 FROM TABLENAME LIMIT 5) -- mclient responds: invalid tuple received from server, got columns, expected , ignoring Reproducible: Always ### Steps to Reproduce: 1. I am using the alaska household file from the 2010 american community survey. This file can be downloaded from: http://www2.census.gov/acs2010_1yr/pums/csv_hak.zip 2. Run these simple commands: drop table household; create table household ( RT VARCHAR(255), SERIALNO INT, DIVISION INT, PUMA INT, REGION INT, ST INT, ADJHSG INT, ADJINC INT, WGTP INT, NP INT, ZZZZ INT, ACR INT, AGS INT, BATH INT, BDSP INT, BLD INT, BUS INT, CONP INT, ELEP INT, FS INT, FULP INT, GASP INT, HFL INT, INSP INT, MHP INT, MRGI INT, MRGP INT, MRGT INT, MRGX INT, REFR INT, RMSP INT, RNTM INT, RNTP INT, RWAT INT, SINK INT, SMP INT, STOV INT, TEL INT, TEN INT, TOIL INT, VACS INT, VALP INT, VEH INT, WATP INT, YBL INT, FES INT, FINCP INT, FPARC INT, GRNTP INT, GRPIP INT, HHL INT, HHT INT, HINCP INT, HUGCL INT, HUPAC INT, HUPAOC INT, HUPARC INT, KIT INT, LNGI INT, MULTG INT, MV INT, NOC INT, NPF INT, NPP INT, NR INT, NRC INT, OCPIP INT, PARTNER INT, PLM INT, PSF INT, R18 INT, R60 INT, R65 INT, RESMODE INT, SMOCP INT, SMX INT, SRNT INT, SVAL INT, TAXP INT, WIF INT, WKEXREL INT, WORKSTAT INT, FACRP INT, FAGSP INT, FBATHP INT, FBDSP INT, FBLDP INT, FBUSP INT, FCONP INT, FELEP INT, FFSP INT, FFULP INT, FGASP INT, FHFLP INT, FINSP INT, FKITP INT, FMHP INT, FMRGIP INT, FMRGP INT, FMRGTP INT, FMRGXP INT, FMVP INT, FPLMP INT, FREFRP INT, FRMSP INT, FRNTMP INT, FRNTP INT, FRWATP INT, FSINKP INT, FSMP INT, FSMXHP INT, FSMXSP INT, FSTOVP INT, FTAXP INT, FTELP INT, FTENP INT, FTOILP INT, FVACSP INT, FVALP INT, FVEHP INT, FWATP INT, FYBLP INT, wgtp1 INT, wgtp2 INT, wgtp3 INT, wgtp4 INT, wgtp5 INT, wgtp6 INT, wgtp7 INT, wgtp8 INT, wgtp9 INT, wgtp10 INT, wgtp11 INT, wgtp12 INT, wgtp13 INT, wgtp14 INT, wgtp15 INT, wgtp16 INT, wgtp17 INT, wgtp18 INT, wgtp19 INT, wgtp20 INT, wgtp21 INT, wgtp22 INT, wgtp23 INT, wgtp24 INT, wgtp25 INT, wgtp26 INT, wgtp27 INT, wgtp28 INT, wgtp29 INT, wgtp30 INT, wgtp31 INT, wgtp32 INT, wgtp33 INT, wgtp34 INT, wgtp35 INT, wgtp36 INT, wgtp37 INT, wgtp38 INT, wgtp39 INT, wgtp40 INT, wgtp41 INT, wgtp42 INT, wgtp43 INT, wgtp44 INT, wgtp45 INT, wgtp46 INT, wgtp47 INT, wgtp48 INT, wgtp49 INT, wgtp50 INT, wgtp51 INT, wgtp52 INT, wgtp53 INT, wgtp54 INT, wgtp55 INT, wgtp56 INT, wgtp57 INT, wgtp58 INT, wgtp59 INT, wgtp60 INT, wgtp61 INT, wgtp62 INT, wgtp63 INT, wgtp64 INT, wgtp65 INT, wgtp66 INT, wgtp67 INT, wgtp68 INT, wgtp69 INT, wgtp70 INT, wgtp71 INT, wgtp72 INT, wgtp73 INT, wgtp74 INT, wgtp75 INT, wgtp76 INT, wgtp77 INT, wgtp78 INT, wgtp79 INT, wgtp80 INT ); copy 5000 offset 2 records into household from 'C:\My Directory\ss10hak.csv' using delimiters ',','\n','"' NULL as '' ; \w-1 select count(*) from household; select * from household limit 5 ; PLAN select * from household limit 5 ; EXPLAIN select * from household limit 5 ; ### Actual Results: > invalid tuple received from server, got 138 columns, expected 476, ignoring > +------+------+------+------+-------+------+---------+---------+------+------+ > 1 tuple (417.984ms) !466 columns dropped! > note: to disable dropping columns and/or truncating fields use \w-1 ### Expected Results: The first five records of this data table I am confident the problem is not limited to mclient. When using a JAVA connection instead of mclient (with http://sqlsurvey.r-forge.r-project.org/) I get the exact same error. ## Comment 17798 Date: 2012-10-13 15:21:35 +0200 From: @drstmane (1) In the genuine MonetDB code base, the reported error message is only generated in the SQLrenderer() of mclient.c . (2) Could you please shared with us, which exact version/release of MonetDB you are using? The output of `mserver5 --version` would be just fine ... (3) Could you please try other than the default SQL renderer in you setting, i.e., on you mclient console ("sql>" prompt) type \f select * from household limit 1 ; \fraw select * from household limit 1 ; \fcsv select * from household limit 1 ; \ftab select * from household limit 1 ; \ftest select * from household limit 1 ; \fsql select * from household limit 1 ; (assuming that the reported error also occurs with "limit 1"), and share the entire output with us? Thanks! ## Comment 17799 Date: 2012-10-13 15:29:13 +0200 From: Anthony Damico &lt;<ajdamico>&gt; Thanks Stephan! Here you go: (1) I don't understand this.. is there something I can or should do? Sorry, I'm new to MonetDB.. (2) C:\Program Files\MonetDB\MonetDB5>M5server --version MonetDB 5 server v11.11.11 "Jul2012-SP2" (64-bit, 64-bit oids) Copyright (c) 1993-July 2008 CWI Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved Visit http://www.monetdb.org/ for further information Found 15.9GiB available memory, 2 available cpu cores Libraries: libpcre: 8.13 2011-08-16 openssl: OpenSSL 1.0.1b 26 Apr 2012 libxml2: 2.7.8 Compiled by: monet@LAB03 (x86_64-pc-winnt) Compilation: cl -GF -W3 -wd4273 -wd4102 -MD -nologo -Ox Linking : cl -GF -W3 -wd4273 -wd4102 -MD -nologo -Ox C:\Program Files\MonetDB\MonetDB5> (3) sql>\f Current formatter: sql sql>select * from household limit 1 ; +------+------+------+------+-------+------+---------+---------+------+------+ | rt | seri | divi | puma | regio | st | adjhsg | adjinc | wgtp | np |> : : alno : sion : : n : : : : : :> +======+======+======+======+=======+======+=========+=========+======+======+ invalid tuple received from server, got 138 columns, expected 202, ignoring +------+------+------+------+-------+------+---------+---------+------+------+ 1 tuple (2.0s) !192 columns dropped! note: to disable dropping columns and/or truncating fields use \w-1 sql> sql>\fraw sql>select * from household limit 1 ; % sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household table_name % rt, serialno, division, puma, region, st, adjhsg, adjinc, wgtp, np, zzzz, acr, ags, bath, bdsp, bld, bus, conp, elep, fs, fulp, gasp, hfl, insp, mhp, mrgi, mrgp, mrgt, mrgx, refr, rmsp, rntm, rntp, rwat, sink, smp, stov, tel, ten, toil, vacs, valp, veh, watp, ybl, fes, fincp, fparc, grntp, grpip, hhl, hht, hincp, hugcl, hupac, hupaoc, huparc, kit, lngi, multg, mv, noc, npf, npp, nr, nrc, ocpip, partner, plm, psf, r18, r60, r65, resmode, smocp, smx, srnt, sval, taxp, wif, wkexrel, workstat, facrp, fagsp, fbathp, fbdsp, fbldp, fbusp, fconp, felep, ffsp, ffulp, fgasp, fhflp, finsp, fkitp, fmhp, fmrgip, fmrgp, fmrgtp, fmrgxp, fmvp, fplmp, frefrp, frmsp, frntmp, frntp, frwatp, fsinkp, fsmp, fsmxhp, fsmxsp, fstovp, ftaxp, ftelp, ftenp, ftoilp, fvacsp, fvalp, fvehp, fwatp, fyblp, wgtp1, wgtp2, wgtp3, wgtp4, wgtp5, wgtp6, wgtp7, wgtp8, wgtp9, wgtp10, wgtp11, wgtp12, wgtp13, wgtp14, wgtp15, wgtp16, wgtp17, wgtp18, wgtp19, wgtp20, wgtp21, wgtp22, wgtp23, wgtp24, wgtp25, wgtp26, wgtp27, wgtp28, wgtp29, wgtp30, wgtp31, wgtp32, wgtp33, wgtp34, wgtp35, wgtp36, wgtp37, wgtp38, wgtp39, wgtp40, wgtp41, wgtp42, wgtp43, wgtp44, wgtp45, wgtp46, wgtp47, wgtp48, wgtp49, wgtp50, wgtp51, wgtp52, wgtp53, wgtp54, wgtp55, wgtp56, wgtp57, wgtp58, wgtp59, wgtp60, wgtp61, wgtp62, wgtp63, wgtp64, wgtp65, wgtp66, wgtp67, wgtp68, wgtp69, wgtp70, wgtp71, wgtp72, wgtp73, wgtp74, wgtp75, wgtp76, wgtp77, wgtp78, wgtp79, wgtp80 name % varchar, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int type % 1, 3, 1, 3, 1, 1, 7, 7, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 3, 1, 4, 1, 1, 3, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 6, 1, 4, 1, 1, 5, 1, 1, 1, 1, 1, 5, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 4, 1, 1, 1, 2, 1, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 2, 3, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 2, 2, 2, 2 length [ "H", 168, 9, 300, 4, 2, 1000000, 1007624, 56, 3, 1, 1, NULL, 1, 3, 2, 2, NULL, 200, 2, 3500, 3, 4, 760, NULL, 1, 1800, 1, 1, 1, 7, NULL, NULL, 1, 1, NULL, 1, 1, 1, 1, NULL, 235000, 2, 1600, 5, 7, 89500, 4, NULL, NULL, 1, 3, 89500, 0, 4, 4, 4, 1, 1, 1, 6, 0, 3, 0, 0, 0, 33, 0, 1, 0, 0, 0, 0, 1, 2425, 3, 0, 1, 43, 3, 14, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 74, 14, 62, 94, 47, 55, 45, 72, 60, 120, 18, 58, 31, 61, 54, 52, sql> sql>\fcsv sql>select * from household limit 1 ; H,168,9,300,4,2,1000000,1007624,56,3,1,1,,1,3,2,2,,200,2,3500,3,4,760,,1,1800,1, 1,1,7,,,1,1,,1,1,1,1,,235000,2,1600,5,7,89500,4,,,1,3,89500,0,4,4,4,1,1,1,6,0,3, 0,0,0,33,0,1,0,0,0,0,1,2425,3,0,1,43,3,14,13,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 ,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,74,14,62,94,47,55,45,72,60,120,18,5 8,31,61,54,52 sql> sql>\ftab sql>select * from household limit 1 ; H 168 9 300 4 2 1000000 1007624 56 3 1 1 1 3 2 2 200 2 3500 3 4 760 1 1800 1 1 1 7 1 1 1 1 1 1 235000 2 1600 5 7 89500 4 1 3 89500 0 4 4 4 1 1 1 6 0 3 0 0 0 33 0 1 0 0 0 0 1 2425 3 0 1 43 3 14 13 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 74 14 62 94 47 55 45 72 60 120 18 58 31 61 54 52 sql> sql>\ftest sql>select * from household limit 1 ; % sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household, sys.household, sys.household, sys.hous ehold, sys.household, sys.household table_name % rt, serialno, division, puma, region, st, adjhsg, adjinc, wgtp, np, zzzz, acr, ags, bath, bdsp, bld, bus, conp, elep, fs, fulp, gasp, hfl, insp, mhp, mrgi, mrgp, mrgt, mrgx, refr, rmsp, rntm, rntp, rwat, sink, smp, stov, tel, ten, toil, vacs, valp, veh, watp, ybl, fes, fincp, fparc, grntp, grpip, hhl, hht, hincp, hugcl, hupac, hupaoc, huparc, kit, lngi, multg, mv, noc, npf, npp, nr, nrc, ocpip, partner, plm, psf, r18, r60, r65, resmode, smocp, smx, srnt, sval, taxp, wif, wkexrel, workstat, facrp, fagsp, fbathp, fbdsp, fbldp, fbusp, fconp, felep, ffsp, ffulp, fgasp, fhflp, finsp, fkitp, fmhp, fmrgip, fmrgp, fmrgtp, fmrgxp, fmvp, fplmp, frefrp, frmsp, frntmp, frntp, frwatp, fsinkp, fsmp, fsmxhp, fsmxsp, fstovp, ftaxp, ftelp, ftenp, ftoilp, fvacsp, fvalp, fvehp, fwatp, fyblp, wgtp1, wgtp2, wgtp3, wgtp4, wgtp5, wgtp6, wgtp7, wgtp8, wgtp9, wgtp10, wgtp11, wgtp12, wgtp13, wgtp14, wgtp15, wgtp16, wgtp17, wgtp18, wgtp19, wgtp20, wgtp21, wgtp22, wgtp23, wgtp24, wgtp25, wgtp26, wgtp27, wgtp28, wgtp29, wgtp30, wgtp31, wgtp32, wgtp33, wgtp34, wgtp35, wgtp36, wgtp37, wgtp38, wgtp39, wgtp40, wgtp41, wgtp42, wgtp43, wgtp44, wgtp45, wgtp46, wgtp47, wgtp48, wgtp49, wgtp50, wgtp51, wgtp52, wgtp53, wgtp54, wgtp55, wgtp56, wgtp57, wgtp58, wgtp59, wgtp60, wgtp61, wgtp62, wgtp63, wgtp64, wgtp65, wgtp66, wgtp67, wgtp68, wgtp69, wgtp70, wgtp71, wgtp72, wgtp73, wgtp74, wgtp75, wgtp76, wgtp77, wgtp78, wgtp79, wgtp80 name % varchar, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int, int type % 1, 3, 1, 3, 1, 1, 7, 7, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 3, 1, 4, 1, 1, 3, 1, 1, 4, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 6, 1, 4, 1, 1, 5, 1, 1, 1, 1, 1, 5, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 1, 1, 4, 1, 1, 1, 2, 1, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 2, 3, 3, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 3, 2, 2, 2, 2 length [ "H", 168, 9, 300, 4, 2, 1000000, 1007624, 56, 3, 1, 1, NULL, 1, 3, 2, 2, NULL, 200, 2, 3500, 3, 4, 760, NULL, 1, 1800, 1, 1, 1, 7, NULL, NULL, 1, 1, NULL, 1, 1, 1, 1, NULL, 235000, 2, 1600, 5, 7, 89500, 4, NULL, NULL, 1, 3, 89500, 0, 4, 4, 4, 1, 1, 1, 6, 0, 3, 0, 0, 0, 33, 0, 1, 0, 0, 0, 0, 1, 2425, 3, 0, 1, 43, 3, 14, 13, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 74, 14, 62, 94, 47, 55, 45, 72, 60, 120, 18, 58, 31, 61, 54, 52 ] sql> sql>\fsql sql>select * from household limit 1 ; +------+------+------+------+-------+------+---------+---------+------+------+ | rt | seri | divi | puma | regio | st | adjhsg | adjinc | wgtp | np |> : : alno : sion : : n : : : : : :> +======+======+======+======+=======+======+=========+=========+======+======+ invalid tuple received from server, got 138 columns, expected 202, ignoring +------+------+------+------+-------+------+---------+---------+------+------+ 1 tuple (106.778ms) !192 columns dropped! sql> ## Comment 17809 Date: 2012-10-13 19:08:06 +0200 From: @mlkersten To rule out one area of possible problems, could you check if the result of the following instruction contains the 202 fields/row. copy select * from household limit 1 into 'filename'; ## Comment 17810 Date: 2012-10-13 23:32:54 +0200 From: Anthony Damico &lt;<ajdamico>&gt; Yes, this appears to work properly. I get "1 affected row" and then the output file contains 202 separate values. ## Comment 17858 Date: 2012-10-30 15:24:29 +0100 From: @sjoerdmullender Changeset [f694b42ec70e](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=f694b42ec70e) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=f694b42ec70e](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=f694b42ec70e) Changeset description: Fix an off-by-one error. This should fix bug #3161. The problem was that the code checked whether the data would fit the allocated space, and if it didn't, it would allocate more. So far so good. But if the data fits exactly, the code would then copy one too few characters. We now extend the buffer if the data fits exactly. Note that fitting exactly is here defined as fits without the usual NUL byte at the end of the string, so we needed to extend for that anyway. This only showed up on Windows because BUFSIZ is significantly smaller on Windows than on Linux. ## Comment 17859 Date: 2012-10-30 16:12:22 +0100 From: @sjoerdmullender Changeset [b124e68caa5a](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=b124e68caa5a) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=b124e68caa5a](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=b124e68caa5a) Changeset description: Added test for bug #3161. ## Comment 17975 Date: 2012-11-21 14:49:41 +0100 From: @sjoerdmullender Oct2012-SP1 has been released.
invalid tuple received from server, got 138 columns, expected 476, ignoring
https://api.github.com/repos/MonetDB/MonetDB/issues/3161/comments
0
2020-11-30T12:14:01Z
2024-06-27T11:57:46Z
https://github.com/MonetDB/MonetDB/issues/3161
753,427,710
3,161
[ "MonetDB", "MonetDB" ]
Date: 2012-10-12 07:11:56 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.3 (Oct2012) CC: @njnes Depends on: #2541 Last updated: 2012-11-26 15:12:22 +0100 ## Comment 17796 Date: 2012-10-12 07:11:56 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.94 Safari/537.4 Build Identifier: No clear documentation and guideline on Vacuuming database. Reproducible: Always ## Comment 17893 Date: 2012-11-07 18:51:30 +0100 From: @grobian This functionality doesn't exist currently, hence it isn't documented.
No clear documentation and guideline on Vacuuming database
https://api.github.com/repos/MonetDB/MonetDB/issues/3160/comments
0
2020-11-30T12:13:58Z
2024-06-28T13:17:29Z
https://github.com/MonetDB/MonetDB/issues/3160
753,427,667
3,160
[ "MonetDB", "MonetDB" ]
Date: 2012-10-11 20:32:23 +0200 From: @mlkersten To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.3 (Oct2012) Last updated: 2012-10-11 20:50:31 +0200 ## Comment 17794 Date: 2012-10-11 20:32:23 +0200 From: @mlkersten User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:15.0) Gecko/20100101 Firefox/15.0.1 Build Identifier: It appears that a column of type BLOB is not handled correctly. The test below shows that nothing has been inserted or displayed properly. Reproducible: Always ### Steps to Reproduce: CREATE TEMPORARY TABLE Poly ( ra1 DOUBLE PRECISION NOT NULL, dec1 DOUBLE PRECISION NOT NULL, ra2 DOUBLE PRECISION NOT NULL, dec2 DOUBLE PRECISION NOT NULL, ra3 DOUBLE PRECISION NOT NULL, dec3 DOUBLE PRECISION NOT NULL, poly blob DEFAULT NULL ); INSERT INTO Poly VALUES (-10, 0, 10, 0, 0, 10, NULL); SELECT * from poly; ### Actual Results: select * from poly; +-----+------+-----+------+-----+------+------+ | ra1 | dec1 | ra2 | dec2 | ra3 | dec3 | poly | +=====+======+=====+======+=====+======+======+ +-----+------+-----+------+-----+------+------+ 0 tuples (1.669ms) ### Expected Results: select * from poly; +-----+------+-----+------+-----+------+------+ | ra1 | dec1 | ra2 | dec2 | ra3 | dec3 | poly | +=====+======+=====+======+=====+======+======+ | -10 | 0 | 10 | 0 | 0 | 10 | null | +-----+------+-----+------+-----+------+------+ 0 tuples (1.669ms) ## Comment 17795 Date: 2012-10-11 20:50:31 +0200 From: @mlkersten This is temporary table behaviour. Has nothing to do with blob's. Try using a commit action, ON COMMIT PRESERVE ROWS
Handling blob values failed.
https://api.github.com/repos/MonetDB/MonetDB/issues/3159/comments
0
2020-11-30T12:13:56Z
2024-06-28T13:17:28Z
https://github.com/MonetDB/MonetDB/issues/3159
753,427,636
3,159
[ "MonetDB", "MonetDB" ]
Date: 2012-10-10 19:59:01 +0200 From: Andy Grove &lt;<andy.grove>&gt; To: clients devs &lt;<bugs-clients>&gt; Version: 11.13.3 (Oct2012) Last updated: 2012-11-07 19:05:33 +0100 ## Comment 17788 Date: 2012-10-10 19:59:01 +0200 From: Andy Grove &lt;<andy.grove>&gt; User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_8_1) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.79 Safari/537.4 Build Identifier: I am running this query using a prepared statement select a, b, count(*) from foo where c>? group by a, b a and b are varchars and c is an integer type. The code: PreparedStatement pstmt = conn.prepareStatement(sql); pstmt.setObject(1, 12345); This fails with "java.sql.SQLException: EXEC: wrong type for argument 1 of prepared statement: char, expected int" However, if I change the code to the following then it works correctly: PreparedStatement pstmt = conn.prepareStatement(sql); pstmt.setInt(1, 12345); I took a quick look at the source code and it seems that the prepared statement is using the data type for the first column in the select list rather than for the first bound parameter. Reproducible: Always ### Steps to Reproduce: 1. CREATE TABLE foo (a varchar(5), b varchar(5), c integer) 2. INSERT INTO foo VALUES ('a', 'a', 1); 3. Run java code as described in details ### Actual Results: java.sql.SQLException: EXEC: wrong type for argument 1 of prepared statement: char, expected int ### Expected Results: Query should execute without error ## Comment 17789 Date: 2012-10-10 20:29:54 +0200 From: @grobian Changeset [d8f8cb98ca1c](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=d8f8cb98ca1c) made by Fabian Groffen <fabian@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=d8f8cb98ca1c](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=d8f8cb98ca1c) Changeset description: PreparedStatement: fix column offset handling Since [56ca5fe0526b](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=56ca5fe0526b) we can no longer map a column index directly to our result array. Hence, we have to use getColumnIdx() method for each and every place where we use the column index to lookup something from our backing arrays. Thanks Andy Grove in bug #3158. ## Comment 17790 Date: 2012-10-10 20:36:16 +0200 From: @grobian Thanks. I've committed a fix. I think this warrants rebuilding the Oct2012 release. Maybe in the next few days more bugs show up + get fixed. ## Comment 17896 Date: 2012-11-07 19:05:33 +0100 From: @grobian This bug was/is fixed in the Oct2012 release
setObject() using wrong data type
https://api.github.com/repos/MonetDB/MonetDB/issues/3158/comments
0
2020-11-30T12:13:53Z
2024-06-27T11:57:43Z
https://github.com/MonetDB/MonetDB/issues/3158
753,427,609
3,158
[ "MonetDB", "MonetDB" ]
Date: 2012-10-09 16:16:14 +0200 From: mrunal.gawade To: GDK devs &lt;<bugs-common>&gt; Version: -- development CC: @mlkersten, @drstmane Last updated: 2012-11-07 19:06:30 +0100 ## Comment 17773 Date: 2012-10-09 16:16:14 +0200 From: mrunal.gawade User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.56 Safari/537.4 Build Identifier: I have written an alternate version for multithreaded uselect (which also does a matpack internally) which throws error due to following condition in code path. The data set is a single column of longint with total size of 10GB and the query is "select a from table where a>=1 and a<=1250000000;". The filename below is null, minsize=284944516 and h->size=10799999912 and that is the reason the check below does not hold and error is thrown. if (h->filename == NULL || (h->size < minsize)) { > 0 GDKerror (format=0x7ffff76a25d0 "HEAPalloc: Insufficient space for HEAP of %zu bytes.") at gdk_utils.c:1610 > 1 0x00007ffff720b55a in HEAPalloc (h=0x7fffedfe7ff0, nitems=10799999912, itemsize=1) at gdk_heap.c:334 > 2 0x00007ffff720c29b in HEAPcopy (dst=0x7fffedfe7ff0, src=0x7fffe00a8228) at gdk_heap.c:574 > 3 0x00007ffff72b1281 in heapcopy (bn=0x7fffe00a0020, ext=0x7ffff76ac399 "head", dst=0x7fffedfe7ff0, src=0x7fffe00a8228) at gdk_bat.c:719 > 4 0x00007ffff72b22b1 in BATcopy (b=0x7fffe00a8190, ht=6, tt=6, writable=0) at gdk_bat.c:862 > 5 0x00007ffff752ae6d in diff_intersect (l=0x7fffe00a8190, r=0x1a4b0d0, diff=1, set=0) at gdk_setop.mx:770 > 6 0x00007ffff752b63e in BATkdiff (l=0x7fffe00a8190, r=0x1a4b0d0) at gdk_setop.mx:843 > 7 0x00007ffff7b41a4e in ALGbinary (result=0x7fffe00a0b40, lid=0x7fffe00a0b10, rid=0x7fffe00a0b20, func=0x7ffff752b5ff <BATkdiff>, name=0x7ffff7ce924f "algebra.kdiff") at algebra.mx:2586 > 8 0x00007ffff7b42749 in ALGkdiff (result=0x7fffe00a0b40, lid=0x7fffe00a0b10, rid=0x7fffe00a0b20) at algebra.mx:2789 > 9 0x00007ffff7a3a5e5 in malCommandCall (stk=0x7fffe00a09b0, pci=0x7fffe00929c0) at mal_interpreter.c:144 > 10 0x00007ffff7a3d07b in runMALsequence (cntxt=0x7ffff029f338, mb=0x7fffe0091d60, startpc=1, stoppc=0, stk=0x7fffe00a09b0, env=0x0, pcicaller=0x0) at mal_interpreter.c:711 > 11 0x00007ffff7a3c64c in callMAL (cntxt=0x7ffff029f338, mb=0x7fffe0091d60, env=0x7fffedfe8af0, argv=0x7fffedfe8b90, debug=0 '\000') at mal_interpreter.c:545 > 12 0x00007fffef0ad5bc in SQLexecutePrepared (c=0x7ffff029f338, be=0x7fffe0084cb0, q=0x7fffe0086350) at sql_scenario.c:1728 > 13 0x00007fffef0ad8a5 in SQLengineIntern (c=0x7ffff029f338, be=0x7fffe0084cb0) at sql_scenario.c:1781 > 14 0x00007fffef0ade42 in SQLengine (c=0x7ffff029f338) at sql_scenario.c:1907 > 15 0x00007ffff7a6e0f1 in runPhase (c=0x7ffff029f338, phase=4) at mal_scenario.c:522 > 16 0x00007ffff7a6e2f1 in runScenarioBody (c=0x7ffff029f338) at mal_scenario.c:573 > 17 0x00007ffff7a6e4f4 in runScenario (c=0x7ffff029f338) at mal_scenario.c:601 > 18 0x00007ffff7a6f59c in MSserveClient (dummy=0x7ffff029f338) at mal_session.c:430 > 19 0x00007ffff72d2b1a in wrapper_routine (data=0x7fffee3ea900) at gdk_system.c:559 > 20 0x00000031fc407d90 in start_thread () from /lib64/libpthread.so.0 > 21 0x00000031fb8f119d in clone () from /lib64/libc.so.6 > Reproducible: Always ## Comment 17774 Date: 2012-10-09 16:49:26 +0200 From: @grobian Could it be, that an operation is done on the result of your alternative uselect? In that case, does the problem persist if you switch back to normal uselect for the same plan? (Can it be that you create a BAT wrongly?) ## Comment 17775 Date: 2012-10-09 17:17:38 +0200 From: @drstmane Mrunal, could you possibly share the output of `hg summary` and attache the output of `hg diff` --- both commands executed in the top-level directory of your MonetDB source code checkout? Thanks, Stefan ## Comment 17780 Date: 2012-10-09 18:29:59 +0200 From: mrunal.gawade Created attachment 148 algebra.c algebra.c > Attached file: [algebra.c](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3157_algebra.c_148) (text/x-csrc, 141427 bytes) > Description: algebra.c ## Comment 17781 Date: 2012-10-09 18:31:30 +0200 From: mrunal.gawade bash-4.2$ hg summary parent: 45570:a755aa657727 tip Removing unused argument. branch: default commit: 7 modified, 953 unknown update: (current) "hg diff" does not show the code for algebra.c that I modified. However, the file is located on "cologne" at following path. (It is not very well indented though as I was playing around with code for my own understanding). /export/scratch2/gawade/Softwares/MonetDB-Default/MonetDB/monetdb5/modules/kernel/algebra.c The error does not come from correct (original) uselect plan. I do not modify the existing code of uselect much except for splitting it in different partitions, with threads and adjusting pointers accordingly. So I do not touch existing api's wrongly ( I suppose) or introduce new gdk API's. Below is mal plan. It has 3 uselects. The first uselect in this case enters my function and I work on it. The next 2 uselects also enter my function due to same signature, but inside my function I check for batcount==0 and pass the call to original uselect. The error above is reported from one of the kdifference that appear after first uselect returns. I have attached the file algebra.c here. (ALGuselectInclusive is the entry function for my code) +----------------------------------------------------------------------+ | mal | +======================================================================+ | function user.s0_1{autoCommit=true}(A0:lng,A1:lng):void; | | X_4 := sql.mvc(); | | X_5:bat[:oid,:lng] := sql.bind(X_4,"sys","testsplit8","a",0); | | X_10 := A0; | | X_11 := A1; | | X_12 := algebra.uselect(X_5,X_10,X_11,true,true); | | X_13:bat[:oid,:lng] := sql.bind(X_4,"sys","testsplit8","a",2); | | X_15 := algebra.kdifference(X_12,X_13); | | X_16 := algebra.uselect(X_13,X_10,X_11,true,true); | | X_17 := algebra.kunion(X_15,X_16); | | X_18:bat[:oid,:lng] := sql.bind(X_4,"sys","testsplit8","a",1); | | X_20 := algebra.uselect(X_18,X_10,X_11,true,true); | | X_21 := algebra.kunion(X_17,X_20); | | X_22:bat[:oid,:oid] := sql.bind_dbat(X_4,"sys","testsplit8",1); | | X_23 := bat.reverse(X_22); | | X_24 := algebra.kdifference(X_21,X_23); | | X_27 := calc.oid(0@0); | | X_29 := algebra.markT(X_24,X_27); | | X_30 := bat.reverse(X_29); | | X_31 := algebra.kdifference(X_5,X_13); | | X_32 := algebra.kunion(X_31,X_13); | | X_33 := algebra.kunion(X_32,X_18); | | X_34 := algebra.leftjoin(X_30,X_33); | | X_37 := sql.resultSet(1,1,X_34); | | sql.rsColumn(X_37,"sys.testsplit8","a","bigint",64,0,X_34); | | X_43 := io.stdout(); | | sql.exportResult(X_43,X_37); | | end s0_1; | +----------------------------------------------------------------------+ ## Comment 17782 Date: 2012-10-09 18:50:36 +0200 From: @grobian you're on the development line (default) :( ## Comment 17783 Date: 2012-10-09 19:07:40 +0200 From: @drstmane Mrunal, it's usually a good and strongly advised habit to only modify genuine source files, and never modify any derived/generated source files --- not only can you then easily get a "diff" between the original code and your modifications, but also you then do not run the risk that a build `make` re-extracts/-generates (in this case) the .c file from the original .mx file, overwriting your .c file ...). ## Comment 17784 Date: 2012-10-10 00:02:53 +0200 From: @drstmane (In reply to comment 0) > The filename below is null, minsize=284944516 and h->size=10799999912 and that > is the reason the check below does not hold and error is thrown. > > if (h->filename == NULL || (h->size < minsize)) { If filename is NULL, the above condition does evaluate to true, not to false. > > > 0 GDKerror (format=0x7ffff76a25d0 "HEAPalloc: Insufficient space for HEAP of %zu bytes.") at gdk_utils.c:1610 > > 1 0x00007ffff720b55a in HEAPalloc (h=0x7fffedfe7ff0, nitems=10799999912, itemsize=1) at gdk_heap.c:334 > > 2 0x00007ffff720c29b in HEAPcopy (dst=0x7fffedfe7ff0, src=0x7fffe00a8228) at gdk_heap.c:574 These lines do not match with the code of gdk/gdk_heap.c of changeset [a755aa657727](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=a755aa657727) Could you please share *all* your code changes (`hg diff` of your source tree plus all (discouraged) changes of generated code files in your build tree), such that we can eliminate that these might be related to the reported problem? Thanks! ## Comment 17785 Date: 2012-10-10 00:30:18 +0200 From: @drstmane Did / could you check, which exact path is chosen in HEAPalloc(), i.e., which is the final assignment to h->base in HEAPalloc() before if (h->base == NULL) evaluates to true and GDKerror() is called? Thanks! ## Comment 17791 Date: 2012-10-11 01:51:54 +0200 From: mrunal.gawade Sorry for late response. I cleaned the code and added corner case checks. Did not see this message earlier. I think I nailed the main problem. I am looking into it. BATsubselect which is called from CMDuselect_(&bn, b, low, high, lin, rin); is not returning correct type for the returned bat "bn". Input bat b has "11" (lng) as type whereas return bat bn is getting "0". This leads to failure of heapname allocation strategy in BATcreatedesc(ht, tt, (ht || tt)); due to which a null file name is returned even though size of bat is huge. I am passing input arguments low, high, lin, rin as received from the main input function to CMDuselect so it should not fail. Let me see it further tomorrow. Thanks a lot for your time on this. Regards, Mrunal ## Comment 17792 Date: 2012-10-11 07:27:22 +0200 From: @mlkersten BATuselect returns a [:void,:oid] column and it can return an empty BAT, which is of type [:void,:void]. The empty BAT will have BATcount = 0. All correct. Do you change the count yourself? Or how do you call BATcreatedesc? Do you pass it correctly a set of heapnames? ## Comment 17812 Date: 2012-10-15 08:26:47 +0200 From: @drstmane Mrunal, could you explain what exactly goes wrong in the heapname allocation strategy in BATcreatedesc(ht, tt, (ht || tt))? Please keep in mind that a :void (type == 0) column is not materialized, and thus needs neither heap nor filename ... Also, your GDK trace shows a HEAPalloc() failing while copying an [:oid,:oid] BAT (ht=6, tt=6); how is that related to type == 0 (:void) or type == 11 (:lng) ? Finally, your answer to my question in Comment 8 would still be very helpful for us... Thanks! Stefan ## Comment 17815 Date: 2012-10-15 18:26:21 +0200 From: mrunal.gawade hi Stefan, Here is a mail I wrote about the bug. In crux, mat pack is not checking types correctly at present. After a lot of walk in the code and tracing paths and trying to understand type conversion across BAT apis, I did this small hack to introduce explicit type tailtype "tt=oid" to returned bat from uselect. At present it is returned as bat[:void,:void]. This bat is created on a view of original bat which has type bat[:void,:lng]. This returned bat from uselect which I am further using in matpack is not empty though. Since the main problem is when BATnew calls BATcreatedesc(ht, tt, (ht || tt)) with both ht and tt =0 it results in filename parameter as zero, which leads to non allocation of filename in batcreatedesc. The hack of tt=TYPE_oid was done to adhere to semantics of uselect returning [void,oid] in non-view, non-emtpy bats). In this particular query the selectivity is 100% so continuous range of oids in newly created bat from matpack should map to the original bat on which view was created. However, this will fail in other non 100% selectivity cases. printf("\n size of matpack is %lu", cap); tt=TYPE_oid; bn = BATnew(ht, tt, cap); I think this case of "both ht,tt =0 and size != 0, when a view bat is created, should be checked explicitly by mat pack and corresponding care of type setting should be done correctly to that memory mapped file is allocated instead of malloced and correct oids are generated to access original bat on which view was created. Regards, Mrunal ## Comment 17816 Date: 2012-10-15 19:00:53 +0200 From: @drstmane Mrunal, in the original code of MATpack as well as your copy of it, replace BATins(bn,b1,FALSE); by bn = BATins(bn,b1,FALSE); and everything should work fine without any further "HACKS". There is a reason, why BATins() is not a void funtion, but rather returns the (modified) target BAT as result, among others because it might need to materialize TYPE_void into TYPE_oid columns. In fact, we'd need to check all MonetDB code for correct use of BATins(), i.e., b = BATins(b,...,...); instead of BATins(b,...,...); ## Comment 17817 Date: 2012-10-15 19:15:43 +0200 From: @drstmane Hm, looking at the BATins() code once again, maybe my suggestion is not sufficient, and we'd need to also consider assigning a suitable heap-filename in BATmaterializeh() (gdk/gdk_align.c) instead of using no filename: b->H->heap.filename = NULL; ... What I still do not understand, though, is how your uselect & bat.pack related explanations relate to the failing malloc in algebra.kdiff() ... ? ## Comment 17818 Date: 2012-10-15 19:30:26 +0200 From: @mlkersten At the MAL level we only deal with oid types. This means that most likely the following patch to mat.c will work --- a/monetdb5/modules/mal/mat.c Wed Oct 10 23:44:36 2012 +0200 +++ b/monetdb5/modules/mal/mat.c Mon Oct 15 19:28:55 2012 +0200 @@ -82,9 +82,12 @@ * that are subsequently reduced. * Contrary to most operations, NIL arguments are skipped and * do not produce RUNTIME_OBJECT_MISSING. + * + * We have to be carefull with :void and :oid tailed BATs. + * A sub-expression may produce a mixture of both. */ static str -MATpackInternal(MalStkPtr stk, InstrPtr p) +MATpackInternal(MalBlkPtr mb, MalStkPtr stk, InstrPtr p) { int i, *ret = (int*) getArgReference(stk,p,0); BAT *b, *bn; @@ -98,8 +101,8 @@ b = BATmirror(b); if( b ){ if (ht == TYPE_any){ - ht = b->htype; - tt = b->ttype; + ht = getHeadType(getVarType(mb,getArg(p,i))); + tt = getTailType(getVarType(mb,getArg(p,i))); } cap += BATcount(b); } @@ -112,11 +115,6 @@ bn = BATnew(ht, tt, cap); if (bn == NULL) throw(MAL, "mat.pack", MAL_MALLOC_FAIL); - /* must set seqbase or else BATins will not materialize column */ - if (ht == TYPE_void) - BATseqbase(bn, 0); - if (tt == TYPE_void) - BATseqbase(BATmirror(bn), 0); for (i = 1; i < p->argc; i++) { b = BATdescriptor(stk->stk[getArg(p,i)].val.ival); @@ -378,8 +376,7 @@ MATpack(Client cntxt, MalBlkPtr mb, MalStkPtr stk, InstrPtr p) { (void) cntxt; - (void) mb; - return MATpackInternal(stk,p); + return MATpackInternal(mb,stk,p); } ## Comment 17819 Date: 2012-10-15 20:01:07 +0200 From: @drstmane A simple(r) alternative of this patch would be diff -r [a514016682c9](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=a514016682c9) monetdb5/modules/mal/mat.c --- a/monetdb5/modules/mal/mat.c Wed Oct 10 20:33:22 2012 +0200 +++ b/monetdb5/modules/mal/mat.c Mon Oct 15 19:59:56 2012 +0200 @@ -98,8 +98,8 @@ b = BATmirror(b); if( b ){ if (ht == TYPE_any){ - ht = b->htype; - tt = b->ttype; + ht = ATOMtype(b->htype); + tt = ATOMtype(b->ttype); } cap += BATcount(b); } @@ -112,11 +112,6 @@ bn = BATnew(ht, tt, cap); if (bn == NULL) throw(MAL, "mat.pack", MAL_MALLOC_FAIL); - /* must set seqbase or else BATins will not materialize column */ - if (ht == TYPE_void) - BATseqbase(bn, 0); - if (tt == TYPE_void) - BATseqbase(BATmirror(bn), 0); for (i = 1; i < p->argc; i++) { Be aware, though, that both variants of the patch will "unnecessarily" materialize columns that are dense and remain so after mat.pack(). BATins() is designed to materialize only if strictly required, i.e., denseness is not maintained. ## Comment 17897 Date: 2012-11-07 19:06:30 +0100 From: @grobian custom code with questionable correctness
HeapAlloc fails due to no filename for memory mapped file
https://api.github.com/repos/MonetDB/MonetDB/issues/3157/comments
0
2020-11-30T12:13:50Z
2024-06-28T13:17:28Z
https://github.com/MonetDB/MonetDB/issues/3157
753,427,570
3,157
[ "MonetDB", "MonetDB" ]
Date: 2012-10-09 14:00:53 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; To: Merovingian devs &lt;<bugs-merovingian>&gt; Version: -- development CC: alexo15 Duplicates: #2407 Last updated: 2019-03-02 20:21:52 +0100 ## Comment 17768 Date: 2012-10-09 14:00:53 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.79 Safari/537.4 Build Identifier: As of now monetdb binds with all of available IPs in the system, there must be a provision to restrict it to localhost, a specific IP address. This will be very critical requirement for some of customers. hostname property should be made writable for this. Reproducible: Always ### Actual Results: update hostname using monetdbd command and should be able to specify an IP / hostname. ### Expected Results: Monetdbd should bind to given hostname/ip address only isntead of 0.0.0.0 ## Comment 17770 Date: 2012-10-09 14:03:35 +0200 From: @grobian *** This bug has been marked as a duplicate of bug #2407 *** ## Comment 26915 Date: 2019-03-02 20:21:52 +0100 From: Alex Ossipov &lt;<alexo15>&gt; This fix should be reopened to add ipv6 support.
Provision to make monetdb run in a specified IP address only
https://api.github.com/repos/MonetDB/MonetDB/issues/3156/comments
0
2020-11-30T12:13:46Z
2024-06-28T13:17:27Z
https://github.com/MonetDB/MonetDB/issues/3156
753,427,529
3,156
[ "MonetDB", "MonetDB" ]
Date: 2012-10-09 12:31:21 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; To: Merovingian devs &lt;<bugs-merovingian>&gt; Version: 11.13.3 (Oct2012) CC: ashishk Last updated: 2012-11-21 14:49:40 +0100 ## Comment 17764 Date: 2012-10-09 12:31:21 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.4 (KHTML, like Gecko) Chrome/22.0.1229.79 Safari/537.4 Build Identifier: As of now there is no way we can switch of UDP discovery mode to be disabled. Though it is a very good feature but may not be acceptable in certain situations Reproducible: Always ### Steps to Reproduce: 1.Set Discovery to false using monetdbd 2.Try to start server 3.Server startup fails with a message uanble to check status. ### Actual Results: server startup fails ### Expected Results: Server start up should succeed with Discovery disabled. ## Comment 17765 Date: 2012-10-09 12:54:01 +0200 From: @grobian This is indeed a stupid logic error. ## Comment 17766 Date: 2012-10-09 12:58:20 +0200 From: @grobian Changeset [4450ff9fa3f2](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=4450ff9fa3f2) made by Fabian Groffen <fabian@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=4450ff9fa3f2](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=4450ff9fa3f2) Changeset description: merovingian: fix logic error for discovery We shouldn't treat discovery being disabled as failure, but just optionally skip setting up the UDP channel. Fixes bug #3155. ## Comment 17767 Date: 2012-10-09 12:59:42 +0200 From: @grobian Fixed ## Comment 17769 Date: 2012-10-09 14:02:45 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; when next stable build with this fix is scheduled? any hints on exact date will be helpful! Thanks! ## Comment 17772 Date: 2012-10-09 14:04:53 +0200 From: @grobian It's being built right now, so, I hope today or tomorrow to release the release candidate. If that one behaves well, we can release it next week. Any testing would be appreciated. ## Comment 17811 Date: 2012-10-14 11:13:52 +0200 From: Ashish Kumar Singh &lt;<ashishk>&gt; HI, When is release candidate going to be out? Is it on track? Regards, Ashish ## Comment 17813 Date: 2012-10-15 08:30:50 +0200 From: @grobian (In reply to comment 6) > When is release candidate going to be out? Is it on track? not really, there hasn't been much feedback yet, and a fix was made for an issue that might warrant a rebuild I think we'll evaluate tomorrow. ## Comment 17814 Date: 2012-10-15 08:32:23 +0200 From: @grobian in case you're looking for the candidate itself, you can find it here: http://dev.monetdb.org/downloads/testing/ ## Comment 17974 Date: 2012-11-21 14:49:40 +0100 From: @sjoerdmullender Oct2012-SP1 has been released.
Provide an option for setting discovery to false
https://api.github.com/repos/MonetDB/MonetDB/issues/3155/comments
0
2020-11-30T12:13:43Z
2024-06-27T11:57:40Z
https://github.com/MonetDB/MonetDB/issues/3155
753,427,500
3,155
[ "MonetDB", "MonetDB" ]
Date: 2012-10-03 14:21:00 +0200 From: @grobian To: SQL devs &lt;<bugs-sql>&gt; Version: -- development Last updated: 2012-11-07 19:08:54 +0100 ## Comment 17763 Date: 2012-10-03 14:21:00 +0200 From: @grobian http://monetdb.cwi.nl/testweb/web/testchange.php?test=45638:ecdf6c0649ee/GNU-Fedora-x86_64-propcheck-assert/sql/mTests/test%2FBugTracker-2009%2Freorder.SF-2770608 Test fails since [c360e613b861](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=c360e613b861) ## Comment 17898 Date: 2012-11-07 19:08:54 +0100 From: @grobian 45727:8dea6abd4c90 apparently fixed this as side-effect
BugTracker-2009/reorder.SF-2770608 fails since leftfetchjoin changes
https://api.github.com/repos/MonetDB/MonetDB/issues/3154/comments
0
2020-11-30T12:13:41Z
2024-06-27T11:57:39Z
https://github.com/MonetDB/MonetDB/issues/3154
753,427,462
3,154
[ "MonetDB", "MonetDB" ]
Date: 2012-10-01 17:37:35 +0200 From: gordon &lt;<gordon>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.13.3 (Oct2012) CC: mrunal.gawade, @njnes, @skinkie, y.kargin Duplicates: #3198 Last updated: 2012-11-28 11:16:53 +0100 ## Comment 17762 Date: 2012-10-01 17:37:35 +0200 From: gordon &lt;<gordon>&gt; User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/535.19 (KHTML, like Gecko) Chrome/18.0.1025.151 Safari/535.19 Build Identifier: Hello, Got this error message (in the merovingian.log): == mserver5: sql_gencode.c:864: _dumpstmt: Assertion `s->nrcols' failed. == After trying the following query using "union": === select 'total', 'a', 'b', 'c', sum(count) as counts from bc251 union select track, category, name, orien, sum(count) as counts from bc251 group by track, category, name, orien order by reads desc limit 100 ; === Each of the two 'selects' without the union work fine. Reproducible: Always ### Steps to Reproduce: 1. Run the query. 2. 3. ### Actual Results: Server crashes with SIGABRT, mclient exits with "connection terminated". ### Expected Results: Results of the query. Using MonetDB 5 server v11.14.0, HG changeset 45564:14983b3e103e (compiled from source). ## Comment 17786 Date: 2012-10-10 13:38:19 +0200 From: @grobian (In reply to comment 0) > Each of the two 'selects' without the union work fine. Are you sure of this? You reference reads from order by, but don't use it in select, which causes the parser to complain here (after trying to fix column names for your set). ## Comment 17787 Date: 2012-10-10 17:48:25 +0200 From: gordon &lt;<gordon>&gt; Hello Fabian, (In reply to comment 1) > (In reply to comment 0) > > Each of the two 'selects' without the union work fine. > > Are you sure of this? You reference reads from order by, but don't use it in > select, which causes the parser to complain here (after trying to fix column > names for your set). Yes - the bug is reproducible. I had a typo in the bug report above, but I sent you an email (privately) with the exact query that triggers the bug on the same table (bc251). ## Comment 18015 Date: 2012-11-26 16:54:36 +0100 From: @njnes also this one is fixed on default but still a problem on Oct2012 (seems deep in the string bat handling) Is related or even duplicate of 3165 ## Comment 18157 Date: 2012-11-27 17:15:26 +0100 From: Yagiz &lt;<y.kargin>&gt; We can not write a test because we cannot publish the data. ## Comment 18176 Date: 2012-11-28 11:10:45 +0100 From: @njnes *** Bug #3198 has been marked as a duplicate of this bug. *** ## Comment 18178 Date: 2012-11-28 11:16:53 +0100 From: @njnes *** This bug has been marked as a duplicate of bug #3198 ***
mserver5: sql_gencode.c:864: _dumpstmt: Assertion `s->nrcols' failed.
https://api.github.com/repos/MonetDB/MonetDB/issues/3153/comments
0
2020-11-30T12:13:37Z
2024-06-28T13:17:26Z
https://github.com/MonetDB/MonetDB/issues/3153
753,427,409
3,153
[ "MonetDB", "MonetDB" ]
Date: 2012-09-19 21:48:08 +0200 From: gordon &lt;<gordon>&gt; To: GDK devs &lt;<bugs-common>&gt; Version: 11.15.15 (Feb2013-SP4) CC: @hannesmuehleisen, @lsidir, @drstmane Last updated: 2013-10-08 11:33:06 +0200 ## Comment 17747 Date: 2012-09-19 21:48:08 +0200 From: gordon &lt;<gordon>&gt; Created attachment 147 The server log. Hello, Trying a simple query on a new database with 1.6M entries, the server crashes. Attached is the log. The query was: select name, max(category), count(*) as count, sum(reads) as sum from bc251 group by name Executed using "mclient". The server was compiled from source on CentOS 5.4 . I can provide other technical details if needed. -gordon > Attached file: [merovingian.log](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3152_merovingian.log_147) (text/x-log, 26095 bytes) > Description: The server log. ## Comment 17748 Date: 2012-09-19 22:13:42 +0200 From: gordon &lt;<gordon>&gt; Hello again, I tried the same with Jl2012-SP2 ( compiled from source ) . The query still fails, but the error is now: === 2012-09-19 16:11:06 MSG voc[8903]: MonetDB 5 server v11.11.11 "Jul2012-SP2" 2012-09-19 16:11:06 MSG voc[8903]: Serving database 'voc', using 8 threads 2012-09-19 16:11:06 MSG voc[8903]: Compiled for x86_64-redhat-linux-gnu/64bit with 64bit OIDs dynamically linked 2012-09-19 16:11:06 MSG voc[8903]: Found 15.677 GiB available main-memory. 2012-09-19 16:11:06 MSG voc[8903]: Copyright (c) 1993-July 2008 CWI. 2012-09-19 16:11:06 MSG voc[8903]: Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved 2012-09-19 16:11:06 MSG voc[8903]: Visit http://www.monetdb.org/ for further information 2012-09-19 16:11:06 MSG voc[8903]: Listening for UNIX domain connection requests on mapi:monetdb:///localdata/gordon/monetdb/testdb/voc/.mapi.sock 2012-09-19 16:11:06 MSG voc[8903]: MonetDB/JAQL module loaded 2012-09-19 16:11:06 MSG voc[8903]: MonetDB/SQL module loaded 2012-09-19 16:11:06 MSG merovingian[8880]: proxying client (local) for database 'voc' to mapi:monetdb:///localdata/gordon/monetdb/testdb/voc/.mapi.sock?database=voc 2012-09-19 16:11:06 MSG merovingian[8880]: target connection is on local UNIX domain socket, passing on filedescriptor instead of proxying 2012-09-19 16:11:06 ERR voc[8903]: mserver5: gdk_heap.c:477: GDKupgradevarheap: Assertion `c->heap.parentid == 0' failed. 2012-09-19 16:11:06 MSG merovingian[8880]: database 'voc' (8903) was killed by signal SIGABRT === Regards, -gordon ## Comment 17749 Date: 2012-09-19 22:26:40 +0200 From: gordon &lt;<gordon>&gt; One more update: Running with the latest version: === changeset: 45564:14983b3e103e tag: tip user: Sjoerd Mullender <sjoerd@acm.org> date: Wed Sep 19 13:43:44 2012 +0200 summary: Backout changeset [48d5a5381005](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=48d5a5381005) === works fine (doesn't crash, with the same query). But I'm too worried to use an unreleased version for a production server. Will the final Jul2012_SP2 include the fix? Thanks, -gordon ## Comment 17751 Date: 2012-09-25 17:27:58 +0200 From: @grobian GDK problem, not monetdbd/merovingian ## Comment 17752 Date: 2012-09-25 17:30:07 +0200 From: @grobian (In reply to comment 2) > One more update: > > Running with the latest version: > === > changeset: 45564:14983b3e103e > tag: tip > user: Sjoerd Mullender <sjoerd@acm.org> > date: Wed Sep 19 13:43:44 2012 +0200 > summary: Backout changeset [48d5a5381005](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=48d5a5381005) > === > > works fine (doesn't crash, with the same query). > > But I'm too worried to use an unreleased version for a production server. > > Will the final Jul2012_SP2 include the fix? That commit was on the default branch, undoing another commit on the default branch, so unlikely. The released Jul2012-SP2 won't change either. Does it also crash using the Oct2012 branch? ## Comment 17754 Date: 2012-09-25 18:03:50 +0200 From: gordon &lt;<gordon>&gt; (In reply to comment 4) > (In reply to comment 2) > > One more update: > > > > Running with the latest version: > > changeset: 45564:14983b3e103e > > > > works fine (doesn't crash, with the same query). > > That commit was on the default branch, undoing another commit on the default > branch, so unlikely. The released Jul2012-SP2 won't change either. > > Does it also crash using the Oct2012 branch? Yes. The version I've used: == $ hg update -C -r Oct2012 $ hg id [b3df9ec1a3e0](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=b3df9ec1a3e0) (Oct2012) == I've created a new dbfarm, created a new table, and re-loaded the same data. Running the same query crashes the server. The log file contains: === 2012-09-25 11:56:51 ERR voc[29623]: mserver5: gdk_heap.c:488: GDKupgradevarheap: Assertion `c->heap.parentid == 0' failed. 2012-09-25 11:56:51 ERR voc[29623]: mserver5: gdk_heap.c:488: GDKupgradevarheap: Assertion `c->heap.parentid == 0' failed. 2012-09-25 11:56:51 ERR voc[29623]: mserver5: gdk_heap.c:488: GDKupgradevarheap: Assertion `c->heap.parentid == 0' failed. 2012-09-25 11:56:51 ERR voc[29623]: mserver5: gdk_heap.c:488: GDKupgradevarheap: Assertion `c->heap.parentid == 0' failed. 2012-09-25 11:56:51 ERR voc[29623]: mserver5: gdk_heap.c:488: GDKupgradevarheap: Assertion `c->heap.parentid == 0' failed. 2012-09-25 11:56:51 ERR voc[29623]: mserver5: gdk_heap.c:488: GDKupgradevarheap: Assertion `c->heap.parentid == 0' failed. 2012-09-25 11:56:51 MSG merovingian[29606]: database 'voc' (29623) was killed by signal SIGABRT === (the error was printed 6 times) ## Comment 17755 Date: 2012-09-25 19:29:12 +0200 From: @grobian With gordon's data, I can reproduce the problem. 0 0x0000003f15a36285 in raise () from /lib64/libc.so.6 1 0x0000003f15a37b9b in abort () from /lib64/libc.so.6 2 0x0000003f15a2ee9e in __assert_fail_base () from /lib64/libc.so.6 3 0x0000003f15a2ef42 in __assert_fail () from /lib64/libc.so.6 4 0x00007ffff702ceb0 in GDKupgradevarheap (c=0x7fffbc009050, v=<optimized out>, copyall=<optimized out>) at /ufs/fabian/scratch/ssd/monetdb/Oct2012/hgrepo/gdk/gdk_heap.c:488 5 0x00007ffff78d7b4b in aggrX3_max3_any_var_ptr (e=<optimized out>, g=<optimized out>, b=<optimized out>, ret=0x7fffe916cae0) at /ufs/fabian/scratch/ssd/monetdb/Oct2012/hgrepo/monetdb5/modules/kernel/aggr_bge_minmax.mx:108 6 CMDaggrX3_max3 (ret=0x7fffe916cae0, b=<optimized out>, g=<optimized out>, e=<optimized out>) at /ufs/fabian/scratch/ssd/monetdb/Oct2012/hgrepo/monetdb5/modules/kernel/aggr_bge_minmax.mx:448 7 0x00007ffff7a8c3ce in AX3aggrX3_max3 (ret=0x7fffdc0ebe90, bid=<optimized out>, gid=<optimized out>, eid=<optimized out>) at /ufs/fabian/scratch/ssd/monetdb/Oct2012/hgrepo/monetdb5/modules/kernel/aggr.mx:660 8 0x00007ffff762a422 in DFLOWstep (t=<optimized out>, fs=<optimized out>) at /ufs/fabian/scratch/ssd/monetdb/Oct2012/hgrepo/monetdb5/mal/mal_dataflow.c:484 9 0x00007ffff762b80b in runDFLOWworker (t=0x7fffdc0db5c8) at /ufs/fabian/scratch/ssd/monetdb/Oct2012/hgrepo/monetdb5/mal/mal_dataflow.c:832 10 0x0000003f16607d90 in start_thread () from /lib64/libpthread.so.0 11 0x0000003f15af119d in clone () from /lib64/libc.so.6 It seems this part leads to this (invalid?) BAT | X_108:bat[:oid,:str] := sql.bind(X_2,"sys","XXX","YYY",0,1,8); | X_130:bat[:oid,:str] := sql.bind(X_2,"sys","XXX","YYY",2,1,8); | X_280 := algebra.kdifference(X_108,X_130); | | X_289 := algebra.kunion(X_280,X_130); | | X_305 := algebra.kdifference(X_289,X_11); | | X_315 := aggr.max(X_305,X_216,X_242); ## Comment 18125 Date: 2012-11-27 15:44:06 +0100 From: @lsidir Changeset [929e19365437](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=929e19365437) made by lsidir <lsidir@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=929e19365437](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=929e19365437) Changeset description: A workaround fix for bug #3152 - DO NOT PROPAGATE. The "trick" of creating a view and then forcing value updates does not work for strings if the vheap needs to be extended. ## Comment 18126 Date: 2012-11-27 15:44:28 +0100 From: @lsidir I checked the current branch and the bug does not appear. For the Oct2012 release a workaround has been provided. ## Comment 18183 Date: 2012-11-28 11:48:35 +0100 From: @drstmane Re-opened, as we also should add test for bug that are fixed / work by now, just to monitor when they re-appear. ## Comment 18215 Date: 2012-11-28 17:31:31 +0100 From: @lsidir Changeset [822e78b1baa5](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=822e78b1baa5) made by lsidir <lsidir@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=822e78b1baa5](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=822e78b1baa5) Changeset description: A more ellegant fix for bug #3152 - DO NOT PROPAGATE.
mserver5: gdk_heap.c:477: GDKupgradevarheap: Assertion `c->heap.parentid == 0' failed
https://api.github.com/repos/MonetDB/MonetDB/issues/3152/comments
0
2020-11-30T12:13:33Z
2024-06-27T11:57:37Z
https://github.com/MonetDB/MonetDB/issues/3152
753,427,363
3,152
[ "MonetDB", "MonetDB" ]
Date: 2012-09-18 00:06:03 +0200 From: jdixon To: Merovingian devs &lt;<bugs-merovingian>&gt; Version: 11.11.7 (Jul2012-SP1) CC: @drstmane Last updated: 2013-03-12 03:19:26 +0100 ## Comment 17740 Date: 2012-09-18 00:06:03 +0200 From: jdixon User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:15.0) Gecko/20100101 Firefox/15.0.1 Build Identifier: After creating, populating, and dropping a table in a loop the server will eventually crash and connections via mclient or JDBC will be refused from that point on. Here is the crash report: Process: monetdbd [23886] Path: /usr/local/monetdb/bin/monetdbd Identifier: monetdbd Version: ??? (???) Code Type: X86-64 (Native) Parent Process: ??? [1] Date/Time: 2012-09-17 17:44:41.094 -0400 OS Version: Mac OS X 10.7.4 (11E53) Report Version: 9 Crashed Thread: 0 Dispatch queue: com.apple.main-thread Exception Type: EXC_CRASH (SIGABRT) Exception Codes: 0x0000000000000000, 0x0000000000000000 Application Specific Information: *** error for object 0x1005008e0: pointer being freed was not allocated Thread 0 Crashed:: Dispatch queue: com.apple.main-thread 0 libsystem_kernel.dylib 0x00007fff8d2f9ce2 __pthread_kill + 10 1 libsystem_c.dylib 0x00007fff8d3957d2 pthread_kill + 95 2 libsystem_c.dylib 0x00007fff8d386a7a abort + 143 3 libsystem_c.dylib 0x00007fff8d3e584c free + 389 4 monetdbd 0x000000010001105e freeConfFile + 30 5 monetdbd 0x00000001000025b5 main + 4357 6 monetdbd 0x0000000100001484 start + 52 Thread 0 crashed with X86 Thread State (64-bit): rax: 0x0000000000000000 rbx: 0x0000000000000006 rcx: 0x00007fff5fbfe7d8 rdx: 0x0000000000000000 rdi: 0x0000000000000203 rsi: 0x0000000000000006 rbp: 0x00007fff5fbfe800 rsp: 0x00007fff5fbfe7d8 r8: 0x00007fff79269fb8 r9: 0x00007fff8d3f8230 r10: 0x00007fff8d2f9d0a r11: 0xffffff80002da8d0 r12: 0x000000010043a000 r13: 0x0000000000000001 r14: 0x00007fff7926c960 r15: 0x0000000000000001 rip: 0x00007fff8d2f9ce2 rfl: 0x0000000000000246 cr2: 0x000000010043b000 Logical CPU: 0 Binary Images: 0x100000000 - 0x10001afe7 +monetdbd (??? - ???) <2D60B00B-DFD9-36A4-83BD-55E665572172> /usr/local/monetdb/bin/monetdbd 0x10001f000 - 0x100027fff +libstream.3.dylib (5.3.0 - compatibility 5.0.0) <F45DC4B6-36E0-3FB7-8808-98D8CA326C7E> /usr/local/monetdb/lib/libstream.3.dylib 0x10002b000 - 0x10003cfff +libmapi.6.dylib (7.2.0 - compatibility 7.0.0) <7130C005-DA28-3A42-83A8-AF92A715EE78> /usr/local/monetdb/lib/libmapi.6.dylib 0x100041000 - 0x100055fe7 +libz.1.dylib (1.2.7 - compatibility 1.0.0) <B5329CF9-DE09-3F60-976E-E6C9B80B5E25> /usr/local/monetdb/lib/monetdb/external/libz.1.dylib 0x100059000 - 0x100067fff +libbz2.1.dylib (1.0.6 - compatibility 1.0.0) <460F9BFC-6A75-A651-72BB-3355FC469031> /usr/local/monetdb/lib/monetdb/external/libbz2.1.dylib 0x10006b000 - 0x1000c3fef +libcurl.4.dylib (7.0.0 - compatibility 7.0.0) <7CE9F350-E381-3239-B0A5-EA75EAD9157D> /usr/local/monetdb/lib/monetdb/external/libcurl.4.dylib 0x1000cf000 - 0x1001b2ff7 +libiconv.2.dylib (8.1.0 - compatibility 8.0.0) <2A1FD19B-5875-3A42-AC2A-1F4125546C8F> /usr/local/monetdb/lib/monetdb/external/libiconv.2.dylib 0x1001be000 - 0x100211ff7 +libssl.1.0.0.dylib (??? - ???) <6CEE0EA6-A257-3540-A453-F8A5C6A8F4F7> /usr/local/monetdb/lib/monetdb/external/libssl.1.0.0.dylib 0x10022f000 - 0x100397fef +libcrypto.1.0.0.dylib (??? - ???) <3BC18C7F-CD19-3BC1-998D-53D7D73E8E22> /usr/local/monetdb/lib/monetdb/external/libcrypto.1.0.0.dylib 0x7fff6a15d000 - 0x7fff6a191baf dyld (195.6 - ???) <0CD1B35B-A28F-32DA-B72E-452EAD609613> /usr/lib/dyld 0x7fff88bdb000 - 0x7fff88bdcff7 libsystem_blocks.dylib (53.0.0 - compatibility 1.0.0) <8BCA214A-8992-34B2-A8B9-B74DEACA1869> /usr/lib/system/libsystem_blocks.dylib 0x7fff8bb29000 - 0x7fff8bb33ff7 liblaunch.dylib (392.38.0 - compatibility 1.0.0) <6ECB7F19-B384-32C1-8652-2463C1CF4815> /usr/lib/system/liblaunch.dylib 0x7fff8bf3d000 - 0x7fff8bf41fff libdyld.dylib (195.6.0 - compatibility 1.0.0) <FFC59565-64BD-3B37-90A4-E2C3A422CFC1> /usr/lib/system/libdyld.dylib 0x7fff8c436000 - 0x7fff8c43cff7 libunwind.dylib (30.0.0 - compatibility 1.0.0) <1E9C6C8C-CBE8-3F4B-A5B5-E03E3AB53231> /usr/lib/system/libunwind.dylib 0x7fff8d1d3000 - 0x7fff8d1d4fff libdnsinfo.dylib (395.11.0 - compatibility 1.0.0) <853BAAA5-270F-3FDC-B025-D448DB72E1C3> /usr/lib/system/libdnsinfo.dylib 0x7fff8d2e3000 - 0x7fff8d303fff libsystem_kernel.dylib (1699.26.8 - compatibility 1.0.0) <1DDC0B0F-DB2A-34D6-895D-E5B2B5618946> /usr/lib/system/libsystem_kernel.dylib 0x7fff8d345000 - 0x7fff8d422fef libsystem_c.dylib (763.13.0 - compatibility 1.0.0) <41B43515-2806-3FBC-ACF1-A16F35B7E290> /usr/lib/system/libsystem_c.dylib 0x7fff8e30b000 - 0x7fff8e30bfff libkeymgr.dylib (23.0.0 - compatibility 1.0.0) <61EFED6A-A407-301E-B454-CD18314F0075> /usr/lib/system/libkeymgr.dylib 0x7fff8e41e000 - 0x7fff8e423fff libcompiler_rt.dylib (6.0.0 - compatibility 1.0.0) <98ECD5F6-E85C-32A5-98CD-8911230CB66A> /usr/lib/system/libcompiler_rt.dylib 0x7fff8ee35000 - 0x7fff8ee37fff libquarantine.dylib (36.6.0 - compatibility 1.0.0) <0EBF714B-4B69-3E1F-9A7D-6BBC2AACB310> /usr/lib/system/libquarantine.dylib 0x7fff8ee38000 - 0x7fff8ee3cfff libmathCommon.A.dylib (2026.0.0 - compatibility 1.0.0) <FF83AFF7-42B2-306E-90AF-D539C51A4542> /usr/lib/system/libmathCommon.A.dylib 0x7fff8f2dc000 - 0x7fff8f2e4fff libsystem_dnssd.dylib (??? - ???) <D9BB1F87-A42B-3CBC-9DC2-FC07FCEF0016> /usr/lib/system/libsystem_dnssd.dylib 0x7fff8f844000 - 0x7fff8f849fff libcache.dylib (47.0.0 - compatibility 1.0.0) <1571C3AB-BCB2-38CD-B3B2-C5FC3F927C6A> /usr/lib/system/libcache.dylib 0x7fff9044c000 - 0x7fff9044dff7 libremovefile.dylib (21.1.0 - compatibility 1.0.0) <739E6C83-AA52-3C6C-A680-B37FE2888A04> /usr/lib/system/libremovefile.dylib 0x7fff9091f000 - 0x7fff90924ff7 libsystem_network.dylib (??? - ???) <5DE7024E-1D2D-34A2-80F4-08326331A75B> /usr/lib/system/libsystem_network.dylib 0x7fff9094f000 - 0x7fff90956fff libcopyfile.dylib (85.1.0 - compatibility 1.0.0) <0AB51EE2-E914-358C-AC19-47BC024BDAE7> /usr/lib/system/libcopyfile.dylib 0x7fff90a22000 - 0x7fff90a5dfff libsystem_info.dylib (??? - ???) <35F90252-2AE1-32C5-8D34-782C614D9639> /usr/lib/system/libsystem_info.dylib 0x7fff9147d000 - 0x7fff91483fff libmacho.dylib (800.0.0 - compatibility 1.0.0) <165514D7-1BFA-38EF-A151-676DCD21FB64> /usr/lib/system/libmacho.dylib 0x7fff91677000 - 0x7fff916b9ff7 libcommonCrypto.dylib (55010.0.0 - compatibility 1.0.0) <BB770C22-8C57-365A-8716-4A3C36AE7BFB> /usr/lib/system/libcommonCrypto.dylib 0x7fff91e31000 - 0x7fff91e32ff7 libsystem_sandbox.dylib (??? - ???) <96D38E74-F18F-3CCB-A20B-E8E3ADC4E166> /usr/lib/system/libsystem_sandbox.dylib 0x7fff9272f000 - 0x7fff9274cfff libxpc.dylib (77.19.0 - compatibility 1.0.0) <9F57891B-D7EF-3050-BEDD-21E7C6668248> /usr/lib/system/libxpc.dylib 0x7fff92d57000 - 0x7fff92d60ff7 libsystem_notify.dylib (80.1.0 - compatibility 1.0.0) <A4D651E3-D1C6-3934-AD49-7A104FD14596> /usr/lib/system/libsystem_notify.dylib 0x7fff93efb000 - 0x7fff93f28fe7 libSystem.B.dylib (159.1.0 - compatibility 1.0.0) <7BEBB139-50BB-3112-947A-F4AA168F991C> /usr/lib/libSystem.B.dylib 0x7fff95ad1000 - 0x7fff95ad2fff libunc.dylib (24.0.0 - compatibility 1.0.0) <337960EE-0A85-3DD0-A760-7134CF4C0AFF> /usr/lib/system/libunc.dylib 0x7fff95c0a000 - 0x7fff95c18fff libdispatch.dylib (187.9.0 - compatibility 1.0.0) <1D5BE322-A9B9-3BCE-8FAC-076FB07CF54A> /usr/lib/system/libdispatch.dylib External Modification Summary: Calls made by other processes targeting this process: task_for_pid: 0 thread_create: 0 thread_set_state: 0 Calls made by this process: task_for_pid: 0 thread_create: 0 thread_set_state: 0 Calls made by all processes on this machine: task_for_pid: 5323 thread_create: 0 thread_set_state: 0 VM Region Summary: ReadOnly portion of Libraries: Total=54.1M resident=21.9M(40%) swapped_out_or_unallocated=32.2M(60%) Writable regions: Total=80.6M written=660K(1%) resident=744K(1%) swapped_out=0K(0%) unallocated=79.9M(99%) REGION TYPE VIRTUAL =========== ======= MALLOC 72.2M MALLOC guard page 16K STACK GUARD 56.0M Stack 8192K VM_ALLOCATE 8K __DATA 704K __LINKEDIT 48.3M __TEXT 5888K shared memory 12K =========== ======= TOTAL 191.0M Reproducible: Always ### Steps to Reproduce: Use this script with a database called 'test': for i in {1..10000} do echo "Running load $i " /usr/local/monetdb/bin/mclient test < 1-drop.txt /usr/local/monetdb/bin/mclient test < 2-create.txt /usr/local/monetdb/bin/mclient test < 3-load.txt if [ "$?" == "2" ] then echo "dead" break fi done Here is the contents of 1-drop.txt drop table test1; Here is the contents of 2-create.txt CREATE TABLE test1 ( Country VARCHAR(33) , Adult_HIV_ DOUBLE , Adult_Obesity_ DOUBLE , Aids_Deaths_est BIGINT , Airports BIGINT , Area_sq_km BIGINT , Birth_rate_per_k_pop DOUBLE , Budget_Surplus__GDP DOUBLE , Current_Account_ BIGINT , Death_rate_per_k_pop DOUBLE , Education_Spend_GDP DOUBLE , Elec_Consumption_kwhr BIGINT , Elec_Exports_kwhr BIGINT , Elec_Imports_kwhr BIGINT , Elec_Production_kwhr BIGINT , Exports_ BIGINT , External_Debt_ BIGINT , Fertility_Rate DOUBLE , Foreign_Investment__Abroad_ BIGINT , Foreign_Investment__Home_ BIGINT , Nat_Gas_Consumption_cubic_m BIGINT , Nat_Gas_Export_cubic_m BIGINT , Nat_Gas_Import_cubic_m BIGINT , Nat_Gas_Production_cubic_m BIGINT , Nat_Gas_Reserves_cubic_m BIGINT , GDP__PPP BIGINT , Healthcare_Spend_GDP DOUBLE , Imports_ BIGINT , Infant_Mortality_per_1k DOUBLE , Inflation_Rate_ DOUBLE , Internet_Hosts BIGINT , Internet_Users BIGINT , Investment_Fixed_Assest__GDP BIGINT , Labor_Force BIGINT , Life_Expectancy BIGINT , Maternal_Mortality_per_100k BIGINT , Merchant_Marine BIGINT , Migration_per_1k_pop DOUBLE , Military_Spend_GDP DOUBLE , Oil_Consumption_bblday BIGINT , Oil_Exports_bblday BIGINT , Oil_Imports_bblday BIGINT , Oil_Production_bblday BIGINT , Oil_Reserves_bbl BIGINT , Population_Growth_Rate DOUBLE , Population_With_HIV BIGINT , Population BIGINT , Public_Debt_GPD DOUBLE , Taxes__Govt_Revenue_GPD DOUBLE , Telephone_land_lines BIGINT , Telephone_cellphones BIGINT , Underweight_Children_ DOUBLE , Unemployment_Rate_1524yrs DOUBLE , Unemployment_Rate DOUBLE , Area_sq_m BIGINT , BirthDeath_Delta BIGINT , Elec_Total_kwhr BIGINT , Elec_Total_Used_kwhr BIGINT , Foreign_Investment_Delta_ BIGINT , Education_Spend__PPP BIGINT , Healthcare_Spend__PPP BIGINT , Trade_Gap_ BIGINT , Military_Spend__PPP BIGINT , GDP_Per_Capita BIGINT , Education_Spend_Per_Capita_PPP_per_person BIGINT , Elec_Consumption_Per_Capita_khhr_per_person BIGINT , Healthcare_Spend_Per_Capita_PPP_per_person BIGINT , _Internet_Users BIGINT , Labor_as__Population BIGINT , Military_Spend_Per_Capita_PPP_per_person BIGINT , Nat_Gas_Consumption_Per_Capita_cubic_m_per_person DOUBLE , Oil_Consumption_Per_Capita_bbl_per_person_per_day BIGINT , Population_Density_sq_km BIGINT , Population_Density_sq_m BIGINT ); Here is the contents of 3-load.txt COPY 256 RECORDS INTO test1 FROM STDIN USING DELIMITERS '|','\n','"';"Afghanistan"|0.01|null|null|53|652230|39.3|-9.6|-2475000000|14.59|null|231100000|0|120000000|285500000|571000000|1280000000|5.64|null|null|30000000|0|0|30000000|49550000000|29990000000|7.4|5300000000|121.63|7.7|121|1000000|null|15000000|49|1400|null|-2.51|1.9|4800|0|4512|0|0|2.22|null|30419928|null|8.8|140000|13000000|32.9|null|35.0|251827|25|405500000|231100000|null|null|2219260000|-4729000000|569810000|985|null|7|72|3|49|18|0.9862|0|46|120 "Akrotiri"|null|null|null|null|123|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|15700|null|null|null|null|null|null|null|47|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|null|127|334 "Albania"|null|null|null|5|28748|12.38|-3.5|-1380000000|6.25|null|6593000000|0|1884000000|5201000000|1886000000|5700000000|1.48|null|null|30000000|0|0|30000000|849500000|24990000000|6.9|5022000000|14.12|3.9|15505|1300000|31|1053000|77|31|17|-3.33|1.49|33000|1004|22880|10930|199100000|0.28|null|3002859|59.4|25.6|331500|4548000|6.6|35.5|13.4|11100|6|7085000000|6593000000|null|null|1724310000|-3136000000|372351000|8322|null|2195|574|43|35|123|9.99048|0|104|270 "Algeria"|0.1|null|1000|143|2381741|16.64|-2.1|18120000000|4.72|4.3|30500000000|323000000|49000000|40110000000|78510000000|4421000000|1.74|1944000000|24530000000|29860000000|55280000000|0|85140000000|4502000000000|264100000000|5.8|49840000000|24.9|4.0|561|4700000|33|11130000|74|120|38|-0.27|3.3|312000|1694000|18180|2078000|12200000000|1.17|18000|35406303|6.6|47.8|2923000|32780000|3.7|24.3|9.7|919595|12|40159000000|30823000000|-22586000000|11356300000|15317800000|28670000000|8715300000|7459|320|861|432|13|31|246|843.35267|0|14|38 "American Samoa"|null|74.6|null|3|199|22.69|-6.1|null|4.11|null|176700000|0|0|190000000|445600000|null|3.1|null|null|0|0|0|0|0|575300000|null|308800000|9.42|null|2368|null|null|17630|74|null|null|-6.46|null|4400|0|4440|0|0|1.21|null|68061|null|33.6|10400|2200|null|null|29.8|77|19|190000000|176700000|null|null|null|136800000|null|8452|null|2596|null|null|25|null|0.0|0|342|883 ### Actual Results: After 162 iterations the script fails due to a failure on the server ...[lines deleted]... Running load 159 operation successful operation successful 256 affected rows Running load 160 operation successful operation successful 256 affected rows Running load 161 operation successful operation successful 256 affected rows Running load 162 operation successful operation successful Connection terminated dead ### Expected Results: The script should execute the loop 10000 times successfully I have tried the 11.11.7 release and the December 2011 SP2 release. They give the same result. This issue causes a server crash so I'm rating it as a critical. ## Comment 17741 Date: 2012-09-18 00:07:24 +0200 From: jdixon Created attachment 143 Test script Run this bash script to reproduce the error > Attached file: [testmonet.sh](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3151_testmonet.sh_143) (text/plain, 291 bytes) > Description: Test script ## Comment 17742 Date: 2012-09-18 00:08:07 +0200 From: jdixon Created attachment 144 Test file 1 Used by the test script > Attached file: [1-drop.txt](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3151_1-drop.txt_144) (text/plain, 17 bytes) > Description: Test file 1 ## Comment 17743 Date: 2012-09-18 00:08:34 +0200 From: jdixon Created attachment 145 Test file 2 Used by the test script > Attached file: [2-create.txt](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3151_2-create.txt_145) (text/plain, 2248 bytes) > Description: Test file 2 ## Comment 17744 Date: 2012-09-18 00:09:03 +0200 From: jdixon Created attachment 146 Test file 3 Used by the test script > Attached file: [3-load.txt](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3151_3-load.txt_146) (text/plain, 2263 bytes) > Description: Test file 3 ## Comment 17750 Date: 2012-09-24 20:05:51 +0200 From: @grobian Problem not in monetdbd/merovingian ## Comment 17756 Date: 2012-09-25 20:09:45 +0200 From: @grobian Misread the original report. I can't seem to reproduce however, using the script. Can you please post the output of monetdbd --version? ## Comment 17758 Date: 2012-09-25 21:00:31 +0200 From: jdixon Here is the output of monetdbd -version: MonetDB Database Server v1.6 (Jul2012-SP1) So it runs all 10000 iterations with no problem for you? If you cannot reproduce it, try increasing the loop count in the script. Thanks for looking into this. ## Comment 17759 Date: 2012-09-25 21:07:12 +0200 From: @grobian Jul2012-SP1 != Oct2012 :/ IIRC, I've already fixed this for Jul2012-SP2. ## Comment 17760 Date: 2012-09-26 03:57:41 +0200 From: jdixon Great. Thank you. Is there a way to get an interim, CI, or nightly build so I can validate this for you? ## Comment 17761 Date: 2012-09-26 08:38:26 +0200 From: @grobian How about just downloading the Jul2012-SP2 release? http://dev.monetdb.org/downloads/MacOSX/Jul2012-SP2/ ## Comment 18603 Date: 2013-03-12 00:27:18 +0100 From: @drstmane Changeset [30c2d470a73d](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=30c2d470a73d) made by Stefan Manegold <Stefan.Manegold@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=30c2d470a73d](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=30c2d470a73d) Changeset description: opt_support.c & opt_wrapper.c: "coercion" -> "coercions", i.e., using the correct optimizer name "coercions" to ensure the optimizer is indeed activated/used. Approved related changes in test output (modified MAL plans due to now active coercions optimizer). This should fix bug #3151. Thanks to Pete Hollobon for reporting and proving the initial fix! Open question: Why is an incorrect / non-exiting optimizer name silently ignored?? ## Comment 18611 Date: 2013-03-12 03:19:26 +0100 From: @drstmane The above comment / log message is not related to this bug (3151) but rather to bug #3251 .
After repeatedly creating and populating a table the server crashes with a message of 'pointer being freed was not allocated'
https://api.github.com/repos/MonetDB/MonetDB/issues/3151/comments
0
2020-11-30T12:13:30Z
2024-06-27T11:57:36Z
https://github.com/MonetDB/MonetDB/issues/3151
753,427,322
3,151
[ "MonetDB", "MonetDB" ]
Date: 2012-09-14 13:51:07 +0200 From: @grobian To: SQL devs &lt;<bugs-sql>&gt; Version: -- development CC: akkaran046 Last updated: 2018-12-31 07:11:19 +0100 ## Comment 17737 Date: 2012-09-14 13:51:07 +0200 From: @grobian This is on current Jul2012 (thus post -SP2) After [70aff6bf7838](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=70aff6bf7838) Test_JdbcClient fails to report some constraints for a table produced. This appears to be due to a rewrite of simple LIKE expressions to equality expressions. The JDBC call (DatabaseMetaData.getImportedKeys()) indeed uses LIKE expressions to match schema and table name. Ever since this commit, those expressions are rewritten to simple equality tests, which I believe triggers a bug further on, resulting in incorrectly no result rows. The problem is nicely illustrated by the following queries. The changes are at the end of the query, there schema and table name are matched using like, equality, and with/without pattern (to avoid triggering the rewrite): SELECT 'squirrel' AS "PKTABLE_CAT", 'squirrel' AS "FKTABLE_CAT", "pkschema"."name" AS "PKTABLE_SCHEM", "pktable"."name" AS "PKTABLE_NAME", "pkkeycol"."name" AS "PKCOLUMN_NAME", "fkschema"."name" AS "FKTABLE_SCHEM", "fktable"."name" AS "FKTABLE_NAME", "fkkeycol"."name" AS "FKCOLUMN_NAME", "pkkeycol"."nr" AS "KEY_SEQ", 3 AS "UPDATE_RULE", 3 AS "DELETE_RULE", "fkkey"."name" AS "FK_NAME", "pkkey"."name" AS "PK_NAME", 7 AS "DEFERRABILITY" FROM "sys"."keys" AS "fkkey", "sys"."keys" AS "pkkey", "sys". "objects" AS "fkkeycol", "sys"."objects" AS "pkkeycol", "sys"."tables" AS "fktable", "sys"."tables" AS "pktable", "sys"."schemas" AS "fkschema", "sys". "schemas" AS "pkschema" WHERE "fktable"."id" = "fkkey"."table_id" AND "pktable"."id" = "pkkey"."table_id" AND "fkkey"."id" = "fkkeycol"."id" AND "pkkey"."id" = "pkkeycol"."id" AND "fkschema"."id" = "fktable"."schema_id" AND "pkschema"."id" = "pktable"."schema_id" AND "fkkey"."rkey" > -1 AND "fkkey"."rkey" = "pkkey". "id" AND "fkkeycol"."nr" = "pkkeycol"."nr" AND LOWER("fkschema"."name") LIKE 'sys' AND LOWER("fktable"."name") LIKE 'foreign' ORDER BY "PKTABLE_CAT", "PKTABLE_SCHEM", "PKTABLE_NAME", "PK_NAME", "KEY_SEQ"; +-------------+-------------+---------------+--------------+---------------+ | PKTABLE_CAT | FKTABLE_CAT | PKTABLE_SCHEM | PKTABLE_NAME | PKCOLUMN_NAME |> +=============+=============+===============+==============+===============+ +-------------+-------------+---------------+--------------+---------------+ 0 tuples (5.495ms) !9 columns dropped! SELECT 'squirrel' AS "PKTABLE_CAT", 'squirrel' AS "FKTABLE_CAT", "pkschema"."name" AS "PKTABLE_SCHEM", "pktable"."name" AS "PKTABLE_NAME", "pkkeycol"."name" AS "PKCOLUMN_NAME", "fkschema"."name" AS "FKTABLE_SCHEM", "fktable"."name" AS "FKTABLE_NAME", "fkkeycol"."name" AS "FKCOLUMN_NAME", "pkkeycol"."nr" AS "KEY_SEQ", 3 AS "UPDATE_RULE", 3 AS "DELETE_RULE", "fkkey"."name" AS "FK_NAME", "pkkey"."name" AS "PK_NAME", 7 AS "DEFERRABILITY" FROM "sys"."keys" AS "fkkey", "sys"."keys" AS "pkkey", "sys". "objects" AS "fkkeycol", "sys"."objects" AS "pkkeycol", "sys"."tables" AS "fktable", "sys"."tables" AS "pktable", "sys"."schemas" AS "fkschema", "sys". "schemas" AS "pkschema" WHERE "fktable"."id" = "fkkey"."table_id" AND "pktable"."id" = "pkkey"."table_id" AND "fkkey"."id" = "fkkeycol"."id" AND "pkkey"."id" = "pkkeycol"."id" AND "fkschema"."id" = "fktable"."schema_id" AND "pkschema"."id" = "pktable"."schema_id" AND "fkkey"."rkey" > -1 AND "fkkey"."rkey" = "pkkey". "id" AND "fkkeycol"."nr" = "pkkeycol"."nr" AND LOWER("fkschema"."name") = 'sys' AND LOWER("fktable"."name") = 'foreign' ORDER BY "PKTABLE_CAT", "PKTABLE_SCHEM", "PKTABLE_NAME", "PK_NAME", "KEY_SEQ"; +-------------+-------------+---------------+--------------+---------------+ | PKTABLE_CAT | FKTABLE_CAT | PKTABLE_SCHEM | PKTABLE_NAME | PKCOLUMN_NAME |> +=============+=============+===============+==============+===============+ +-------------+-------------+---------------+--------------+---------------+ 0 tuples (10.375ms) !9 columns dropped! SELECT 'squirrel' AS "PKTABLE_CAT", 'squirrel' AS "FKTABLE_CAT", "pkschema"."name" AS "PKTABLE_SCHEM", "pktable"."name" AS "PKTABLE_NAME", "pkkeycol"."name" AS "PKCOLUMN_NAME", "fkschema"."name" AS "FKTABLE_SCHEM", "fktable"."name" AS "FKTABLE_NAME", "fkkeycol"."name" AS "FKCOLUMN_NAME", "pkkeycol"."nr" AS "KEY_SEQ", 3 AS "UPDATE_RULE", 3 AS "DELETE_RULE", "fkkey"."name" AS "FK_NAME", "pkkey"."name" AS "PK_NAME", 7 AS "DEFERRABILITY" FROM "sys"."keys" AS "fkkey", "sys"."keys" AS "pkkey", "sys". "objects" AS "fkkeycol", "sys"."objects" AS "pkkeycol", "sys"."tables" AS "fktable", "sys"."tables" AS "pktable", "sys"."schemas" AS "fkschema", "sys". "schemas" AS "pkschema" WHERE "fktable"."id" = "fkkey"."table_id" AND "pktable"."id" = "pkkey"."table_id" AND "fkkey"."id" = "fkkeycol"."id" AND "pkkey"."id" = "pkkeycol"."id" AND "fkschema"."id" = "fktable"."schema_id" AND "pkschema"."id" = "pktable"."schema_id" AND "fkkey"."rkey" > -1 AND "fkkey"."rkey" = "pkkey". "id" AND "fkkeycol"."nr" = "pkkeycol"."nr" AND LOWER("fkschema"."name") like 'sys%' AND LOWER("fktable"."name") like 'foreign%' ORDER BY "PKTABLE_CAT", "PKTABLE_SCHEM", "PKTABLE_NAME", "PK_NAME", "KEY_SEQ"; +----------+----------+-------+---------------+------------+-------+----------+ | PKTABLE_ | FKTABLE_ | PKTAB | PKTABLE_NAME | PKCOLUMN_N | FKTAB | FKTABLE_ |> : CAT : CAT : LE_SC : : AME : LE_SC : NAME :> : : : HEM : : : HEM : :> +==========+==========+=======+===============+============+=======+==========+ | squirrel | squirrel | sys | allnewtriples | id | sys | foreign | | squirrel | squirrel | sys | allnewtriples | subject | sys | foreign | | squirrel | squirrel | sys | allnewtriples | predicate | sys | foreign | | squirrel | squirrel | sys | allnewtriples | object | sys | foreign | +----------+----------+-------+---------------+------------+-------+----------+ 4 tuples (16.465ms) !7 columns dropped! SELECT 'squirrel' AS "PKTABLE_CAT", 'squirrel' AS "FKTABLE_CAT", "pkschema"."name" AS "PKTABLE_SCHEM", "pktable"."name" AS "PKTABLE_NAME", "pkkeycol"."name" AS "PKCOLUMN_NAME", "fkschema"."name" AS "FKTABLE_SCHEM", "fktable"."name" AS "FKTABLE_NAME", "fkkeycol"."name" AS "FKCOLUMN_NAME", "pkkeycol"."nr" AS "KEY_SEQ", 3 AS "UPDATE_RULE", 3 AS "DELETE_RULE", "fkkey"."name" AS "FK_NAME", "pkkey"."name" AS "PK_NAME", 7 AS "DEFERRABILITY" FROM "sys"."keys" AS "fkkey", "sys"."keys" AS "pkkey", "sys". "objects" AS "fkkeycol", "sys"."objects" AS "pkkeycol", "sys"."tables" AS "fktable", "sys"."tables" AS "pktable", "sys"."schemas" AS "fkschema", "sys". "schemas" AS "pkschema" WHERE "fktable"."id" = "fkkey"."table_id" AND "pktable"."id" = "pkkey"."table_id" AND "fkkey"."id" = "fkkeycol"."id" AND "pkkey"."id" = "pkkeycol"."id" AND "fkschema"."id" = "fktable"."schema_id" AND "pkschema"."id" = "pktable"."schema_id" AND "fkkey"."rkey" > -1 AND "fkkey"."rkey" = "pkkey". "id" AND "fkkeycol"."nr" = "pkkeycol"."nr" AND LOWER("fkschema"."name") like 'sys%' AND LOWER("fktable"."name") like 'foreign' ORDER BY "PKTABLE_CAT", "PKTABLE_SCHEM", "PKTABLE_NAME", "PK_NAME", "KEY_SEQ"; +----------+----------+-------+---------------+------------+-------+----------+ | PKTABLE_ | FKTABLE_ | PKTAB | PKTABLE_NAME | PKCOLUMN_N | FKTAB | FKTABLE_ |> : CAT : CAT : LE_SC : : AME : LE_SC : NAME :> : : : HEM : : : HEM : :> +==========+==========+=======+===============+============+=======+==========+ | squirrel | squirrel | sys | allnewtriples | id | sys | foreign | | squirrel | squirrel | sys | allnewtriples | subject | sys | foreign | | squirrel | squirrel | sys | allnewtriples | predicate | sys | foreign | | squirrel | squirrel | sys | allnewtriples | object | sys | foreign | +----------+----------+-------+---------------+------------+-------+----------+ 4 tuples (11.194ms) !7 columns dropped! SELECT 'squirrel' AS "PKTABLE_CAT", 'squirrel' AS "FKTABLE_CAT", "pkschema"."name" AS "PKTABLE_SCHEM", "pktable"."name" AS "PKTABLE_NAME", "pkkeycol"."name" AS "PKCOLUMN_NAME", "fkschema"."name" AS "FKTABLE_SCHEM", "fktable"."name" AS "FKTABLE_NAME", "fkkeycol"."name" AS "FKCOLUMN_NAME", "pkkeycol"."nr" AS "KEY_SEQ", 3 AS "UPDATE_RULE", 3 AS "DELETE_RULE", "fkkey"."name" AS "FK_NAME", "pkkey"."name" AS "PK_NAME", 7 AS "DEFERRABILITY" FROM "sys"."keys" AS "fkkey", "sys"."keys" AS "pkkey", "sys". "objects" AS "fkkeycol", "sys"."objects" AS "pkkeycol", "sys"."tables" AS "fktable", "sys"."tables" AS "pktable", "sys"."schemas" AS "fkschema", "sys". "schemas" AS "pkschema" WHERE "fktable"."id" = "fkkey"."table_id" AND "pktable"."id" = "pkkey"."table_id" AND "fkkey"."id" = "fkkeycol"."id" AND "pkkey"."id" = "pkkeycol"."id" AND "fkschema"."id" = "fktable"."schema_id" AND "pkschema"."id" = "pktable"."schema_id" AND "fkkey"."rkey" > -1 AND "fkkey"."rkey" = "pkkey". "id" AND "fkkeycol"."nr" = "pkkeycol"."nr" AND LOWER("fkschema"."name") like 'sys' AND LOWER("fktable"."name") like 'foreign%' ORDER BY "PKTABLE_CAT", "PKTABLE_SCHEM", "PKTABLE_NAME", "PK_NAME", "KEY_SEQ"; +-------------+-------------+---------------+--------------+---------------+ | PKTABLE_CAT | FKTABLE_CAT | PKTABLE_SCHEM | PKTABLE_NAME | PKCOLUMN_NAME |> +=============+=============+===============+==============+===============+ +-------------+-------------+---------------+--------------+---------------+ 0 tuples (7.637ms) !9 columns dropped! SELECT 'squirrel' AS "PKTABLE_CAT", 'squirrel' AS "FKTABLE_CAT", "pkschema"."name" AS "PKTABLE_SCHEM", "pktable"."name" AS "PKTABLE_NAME", "pkkeycol"."name" AS "PKCOLUMN_NAME", '|'||"fkschema"."name"||'|' AS "FKTABLE_SCHEM", "fktable"."name" AS "FKTABLE_NAME", "fkkeycol"."name" AS "FKCOLUMN_NAME", "pkkeycol"."nr" AS "KEY_SEQ", 3 AS "UPDATE_RULE", 3 AS "DELETE_RULE", "fkkey"."name" AS "FK_NAME", "pkkey"."name" AS "PK_NAME", 7 AS "DEFERRABILITY" FROM "sys"."keys" AS "fkkey", "sys"."keys" AS "pkkey", "sys". "objects" AS "fkkeycol", "sys"."objects" AS "pkkeycol", "sys"."tables" AS "fktable", "sys"."tables" AS "pktable", "sys"."schemas" AS "fkschema", "sys". "schemas" AS "pkschema" WHERE "fktable"."id" = "fkkey"."table_id" AND "pktable"."id" = "pkkey"."table_id" AND "fkkey"."id" = "fkkeycol"."id" AND "pkkey"."id" = "pkkeycol"."id" AND "fkschema"."id" = "fktable"."schema_id" AND "pkschema"."id" = "pktable"."schema_id" AND "fkkey"."rkey" > -1 AND "fkkey"."rkey" = "pkkey". "id" AND "fkkeycol"."nr" = "pkkeycol"."nr" AND LOWER("fkschema"."name") like 'sys%' AND LOWER("fktable"."name") like 'foreign' ORDER BY "PKTABLE_CAT", "PKTABLE_SCHEM", "PKTABLE_NAME", "PK_NAME", "KEY_SEQ"; +----------+----------+------+---------------+------------+--------+----------+ | PKTABLE_ | FKTABLE_ | PKTA | PKTABLE_NAME | PKCOLUMN_N | FKTABL | FKTABLE_ |> : CAT : CAT : BLE_ : : AME : E_SCHE : NAME :> : : : SCHE : : : M : :> : : : M : : : : :> +==========+==========+======+===============+============+========+==========+ | squirrel | squirrel | sys | allnewtriples | id | |sys| | foreign | | squirrel | squirrel | sys | allnewtriples | subject | |sys| | foreign | | squirrel | squirrel | sys | allnewtriples | predicate | |sys| | foreign | | squirrel | squirrel | sys | allnewtriples | object | |sys| | foreign | +----------+----------+------+---------------+------------+--------+----------+ 4 tuples (9.797ms) !7 columns dropped! So it seems the first LIKE expression must stay like, or some further rewriting/optimisation will kill the plan. It seems [70aff6bf7838](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=70aff6bf7838) triggers a bug that was in the code for long to be visible now. No test needed, since Test_JdbcClient fails for this reason. ## Comment 17738 Date: 2012-09-14 14:07:47 +0200 From: @grobian Niels, we would like to see this fixed ASAP, if possible, since it blocks Jul2012-SP2. ## Comment 17739 Date: 2012-09-17 09:54:04 +0200 From: @sjoerdmullender Fixed by Niels in changeset [f1c7f64f461e](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=f1c7f64f461e) ## Comment 26766 Date: 2018-12-31 07:11:19 +0100 From: martin garix &lt;<akkaran046>&gt; Sometimes facing this problem,and users asked how do i find my computer in windows 10 http://mycomputerwindows10.com here the one of the best simple perfected working ways,now using this.
Multiple string equality tests fail to match (Test_JdbcClient)
https://api.github.com/repos/MonetDB/MonetDB/issues/3150/comments
0
2020-11-30T12:13:27Z
2024-06-27T11:57:35Z
https://github.com/MonetDB/MonetDB/issues/3150
753,427,283
3,150
[ "MonetDB", "MonetDB" ]
Date: 2012-09-09 12:33:57 +0200 From: @grobian To: MonetDB5 devs &lt;<bugs-monetdb5>&gt; Version: 11.13.3 (Oct2012) CC: @yzchang Last updated: 2012-11-27 11:51:36 +0100 ## Comment 17728 Date: 2012-09-09 12:33:57 +0200 From: @grobian This is on the Oct2012 branch, but we don't have a version for it yet ever since [ae7958b81646](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=ae7958b81646) join03 test fails with: !MALException:jaql.execute:MALException:bat.delete:operation failed !ERROR: BUNdelHead: access denied to tmp_743, aborting. on ppc-macos, sparc*-solaris, and some other platforms http://monetdb.cwi.nl/testweb/web/showtestoutput.php?serial=45431:f7cf4f33c42a&target=GNU-Solaris-sparcv9-dbfarm&module=monetdb5&test=extras%2Fjaql%2Fjoin03&which=out I tried reproducing on ppc-macos (Vomac) but I failed so far. Most likely due to testing configuring with --enable-optimize. Commit [ae7958b81646](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=ae7958b81646) changed from using the jaql.{,u}select wrappers to straight algebra.{,u}select, which hints at some problem in that direction. ## Comment 17729 Date: 2012-09-10 15:05:16 +0200 From: @sjoerdmullender The problem is likely the fact that select can return a view (which it didn't do in the past), and a view is read-only. The solution is to make the bat writable before writing into it. Making it writable will materialize the view. ## Comment 17730 Date: 2012-09-10 16:35:42 +0200 From: @sjoerdmullender It's a bit worse than I thought. The bat from which values are being deleted isn't a view, but instead, there is a view that depends on it. This cannot be fixed by setting the bat writable. ## Comment 17731 Date: 2012-09-12 19:51:07 +0200 From: @grobian I prepared a patch to implement bat.setAccess(x, "w") before each and every bat.insert. It doesn't solve anything, but given comment 1, would it be necessary still? ## Comment 17732 Date: 2012-09-13 09:40:34 +0200 From: @sjoerdmullender In the trace of the test we see this snippet: _75 := bat.reverse(_72); _76 := algebra.select(_75,_66); _77 := bat.delete(_72,_66); The problem is, the select returns a view on its first argument which is the same bat as the one that the subsequent delete deletes from. This latter operation is then refused because it would invalidate the view. I can easily fix this if the input bat to the select (_75) is *not* read-only. If the bat is writable, it would be a clear signal that creating a view on it is a bad idea, so the select would return an independent bat. Then the delete can go ahead and delete entries. Would it be possible to set the bat (_72 or _75) writable *before* the call to select? Basically, you would need to set the bat writable as early as possible. Note that I still need to fix the join code (called from select) to not create a view in case of a writable bat. But that looks like a trivial fix. ## Comment 17733 Date: 2012-09-13 09:53:21 +0200 From: @sjoerdmullender It seems the input to the select was already writable. My little patch to not create a view has the desired effect already. ## Comment 17734 Date: 2012-09-13 18:04:13 +0200 From: @sjoerdmullender Changeset [9fbe7d4f2cc8](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=9fbe7d4f2cc8) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=9fbe7d4f2cc8](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=9fbe7d4f2cc8) Changeset description: When making a bat writable, also create new copy if shared and already writable. BATsetaccess creates a new copy if a bat is made writable but it there are views on it. However, it didn't do this if the mode was already the same. This is part of the fix for bug #3149. ## Comment 17735 Date: 2012-09-13 18:04:15 +0200 From: @sjoerdmullender Changeset [4e56ae4b1912](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=4e56ae4b1912) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=4e56ae4b1912](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=4e56ae4b1912) Changeset description: Big cleanup of bat5.c; more often call BATsetaccess to make a bat writable. This is the second part for the fix of bug #3149. We now also call BATsetaccess to BAT_WRITE in more of the delete functions. Among others the function that was called in the test. ## Comment 17736 Date: 2012-09-13 18:59:43 +0200 From: @grobian join03 and group02 still fail for me if I call setAccess(X, w) before each bat.insert ## Comment 17745 Date: 2012-09-19 09:57:32 +0200 From: @sjoerdmullender Changeset [e5aa7236ee2f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=e5aa7236ee2f) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=e5aa7236ee2f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=e5aa7236ee2f) Changeset description: Big cleanup of bat5.c; more often call BATsetaccess to make a bat writable. This is the second part for the fix of bug #3149. We now also call BATsetaccess to BAT_WRITE in more of the delete functions. Among others the function that was called in the test. (transplanted from 4e56ae4b1912738f3a6c3d0dc1ba6cb4e8fc0d04) ## Comment 17746 Date: 2012-09-19 09:57:35 +0200 From: @sjoerdmullender Changeset [bf08f8b0187a](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=bf08f8b0187a) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=bf08f8b0187a](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=bf08f8b0187a) Changeset description: When making a bat writable, also create new copy if shared and already writable. BATsetaccess creates a new copy if a bat is made writable but it there are views on it. However, it didn't do this if the mode was already the same. This is part of the fix for bug #3149. (transplanted from 9fbe7d4f2cc8cd40b405e5c8b4d565dd0f544826) ## Comment 18037 Date: 2012-11-27 11:51:36 +0100 From: @yzchang This bug is about the existing test: monetdb5/extras/jaql/Tests/join03.mal
join03 test fails since ae7958b81646
https://api.github.com/repos/MonetDB/MonetDB/issues/3149/comments
0
2020-11-30T12:13:25Z
2024-06-27T11:57:34Z
https://github.com/MonetDB/MonetDB/issues/3149
753,427,247
3,149
[ "MonetDB", "MonetDB" ]
Date: 2012-09-06 05:51:27 +0200 From: tracedb &lt;<trace.monetdb>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.11.5 (Jul2012) Last updated: 2012-09-06 08:48:28 +0200 ## Comment 17724 Date: 2012-09-06 05:51:27 +0200 From: tracedb &lt;<trace.monetdb>&gt; User-Agent: Mozilla/5.0 (X11; Linux i686) AppleWebKit/535.19 (KHTML, like Gecko) Ubuntu/11.04 Chromium/18.0.1025.151 Chrome/18.0.1025.151 Safari/535.19 Build Identifier: I create a table "test" with columns (id int, data tinyint). When I insert a record like (1,-128), the sql front end report an error with message "22003!overflow in calculation.". But the range of tinyint is [-128,127], the same situation appears in types smallint and int. Reproducible: Always ### Steps to Reproduce: 1.create table test ( id int, data tinyint ); 2.insert into test values (1,-128); 3.insert into test values (-2147483648,1); ### Actual Results: 22003!overflow in calculation. MonetDB 5 server v11.11.5 "Jul2012" (32-bit, 32-bit oids) Copyright (c) 1993-July 2008 CWI Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved Visit http://www.monetdb.org/ for further information Found 3.0GiB available memory, 2 available cpu cores Libraries: libpcre: 8.12 2011-01-15 (compiled with 8.12) openssl: OpenSSL 0.9.8o 01 Jun 2010 (compiled with OpenSSL 0.9.8o 01 Jun 2010) libxml2: 2.7.8 (compiled with 2.7.8) Compiled by: user@ubuntu (i686-pc-linux-gnu) Compilation: gcc -g -O2 Linking : /usr/bin/ld ## Comment 17725 Date: 2012-09-06 08:27:51 +0200 From: @grobian In MonetDB, the ranges of the integer types are -127,127, e.g. the max positive value down to that value negated. The reason for this is that the maximum negative value is reserved for the NULL representation, which is deeply embedded into the kernel, and won't be changed. ## Comment 17726 Date: 2012-09-06 08:38:42 +0200 From: tracedb &lt;<trace.monetdb>&gt; OK, thanks. BTW, did MonetDB not support integer types with UNSIGNED? (In reply to comment 1) > In MonetDB, the ranges of the integer types are -127,127, e.g. the max positive > value down to that value negated. > > The reason for this is that the maximum negative value is reserved for the NULL > representation, which is deeply embedded into the kernel, and won't be changed. ## Comment 17727 Date: 2012-09-06 08:48:28 +0200 From: @grobian no, it only does signed types
SQL Builtin types such as tinyint, smallint can't deal with edge-case values.
https://api.github.com/repos/MonetDB/MonetDB/issues/3148/comments
0
2020-11-30T12:13:22Z
2024-06-28T13:17:26Z
https://github.com/MonetDB/MonetDB/issues/3148
753,427,194
3,148
[ "MonetDB", "MonetDB" ]
Date: 2012-09-05 16:17:19 +0200 From: Alvaro Basto &lt;<alvarobastolima>&gt; To: clients devs &lt;<bugs-clients>&gt; Version: -- development CC: alvarobastolima, @hannesmuehleisen, martin.van.dinther, y.kargin Duplicates: #2430 Last updated: 2017-09-28 17:39:53 +0200 ## Comment 17720 Date: 2012-09-05 16:17:19 +0200 From: Alvaro Basto &lt;<alvarobastolima>&gt; User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.1 (KHTML, like Gecko) Chrome/21.0.1180.83 Safari/537.1 Build Identifier: When attempting to use the reporting tool "pentaho report designer", I get the following error Feedback: "java.sql.SQLFeatureNotSupportedException: Operation getCharacterStream() currently not supported at nl.cwi.monetdb.jdbc.MonetClob.getCharacterStream(MonetClob.java:80)" and java.sql.SQLFeatureNotSupportedException: Operation setObject() with object of type Class currently not supported! at nl.cwi.monetdb.jdbc.MonetPreparedStatement.setObject(MonetPreparedStatement.java:1901). Reproducible: Always ### Steps to Reproduce: 1. create a connection to the monetdb, in pentaho reporting. 2. create a datasource create a datasource with the following query "parameter passing" select * from dim_time where data = ${data} ### Actual Results: org.pentaho.reporting.engine.classic.core.ReportDataFactoryException: Failed at query: select * from dim_time where data = ${data} at org.pentaho.reporting.engine.classic.core.modules.misc.datafactory.sql.SimpleSQLReportDataFactory.queryData(SimpleSQLReportDataFactory.java:254) at org.pentaho.reporting.engine.classic.core.modules.misc.datafactory.sql.SQLReportDataFactory.queryData(SQLReportDataFactory.java:95) at org.pentaho.reporting.ui.datasources.jdbc.ui.JdbcPreviewWorker.run(JdbcPreviewWorker.java:103) at java.lang.Thread.run(Unknown Source) ParentException: java.sql.SQLException: SELECT: no such table 'dim_time' at nl.cwi.monetdb.jdbc.MonetConnection$ResponseList.executeQuery(MonetConnection.java:2519) at nl.cwi.monetdb.jdbc.MonetConnection$ResponseList.processQuery(MonetConnection.java:2269) at nl.cwi.monetdb.jdbc.MonetStatement.internalExecute(MonetStatement.java:508) at nl.cwi.monetdb.jdbc.MonetStatement.execute(MonetStatement.java:349) at nl.cwi.monetdb.jdbc.MonetPreparedStatement.<init>(MonetPreparedStatement.java:118) at nl.cwi.monetdb.jdbc.MonetConnection.prepareStatement(MonetConnection.java:891) at nl.cwi.monetdb.jdbc.MonetConnection.prepareStatement(MonetConnection.java:849) at org.pentaho.reporting.engine.classic.core.modules.misc.datafactory.sql.SimpleSQLReportDataFactory.parametrizeAndQuery(SimpleSQLReportDataFactory.java:355) at org.pentaho.reporting.engine.classic.core.modules.misc.datafactory.sql.SimpleSQLReportDataFactory.queryData(SimpleSQLReportDataFactory.java:250) at org.pentaho.reporting.engine.classic.core.modules.misc.datafactory.sql.SQLReportDataFactory.queryData(SQLReportDataFactory.java:95) at org.pentaho.reporting.ui.datasources.jdbc.ui.JdbcPreviewWorker.run(JdbcPreviewWorker.java:103) at java.lang.Thread.run(Unknown Source) ### Expected Results: returned a preview screen. functions: MonetClob.getCharacterStream() and MonetPreparedStatement.setObject() are not implemented. ## Comment 17721 Date: 2012-09-05 16:54:15 +0200 From: @grobian (In reply to comment 0) > functions: MonetClob.getCharacterStream() and > MonetPreparedStatement.setObject() are not implemented. Method MonetPreparedStatement.setObject() is implemented, but it doesn't support Class-types. ## Comment 17722 Date: 2012-09-05 18:40:05 +0200 From: Alvaro Basto &lt;<alvarobastolima>&gt; The MonetClob.getCharacterStream () was implemented? ## Comment 17723 Date: 2012-09-05 18:41:48 +0200 From: @grobian no, like any other "stream" methods. ## Comment 18148 Date: 2012-11-27 16:27:21 +0100 From: Yagiz &lt;<y.kargin>&gt; At the moment MonetDB does not support sending streams. ## Comment 18151 Date: 2012-11-27 16:36:33 +0100 From: @grobian *** This bug has been marked as a duplicate of bug #2430 *** ## Comment 25675 Date: 2017-09-28 17:39:53 +0200 From: Martin van Dinther &lt;<martin.van.dinther>&gt; MonetClob.getCharacterStream() and MonetPreparedStatement.setObject() for clob column are now implemented, see also https://www.monetdb.org/bugzilla/show_bug.cgi?id=6349 and https://dev.monetdb.org/hg/monetdb-java/rev/1e49fc74dba4
getCharacterStream not implemented in JDBC
https://api.github.com/repos/MonetDB/MonetDB/issues/3147/comments
0
2020-11-30T12:13:19Z
2024-06-28T13:40:53Z
https://github.com/MonetDB/MonetDB/issues/3147
753,427,161
3,147
[ "MonetDB", "MonetDB" ]
Date: 2012-08-29 20:36:05 +0200 From: Vasco &lt;<vasco.visser>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.11.7 (Jul2012-SP1) Last updated: 2012-11-07 19:18:04 +0100 ## Comment 17707 Date: 2012-08-29 20:36:05 +0200 From: Vasco &lt;<vasco.visser>&gt; User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:14.0) Gecko/20100101 Firefox/14.0.1 Build Identifier: A have a multiple SQL files each containing a create table statement and copy into statement. Each SQL file is fed to a different mclient, thus each mclient only writes to one table. When I try to import the tables simultaneously (fork each mclient to the background) I encounter the following error: "COMMIT: transaction is aborted because of concurency conflicts, will ROLLBACK instead" The log files don't seem to contain anything interesting, although the content of the sql log file is a bit cryptic and might have some meaning to the developers: sql.log: 052001 8 Reproducible: Always ### Steps to Reproduce: 1. Import tables simultaneously using different mclients 2. Wait a while ### Actual Results: The table that was imported by the client that printed the exception is not imported. ### Expected Results: Import the tables simultaneously without concurrency conflicts $ mserver5 --version MonetDB 5 server v11.11.7 "Jul2012-SP1" (64-bit, 64-bit oids) Copyright (c) 1993-July 2008 CWI Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved Visit http://www.monetdb.org/ for further information Found 251.9GiB available memory, 32 available cpu cores Libraries: libpcre: 8.12 2011-01-15 (compiled with 8.12) openssl: OpenSSL 1.0.0i 19 Apr 2012 (compiled with OpenSSL 1.0.0i-fips 19 Apr 2012) libxml2: 2.7.8 (compiled with 2.7.8) Compiled by: vvisser (x86_64-unknown-linux-gnu) Compilation: gcc -g -O2 Linking : /usr/bin/ld -m elf_x86_64 ## Comment 17709 Date: 2012-08-31 10:29:28 +0200 From: @sjoerdmullender First, the log you refer to is the write-ahead log and is an essential part of the database. It is not for human consumption. It looks like you're bitten by the fact that MonetDB uses optimistic concurrency control. The first client doing the commit succeeds, all others fail. That is absolutely to be expected. Of course, the concurrency control works at a certain granularity. Multiple transactions to unrelated tables can work in principle, but I'm not sure what granularity MonetDB uses. However, multiple DDL queries affect shared resources and are certainly subject to concurrency control. I'm strongly tempted to declare this as "not a bug". ## Comment 17757 Date: 2012-09-25 20:20:28 +0200 From: @grobian reassign to correct category ## Comment 17899 Date: 2012-11-07 19:18:04 +0100 From: @grobian (In reply to comment 1) > I'm strongly tempted to declare this as "not a bug". +1
Importing multiple tables simultaneously gives concurrency conflict
https://api.github.com/repos/MonetDB/MonetDB/issues/3146/comments
0
2020-11-30T12:13:16Z
2024-06-28T13:17:25Z
https://github.com/MonetDB/MonetDB/issues/3146
753,427,126
3,146
[ "MonetDB", "MonetDB" ]
Date: 2012-08-23 17:32:35 +0200 From: Christian Braun &lt;<hcb>&gt; To: clients devs &lt;<bugs-clients>&gt; Version: 11.11.7 (Jul2012-SP1) Last updated: 2012-09-21 11:51:25 +0200 ## Comment 17649 Date: 2012-08-23 17:32:35 +0200 From: Christian Braun &lt;<hcb>&gt; User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:14.0) Gecko/20100101 Firefox/14.0.1 Build Identifier: Welcome to mclient, the MonetDB/SQL interactive terminal (Jul2012-SP1) Database: MonetDB v11.11.7 (Jul2012-SP1), 'mapi:monetdb://makalu:50000/db' Type \q to quit, \? for a list of available commands auto commit mode: on sql>select 1; +--------------+ | single_value | +==============+ | 1 | +--------------+ 1 tuple (0.468ms) sql>set history=true; operation successful (0.482ms) sql>select 1; invalid/unknown response from server, ignoring output ? = 0:0 profiler.setFootprintFlag(); ? = 0:0 profiler.setMemoryFlag(); ? = 0:0 inblock := profiler.getDiskReads(); ? = 0:0 oublock := profiler.getDiskWrites(); ? = 0:0 xtime := alarm.usec(); (remaining output omitted, use \fraw to examine in detail) sql>\fraw sql>select 1; 0:0 profiler.setFootprintFlag(); 0:0 profiler.setMemoryFlag(); 0:0 inblock := profiler.getDiskReads(); 0:0 oublock := profiler.getDiskWrites(); 0:0 xtime := alarm.usec(); 0:0 X_43 := alarm.usec(); 0:0 xtime := calc.-(X_43=17795913294:lng,xtime=2:lng); 0:0 rtime := alarm.usec(); % . table_name % single_value name % tinyint type % 1 length [ 1 ] 0:0 sql.exportValue(1,".","single_value","tinyint",8,0,6,A0=1:bte,""); 0:0 X_47 := alarm.usec(); 0:0 rtime := calc.-(X_47=17795913322:lng,rtime=16:lng); foot := profiler.getFootprint(); sql> Reproducible: Always ## Comment 17701 Date: 2012-08-24 16:09:19 +0200 From: @sjoerdmullender Changeset [0901d759538f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=0901d759538f) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=0901d759538f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=0901d759538f) Changeset description: Only print runtimeTiming information when in the (mdb) debugger. This fixes bugs 3117 and 3145. ## Comment 17703 Date: 2012-08-24 16:12:02 +0200 From: @sjoerdmullender This is essentially the same as bug #3117. The extra output was timing information for each MAL statement being executed, but it's only really useful for debugging purposes, so I've disabled the output.
mclient error when enabling history
https://api.github.com/repos/MonetDB/MonetDB/issues/3145/comments
0
2020-11-30T12:13:14Z
2024-06-27T11:57:30Z
https://github.com/MonetDB/MonetDB/issues/3145
753,427,092
3,145
[ "MonetDB", "MonetDB" ]
Date: 2012-08-21 15:37:35 +0200 From: info To: MonetDB5 devs &lt;<bugs-monetdb5>&gt; Version: -- development CC: arkr17997, hotekabop, @yzchang Last updated: 2019-10-31 13:35:49 +0100 ## Comment 17634 Date: 2012-08-21 15:37:35 +0200 From: info Created attachment 140 Valgrind logging monetdb --version MonetDB Database Server Toolkit v1.0 (Jul2012-SP1) There seems to be a memory leak when making a connection. The amount of bytes leaked increase with each connection. We have tested this with both mclient and mapi(C-code). Mclient shows an additional leak compared to connecting with mapi. The first connection made to a database also seems to have some extra leakage. I've added an archive with valgrind logging. MAPI: For mapi we used the following C-program: Mapi dbh = NULL; dbh = mapi_connect("localhost", 50000, "monetdb", "monetdb", "sql", "connectionmapi"); mapi_destroy(dbh); Test: No connection Terminal1: valgrind --leak-check=full mserver5 --set gdk_alloc_map=no --dbname=connectionmapi >& output_mserver5_mapi.txt Terminal1: \q ==26903== definitely lost: 216 bytes in 3 blocks Test: 1st connection Terminal1: valgrind --leak-check=full mserver5 --set gdk_alloc_map=no --dbname=connectionmapi >& output_mserver5_mapi_1st.txt Terminal2: ./Program Terminal1: \q ==26955== definitely lost: 237,648 bytes in 116 blocks Test: 2nd connection Terminal1: valgrind --leak-check=full mserver5 --set gdk_alloc_map=no --dbname=connectionmapi >& output_mserver5_mapi_2nd.txt Terminal2: ./Program Terminal1: \q ==27001== definitely lost: 40 bytes in 1 blocks Test: 3rd connection Terminal1: valgrind --leak-check=full mserver5 --set gdk_alloc_map=no --dbname=connectionmapi >& output_mserver5_mapi_3rd.txt Terminal2: ./Program Terminal1: \q ==27034== definitely lost: 40 bytes in 1 blocks Test: 4th + 5th connection Terminal1: valgrind --leak-check=full mserver5 --set gdk_alloc_map=no --dbname=connectionmapi >& output_mserver5_mapi_4th_5th.txt Terminal2: ./Program Terminal2: ./Program Terminal1: \q ==27071== definitely lost: 80 bytes in 2 blocks MCLIENT: Test: No connection Terminal1: valgrind --leak-check=full mserver5 --set gdk_alloc_map=no --dbname=connectionmclient >& output_mserver5_mclient.txt Terminal1: \q ==26105== definitely lost: 216 bytes in 3 blocks Test: 1st connection Terminal1: valgrind --leak-check=full mserver5 --set gdk_alloc_map=no --dbname=connectionmclient >& output_mserver5_mclient_1st.txt Terminal2: mclient -dconnectionmclient Terminal2: \q Terminal1: \q ==26147== definitely lost: 238,824 bytes in 117 blocks Test: 2nd connection Terminal1: valgrind --leak-check=full mserver5 --set gdk_alloc_map=no --dbname=connectionmclient >& output_mserver5_mclient_2nd.txt Terminal2: mclient -dconnectionmclient Terminal2: \q Terminal1: \q ==26229== definitely lost: 1,216 bytes in 2 blocks Test: 3rd connection Terminal1: valgrind --leak-check=full mserver5 --set gdk_alloc_map=no --dbname=connectionmclient >& output_mserver5_mclient_3rd.txt Terminal2: mclient -dconnectionmclient Terminal2: \q Terminal1: \q ==26293== definitely lost: 1,216 bytes in 2 blocks Test: 4th + 5th connection Terminal1: valgrind --leak-check=full mserver5 --set gdk_alloc_map=no --dbname=connectionmclient >& output_mserver5_mclient_4th_5th.txt Terminal2: mclient -dconnectionmclient Terminal2: \q Terminal2: mclient -dconnectionmclient Terminal2: \q Terminal1: \q ==26415== definitely lost: 2,432 bytes in 4 blocks > Attached file: [connection_leak.tar.bz2](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3144_connection_leak.tar.bz2_140) (application/x-bzip, 254089 bytes) > Description: Valgrind logging ## Comment 17650 Date: 2012-08-24 12:33:32 +0200 From: @sjoerdmullender Changeset [1a1256bc8d44](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=1a1256bc8d44) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=1a1256bc8d44](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=1a1256bc8d44) Changeset description: Fix memory leak. The lifespan info wasn't used in the groups optimizer, and what's worse, it wasn't freed. This fixes (part of) bug #3144. ## Comment 17651 Date: 2012-08-24 13:56:19 +0200 From: @sjoerdmullender Changeset [1db88d19e874](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=1db88d19e874) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=1db88d19e874](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=1db88d19e874) Changeset description: Plug memory leak. Part of fixing bug #3144. ## Comment 17652 Date: 2012-08-24 14:37:11 +0200 From: @sjoerdmullender Changeset [293d29d8bec2](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=293d29d8bec2) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=293d29d8bec2](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=293d29d8bec2) Changeset description: Plug some more memory leaks. Fixes for bug #3144. ## Comment 17653 Date: 2012-08-24 14:48:08 +0200 From: @sjoerdmullender With the three sets of fixes I now get 0 definitely lost bytes of memory when I replay the mclient tests. This'll be in Jul2012-SP2. ## Comment 18049 Date: 2012-11-27 13:19:34 +0100 From: @yzchang Don't know how to add test for this bug
Memleak when connecting to a database (mclient and mapi)
https://api.github.com/repos/MonetDB/MonetDB/issues/3144/comments
0
2020-11-30T12:13:11Z
2024-06-27T11:57:29Z
https://github.com/MonetDB/MonetDB/issues/3144
753,427,069
3,144
[ "MonetDB", "MonetDB" ]
Date: 2012-08-21 13:32:14 +0200 From: @mlkersten To: SQL devs &lt;<bugs-sql>&gt; Version: 11.11.7 (Jul2012-SP1) CC: @romulogoncalves, @njnes Last updated: 2013-01-22 09:29:17 +0100 ## Comment 17633 Date: 2012-08-21 13:32:14 +0200 From: @mlkersten User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:13.0) Gecko/20100101 Firefox/13.0.1 Build Identifier: Based on the Datacell/Tests/emili.sql script This procedure ends up in the function table; CREATE PROCEDURE datacell.enrich() BEGIN INSERT INTO datacell.sensors(ip, location, kind,value) SELECT ip, substring(location,0,3), kind, value FROM datacell.istream; IF TRUE THEN INSERT INTO datacell.area SELECT ip, substring(location,0,3) FROM datacell.istream; END IF; END; This one does *not*, see IF-expression, and does not produce an error message. CREATE PROCEDURE datacell.enrich() BEGIN INSERT INTO datacell.sensors(ip, location, kind,value) SELECT ip, substring(location,0,3), kind, value FROM datacell.istream; IF (SELECT count(*) FROM datacell.area ) = 0 THEN INSERT INTO datacell.area SELECT ip, substring(location,0,3) FROM datacell.istream; END IF; END; En this one works again: CREATE PROCEDURE datacell.enrich() BEGIN DECLARE cnt INTEGER; SET cnt = (SELECT count(*) FROM datacell.area ) ; INSERT INTO datacell.sensors(ip, location, kind,value) SELECT ip, substring(location,0,3), kind, value FROM datacell.istream; IF cnt = 0 THEN INSERT INTO datacell.area SELECT ip, substring(location,0,3) FROM datacell.istream; END IF; END; Reproducible: Always ## Comment 17688 Date: 2012-08-24 14:56:03 +0200 From: @sjoerdmullender Jul2012-SP1 has been released. ## Comment 18117 Date: 2012-11-27 15:25:21 +0100 From: @romulogoncalves Test for this bug added to the SQL module under the directory BugTracker_2012. The test is called: type_resolution_error_in_SQL_procedural_code.Buf-3143 The stable out was added, however, the stable err is dependent of the ERROR message used to report that the procedure creation failed. For the moment a temporary message was added to trigger its fail when Mtest is run. ## Comment 18213 Date: 2012-11-28 16:23:36 +0100 From: @njnes Changeset [1ee4a27c1126](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=1ee4a27c1126) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=1ee4a27c1126](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=1ee4a27c1126) Changeset description: fixed bugs 2977 and 3143 return errors in psm when we don't expect select statements (solves 3143) Give proper error when a function isn't found and don't allow converts from date into second intervals. (solves 2977) ## Comment 18381 Date: 2013-01-22 09:29:17 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
Type resolution error in SQL procedural code
https://api.github.com/repos/MonetDB/MonetDB/issues/3143/comments
0
2020-11-30T12:13:07Z
2024-06-27T11:57:28Z
https://github.com/MonetDB/MonetDB/issues/3143
753,427,007
3,143
[ "MonetDB", "MonetDB" ]
Date: 2012-08-21 11:48:14 +0200 From: info To: Merovingian devs &lt;<bugs-merovingian>&gt; Version: 11.11.7 (Jul2012-SP1) Last updated: 2012-08-31 14:56:10 +0200 ## Comment 17632 Date: 2012-08-21 11:48:14 +0200 From: info User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/535.1 (KHTML, like Gecko) Chrome/13.0.782.107 Safari/535.1 Build Identifier: When using "monetdb shared" or creating a new databases (and possibly other commands that influence the discovery list) a memleak occurs in monetdbd that increases with each executed command. Reproducible: Always ### Steps to Reproduce: valgrind --leak-check=full monetdbd start /monetdb/dbfarm for (( i=1; i<=10; i++ )) do monetdb set shared=1/2/6 test1 sleep 1 monetdb set shared=1/2/7 test1 sleep 1 echo $i done monetdbd stop /monetdb/dbfarm ### Actual Results: ==12448== HEAP SUMMARY: ==12448== in use at exit: 5,034 bytes in 83 blocks ==12448== total heap usage: 1,498 allocs, 1,416 frees, 1,815,403 bytes allocated ==12448== ==12448== 970 bytes in 51 blocks are definitely lost in loss record 14 of 14 ==12448== at 0x4C274A8: malloc (vg_replace_malloc.c:236) ==12448== by 0x54EEFD1: strdup (strdup.c:43) ==12448== by 0x7856449: ??? ==12448== by 0x556D827: gethostbyaddr_r@@GLIBC_2.2.5 (getXXbyYY_r.c:253) ==12448== by 0x5573E1A: getnameinfo (getnameinfo.c:223) ==12448== by 0x40D56D: discoveryRunner (in /data/programs/MonetDB/bin/monetdbd) ==12448== by 0x52559C9: start_thread (pthread_create.c:300) ==12448== by 0x8A596FF: ??? ==12448== ==12448== LEAK SUMMARY: ==12448== definitely lost: 970 bytes in 51 blocks ==12448== indirectly lost: 0 bytes in 0 blocks ==12448== possibly lost: 0 bytes in 0 blocks ==12448== still reachable: 4,064 bytes in 32 blocks ==12448== suppressed: 0 bytes in 0 blocks ==12448== Reachable blocks (those to which a pointer was found) are not shown. ==12448== To see them, rerun with: --leak-check=full --show-reachable=yes ### Expected Results: Expected that no bytes would be definitely lost. monetdb --version MonetDB Database Server Toolkit v1.0 (Jul2012-SP1) ## Comment 17669 Date: 2012-08-24 14:55:09 +0200 From: @sjoerdmullender Jul2012-SP1 has been released. ## Comment 17698 Date: 2012-08-24 15:02:40 +0200 From: @sjoerdmullender This looks like a leak inside the C library. The function getnameinfo is part of the C library, and the documentation doesn't say anything about having to free any memory that it allocates. In fact, no pointer is returned by the function which one could free. ## Comment 17708 Date: 2012-08-30 20:05:48 +0200 From: @grobian does the resident set size of monetdbd grow? Like Sjoerd says, we cannot leak from getnameinfo, since we give it buffers + lengths, like the documentation requires us ## Comment 17714 Date: 2012-08-31 14:12:42 +0200 From: @grobian I changed the script slightly to run ps -o vsz,rss -p `cat path/to/merovingian.pid` in each iteration of the loop. The RSS and virtually claimed memory remained rockstable during all iterations of the loop. !/usr/bin/env bash monetdb create test1 monetdb release test1 for (( i=1; i<=10; i++ )) do monetdb set shared=1/2/6 test1 sleep 1 monetdb set shared=1/2/7 test1 sleep 1 echo $i ps -o vsz,rss -p `cat $DBFARM/merovingian.pid` | sed '1d' done monetdb stop test1 monetdb destroy -f test1 ## Comment 17718 Date: 2012-08-31 14:56:10 +0200 From: info I didn't check the resident set size of monetdbd on this test, just the Valgrind output. It might be that Valgrind doesn't detect it right. Also when searching for getnameinfo online, there seem to be multiple versions of the fuction where some use gethostbyaddr_r and some use gethostbyaddr. Maybe we are using a different version of the function.
Memleak when monetdbd updates it's discoverlist with discoveryRunner function
https://api.github.com/repos/MonetDB/MonetDB/issues/3142/comments
0
2020-11-30T12:13:05Z
2024-06-28T13:17:24Z
https://github.com/MonetDB/MonetDB/issues/3142
753,426,975
3,142
[ "MonetDB", "MonetDB" ]
Date: 2012-08-17 17:01:28 +0200 From: info To: buildtools devs &lt;<bugs-buildtools>&gt; Version: 11.11.7 (Jul2012-SP1) Last updated: 2012-08-24 15:04:06 +0200 ## Comment 17628 Date: 2012-08-17 17:01:28 +0200 From: info User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:14.0) Gecko/20100101 Firefox/14.0.1 Build Identifier: MonetDB version 11.11.7 (from the testing branch (jul2012-sp1)) OS: Ubuntu 12.04 64bit server edition libssl1.0.0 mserver5 gets terminated during startup (see attached merovingian log) when configured as followed: ./configure --prefix=/data/programs/MonetDB --enable-debug=no --enable-geom=no --enable-testing=no --enable-developer=no --enable-assert=no --enable-optimize=yes mserver5 has no problems starting when using: ./configure --prefix=/data/programs/MonetDB --enable-debug=no --enable-geom=no Reproducible: Always ### Steps to Reproduce: 1. build with ./configure --prefix=/data/programs/MonetDB --enable-debug=no --enable-geom=no --enable-testing=no --enable-developer=no --enable-assert=no --enable-optimize=yes 2. create a database, release the database, start the database 3. ### Actual Results: mserver5 terminates on startup, errors are shown in merovingian.log it seems a wrong library libssl0.9.8 is linked instead of libssl1.0.0. also --enable-geom=no seems to be ignored. ____ 2012-08-16 12:17:34 MSG DB11[17810]: MonetDB 5 server v11.11.7 "Jul2012-SP1" 2012-08-16 12:17:34 MSG DB11[17810]: Serving database 'DB11', using 16 threads 2012-08-16 12:17:34 MSG DB11[17810]: Compiled for x86_64-unknown-linux-gnu/64bit with 64bit OIDs dynamically linked 2012-08-16 12:17:34 MSG DB11[17810]: Found 94.409 GiB available main-memory. 2012-08-16 12:17:34 MSG DB11[17810]: Copyright (c) 1993-July 2008 CWI. 2012-08-16 12:17:34 MSG DB11[17810]: Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved 2012-08-16 12:17:34 MSG DB11[17810]: Visit http://www.monetdb.org/ for further information 2012-08-16 12:17:34 MSG DB11[17810]: WARNING: LoaderException:loadLibrary:failed to load library: libssl.so.0.9.8: cannot open shared object file: No such file or directory 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command tostr() :str address mbrTOSTR; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command fromstr() :mbr address mbrFROMSTR; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command hash() :int address mbrHASH; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command null() :int address mbrNULL; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command cmp() :int address mbrCOMP; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command read() address mbrREAD; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command write() address mbrWRITE; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command mbr(v:str) :mbr address mbrFromString; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command tostr() :str address wkbTOSTR; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command fromstr() :wkb address wkbFROMSTR; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command hash() :int address wkbHASH; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command null() :int address wkbNULL; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command cmp() :int address wkbCOMP; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command read() address wkbREAD; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command write() address wkbWRITE; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command put() :int address wkbPUT; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command del() :int address wkbDEL; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command length() :int address wkbLENGTH; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command heap() :int address wkbHEAP; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command wkb{unsafe}(v:str) :wkb address wkbFromString; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError:command FromText{unsafe}(w:str, type:int) :wkb address wkbFromText; 2012-08-16 12:17:34 MSG DB11[17810]: !SyntaxException:parseError: ^<address> not found 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.PointFromText[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.PointFromText[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _4:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.CurveFromText[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.CurveFromText[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _4:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.LineFromText[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.LineFromText[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _4:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.SurfaceFromText[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.SurfaceFromText[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _4:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.PolyFromText[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.PolyFromText[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _4:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.MultiPointFromText[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.MultiPointFromText[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _4:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.MultiCurveFromText[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.MultiCurveFromText[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _4:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.MultiLineFromText[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.MultiLineFromText[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _4:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.MultiSurfaceFromText[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.MultiSurfaceFromText[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _4:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.MultiPolyFromText[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.MultiPolyFromText[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _4:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.GeomFromText[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.GeomFromText[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _4:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.GeomCollectionFromText[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:geom.GeomCollectionFromText[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _4:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.point[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.point[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _3:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.curve[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.curve[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _3:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.linestring[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.linestring[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _3:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.surface[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.surface[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _3:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.polygon[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.polygon[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _3:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.multipoint[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.multipoint[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _3:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.multicurve[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.multicurve[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _3:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.multilinestring[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.multilinestring[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _3:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.multisurface[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.multisurface[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _3:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.multipolygon[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.multipolygon[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _3:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.geometry[1]:object code for command wkb.FromText missing 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.geometry[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _3:int) 2012-08-16 12:17:34 MSG DB11[17810]: !TypeException:calc.geometrycollection[1]:object code for command wkb.FromText missing2012-08-16 12:17:35 MSG DB11[17810]: 2012-08-16 12:17:35 MSG DB11[17810]: !TypeException:calc.geometrycollection[1]:'wkb.FromText' undefined in: x:wkb := wkb.FromText(wkt:str, _3:int) 2012-08-16 12:17:35 MSG DB11[17810]: !TypeException:user.main[2837]:object code for command geom.prelude missing 2012-08-16 12:17:35 MSG DB11[17810]: !TypeException:user.main[2837]:'geom.prelude' undefined in: _2837:void := geom.prelude() 2012-08-16 12:17:35 MSG merovingian[17759]: database 'DB11' (17810) has exited with exit status 0 2012-08-16 12:17:35 MSG merovingian[17759]: database 'DB11' has shut down 2012-08-16 12:17:35 ERR merovingian[17759]: client error: database 'DB11' started up, but failed to open up a communication channel 2012-08-16 12:17:35 MSG merovingian[17759]: starting database 'DB11', up min/avg/max: 0s/0s/0s, crash average: 0.00 0.00 0.00 (1-1=0) 2012-08-16 12:17:35 MSG merovingian[17759]: sending process 17812 (database 'DB11') the TERM signal ____ ## Comment 17629 Date: 2012-08-17 21:25:48 +0200 From: @sjoerdmullender It looks like you have leftovers from an earlier install in which the geom module was enabled. Check in your installation directory, in particular in the directories lib/monetdb5/autoload and lib/monetdb5 (or perhaps lib64/*) whether you have any files there that include the string "geom". My guess is that you do. ## Comment 17631 Date: 2012-08-21 10:03:44 +0200 From: info I use a script to build monetdb which cleans up before building, and creates a debian package for installation on other machines. There the packages are uninstalled before installing a *newer* version. Also I haven't build the geom module for a while (I always use --enable-geom=no) since we don't need it. Anyway, the problem DOES seem to have vanished today. However I don't recall doing anything different. I just wish I knew what went wrong before. :| Thanks for the help though. ;) ## Comment 17659 Date: 2012-08-24 14:53:32 +0200 From: @sjoerdmullender Jul2012-SP1 has been released. ## Comment 17699 Date: 2012-08-24 15:04:06 +0200 From: @sjoerdmullender Looks like this was some glitch. Let's ignore the report.
mserver5 gets terminated after changing configuration parameters for building monetdb
https://api.github.com/repos/MonetDB/MonetDB/issues/3141/comments
0
2020-11-30T12:13:01Z
2024-06-28T13:18:33Z
https://github.com/MonetDB/MonetDB/issues/3141
753,426,946
3,141
[ "MonetDB", "MonetDB" ]
Date: 2012-08-07 11:18:32 +0200 From: risc &lt;<risc>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.11.7 (Jul2012-SP1) CC: risc, y.kargin Last updated: 2012-11-27 14:30:03 +0100 ## Comment 17618 Date: 2012-08-07 11:18:32 +0200 From: risc &lt;<risc>&gt; User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:14.0) Gecko/20100101 Firefox/14.0.1 Build Identifier: I have a table with 20 columns, 400 millon rows. I repeatedly added and droped some additional columns, changing in data type: One column is request_date (Timestamp), which is slow in where clauses. So i want to use derived columns: ALTER TABLE stats ADD request_day int NULL; ALTER TABLE stats ADD request_hour tinyint NULL; ALTER TABLE stats ADD request_minute tinyint NULL; ALTER TABLE stats ADD request_tenminutes tinyint NULL; ALTER TABLE stats DROP request_day ; ALTER TABLE stats DROP request_hour ; ALTER TABLE stats DROP request_minute ; ALTER TABLE stats DROP request_tenminutes ; ALTER TABLE stats ADD request_day int NULL; ALTER TABLE stats ADD request_day int NULL; ALTER TABLE stats ADD request_hour smallint NULL default NULL; ALTER TABLE stats ADD request_minute smallint NULL default NULL; ALTER TABLE stats ADD request_tenminutes smallint NULL default NULL; update stats set request_day = replace(left(stats.request_date,10),'-',''), request_hour = extract(hour from request_date) , request_minute= extract(minute from request_date), request_tenminutes= substring(stats.request_date,15,1) In this state, using the table produced reasonable results and processing time. After some parallel queries, my database crashed. After restart, i was no more able to use column only able to select columns that were These statements are executed OK: select request_hour from stats where id=1 select request_minute from stats where id=1 select request_tenminutes from stats where id=1 BUT this one immediatly crashes the database, reproducible: select request_day from stats where id=1; also crashing: alter table stats drop request_day; root@avlsdb01:~ monetdb status avs_reporting name state uptime health avs_reporting crashed 32%, 4h crash 2012-08-07 11:03:29 root@avlsdb01:~ monetdb start avs_reporting starting database 'avs_reporting'... done Besides, i was repeatedly adding same column "request_day" before - maybe this is causing trouble. But i was (as it seems) able to drop both columns and add it again. By the way, stetoscope was not reporting any activity when executing one of the crashing statement. Reproducible: Always ### Steps to Reproduce: Start database select request_day from stats where id=1 database crashes ## Comment 17619 Date: 2012-08-07 14:40:32 +0200 From: risc &lt;<risc>&gt; new behavior, after reboot logfile reads: 2012-08-07 12:25:35 MSG avs_reporting[13634]: MonetDB 5 server v11.11.5 "Jul2012" 2012-08-07 12:25:35 MSG avs_reporting[13634]: Serving database 'avs_reporting', using 16 threads 2012-08-07 12:25:35 MSG avs_reporting[13634]: Compiled for x86_64-pc-linux-gnu/64bit with 64bit OIDs dynamically linked 2012-08-07 12:25:35 MSG avs_reporting[13634]: Found 31.471 GiB available main-memory. 2012-08-07 12:25:35 MSG avs_reporting[13634]: Copyright (c) 1993-July 2008 CWI. 2012-08-07 12:25:35 MSG avs_reporting[13634]: Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved 2012-08-07 12:25:35 MSG avs_reporting[13634]: Visit http://www.monetdb.org/ for further information 2012-08-07 12:25:35 MSG avs_reporting[13634]: Listening for UNIX domain connection requests on mapi:monetdb:///logdata/monetdb/avsfarm/avs_reporting/.mapi.sock 2012-08-07 12:25:35 MSG avs_reporting[13634]: MonetDB/SQL module loaded 2012-08-07 12:25:35 MSG control[4664]: (local): started 'avs_reporting' 2012-08-07 13:59:19 MSG merovingian[4664]: database 'avs_reporting' (13634) has exited with exit status 0 2012-08-07 13:59:19 MSG merovingian[4664]: caught SIGTERM, starting shutdown sequence 2012-08-07 13:59:21 MSG control[4664]: control channel closed 2012-08-07 13:59:22 MSG merovingian[4664]: Merovingian 1.6 stopped 2012-08-07 14:01:31 MSG merovingian[1054]: Merovingian 1.6 (Jul2012) starting 2012-08-07 14:01:31 MSG merovingian[1054]: monitoring dbfarm /logdata/monetdb/avsfarm 2012-08-07 14:01:36 MSG merovingian[1054]: accepting connections on TCP socket 0.0.0.0:50000 2012-08-07 14:01:36 MSG merovingian[1054]: accepting connections on UNIX domain socket /tmp/.s.monetdb.50000 2012-08-07 14:01:36 MSG discovery[1054]: listening for UDP messages on 0.0.0.0:50000 2012-08-07 14:01:36 MSG control[1054]: accepting connections on UNIX domain socket /tmp/.s.merovingian.50000 2012-08-07 14:01:36 MSG discovery[1054]: new neighbour avlsdb01 (avlsdb01.airberlin.net) 2012-08-07 14:01:37 MSG discovery[1054]: new database mapi:monetdb://avlsdb01:50000/avs_reporting (ttl=660s) 2012-08-07 14:01:39 MSG control[1054]: (local): served status list 2012-08-07 14:01:39 MSG merovingian[1054]: starting database 'avs_reporting', up min/avg/max: 3s/4h/21h, crash average: 0.00 0.80 0.70 (30-9=21) 2012-08-07 14:01:39 MSG avs_reporting[1167]: arguments: /usr/bin/mserver5 --set gdk_dbfarm=/logdata/monetdb/avsfarm --dbname=avs_reporting --set merovingian_uri=mapi:monetdb://avlsdb01:50000/avs_reporting --set mapi_open=false --set mapi_port=0 --set mapi_usock=/logdata/monetdb/avsfarm/avs_reporting/.mapi.sock --set monet_vault_key=/logdata/monetdb/avsfarm/avs_reporting/.vaultkey --set gdk_nr_threads=16 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes 2012-08-07 14:01:40 ERR avs_reporting[1167]: !FATAL: BBPinit: cannot properly process bat/BACKUP. 2012-08-07 14:01:40 MSG merovingian[1054]: database 'avs_reporting' (1167) has exited with exit status 1 2012-08-07 14:01:40 ERR control[1054]: (local): failed to fork mserver: database 'avs_reporting' appears to shut itself down after starting, check monetdbd's logfile for possible hints 2012-08-07 14:30:52 MSG control[1054]: (local): served status list 2012-08-07 14:31:04 MSG control[1054]: (local): served status list 2012-08-07 14:31:04 MSG control[1054]: (local): served default property list 2012-08-07 14:31:04 MSG control[1054]: (local): served property list for database 'avs_reporting' 2012-08-07 14:33:05 MSG control[1054]: (local): served status list 2012-08-07 14:33:05 MSG merovingian[1054]: starting database 'avs_reporting', up min/avg/max: 3s/4h/21h, crash average: 0.00 0.80 0.70 (30-9=21) 2012-08-07 14:33:05 MSG avs_reporting[3955]: arguments: /usr/bin/mserver5 --set gdk_dbfarm=/logdata/monetdb/avsfarm --dbname=avs_reporting --set merovingian_uri=mapi:monetdb://avlsdb01:50000/avs_reporting --set mapi_open=false --set mapi_port=0 --set mapi_usock=/logdata/monetdb/avsfarm/avs_reporting/.mapi.sock --set monet_vault_key=/logdata/monetdb/avsfarm/avs_reporting/.vaultkey --set gdk_nr_threads=16 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes 2012-08-07 14:33:05 ERR avs_reporting[3955]: !FATAL: BBPinit: cannot properly process bat/BACKUP. 2012-08-07 14:33:05 MSG merovingian[1054]: database 'avs_reporting' (3955) has exited with exit status 1 2012-08-07 14:33:05 ERR control[1054]: (local): failed to fork mserver: database 'avs_reporting' appears to shut itself down after starting, check monetdbd's logfile for possible hints 2012-08-07 14:34:53 MSG merovingian[1054]: starting database 'avs_reporting', up min/avg/max: 3s/4h/21h, crash average: 0.00 0.80 0.70 (30-9=21) 2012-08-07 14:34:53 MSG avs_reporting[4040]: arguments: /usr/bin/mserver5 --set gdk_dbfarm=/logdata/monetdb/avsfarm --dbname=avs_reporting --set merovingian_uri=mapi:monetdb://avlsdb01:50000/avs_reporting --set mapi_open=false --set mapi_port=0 --set mapi_usock=/logdata/monetdb/avsfarm/avs_reporting/.mapi.sock --set monet_vault_key=/logdata/monetdb/avsfarm/avs_reporting/.vaultkey --set gdk_nr_threads=16 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes 2012-08-07 14:34:53 MSG merovingian[1054]: database 'avs_reporting' (4040) has exited with exit status 1 2012-08-07 14:34:53 ERR merovingian[1054]: client error: database 'avs_reporting' appears to shut itself down after starting, check monetdbd's logfile for possible hints ------------------------------------------- root@avlsdb01:~ monetdb start avs_reporting starting database 'avs_reporting'... FAILED start: starting 'avs_reporting' failed: database 'avs_reporting' appears to shut itself down after starting, check monetdbd's logfile for possible hints root@avlsdb01:~ monetdbd get all /logdata/monetdb/avsfarm/ property value hostname avlsdb01 dbfarm /logdata/monetdb/avsfarm/ status monetdbd[1054] 1.6 (Jul2012) is serving this dbfarm mserver /usr/bin/mserver5 logfile /logdata/monetdb/avsfarm//merovingian.log pidfile /logdata/monetdb/avsfarm//merovingian.pid sockdir /tmp port 50000 exittimeout 600 forward proxy discovery yes discoveryttl 600 control no passphrase <unknown> mapisock /tmp/.s.monetdb.50000 controlsock /tmp/.s.merovingian.50000 ## Comment 17620 Date: 2012-08-07 14:51:59 +0200 From: risc &lt;<risc>&gt; please disregard my last comment - this was due to missing file permission.... ## Comment 17686 Date: 2012-08-24 14:56:01 +0200 From: @sjoerdmullender Jul2012-SP1 has been released. ## Comment 17900 Date: 2012-11-07 19:21:32 +0100 From: @grobian Sounds like something broke due to the parallel querying nature. Could this be related to bug #3163? ## Comment 18033 Date: 2012-11-27 11:33:18 +0100 From: Yagiz &lt;<y.kargin>&gt; "After some parallel queries, my database crashed." is not informative enough. So, what you need to get the first crash is unclear. ## Comment 18040 Date: 2012-11-27 12:03:56 +0100 From: risc &lt;<risc>&gt; Hi, actually i can not reproduce the behavior again, as it would need to rebuild the table, import all data again and add/drop columns repeatedly as described. Did you try to add the same column name with ALTER TABLE? Maybe this could be an hint - in my opinion, the same column name should be only once in one table, but i saw multiple same named columns. The maximum number of parallel queries was three. In my humble opinion no similarity to bug #3163. Query statements were only SELECTs similar to the above, bit with additional columns and some where clauses. I would state "works for me" as i rebuilt the table once and added columns only once. Btw. now i have 720 Million rows. thanks for your time, risc ## Comment 18041 Date: 2012-11-27 12:16:23 +0100 From: Yagiz &lt;<y.kargin>&gt; Hi, are you saying that it works for you? Which of the reasons below do you think caused this? - you upgraded to the next release. - the first crash is caused by some other race condition that only existed once on that specific case you presented.
Database crash after Selecting an added column
https://api.github.com/repos/MonetDB/MonetDB/issues/3140/comments
0
2020-11-30T12:12:58Z
2024-06-28T13:18:32Z
https://github.com/MonetDB/MonetDB/issues/3140
753,426,904
3,140
[ "MonetDB", "MonetDB" ]
Date: 2012-08-06 16:09:37 +0200 From: @bartscheers To: SQL devs &lt;<bugs-sql>&gt; Version: 11.11.7 (Jul2012-SP1) CC: @drstmane Last updated: 2012-09-21 11:51:25 +0200 ## Comment 17616 Date: 2012-08-06 16:09:37 +0200 From: @bartscheers User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:13.0) Gecko/20100101 Firefox/13.0.1 Build Identifier: When two numbers from different tables are compared, the <, > and = do work, but the <> doesn't. Reproducible: Always ### Steps to Reproduce: 1.create table t1 (id int,dp int); 2.create table t2 (id int, s int); 3.insert into t1 values (1,1),(2,2),(3,2),(4,2),(5,3),(6,3),(7,1); 4.insert into t2 values (1,1),(1,2),(1,3); 5.select t1.id,t1.dp,t3.cnt from t1,(select count(*) as cnt from t2) t3 where t1.id > 1 and t1.dp <> t3.cnt; ### Actual Results: +------+------+------+ | id | dp | cnt | +======+======+======+ | 2 | 2 | 3 | | 3 | 2 | 3 | | 4 | 2 | 3 | | 5 | 3 | 3 | | 6 | 3 | 3 | | 7 | 1 | 3 | +------+------+------+ 6 tuples ### Expected Results: +------+------+------+ | id | dp | cnt | +======+======+======+ | 2 | 2 | 3 | | 3 | 2 | 3 | | 4 | 2 | 3 | | 7 | 1 | 3 | +------+------+------+ 4 tuples Bug still there, if first where-clause is excluded ## Comment 17617 Date: 2012-08-06 18:09:14 +0200 From: @drstmane While also your query should indeed work, here is an IMHO simpler alternative: sql>declare t2_cnt bigint; set t2_cnt = (select count(*) from t2); operation successful (1.453ms) operation successful (1.483ms) sql>select t1.id,t1.dp,t2_cnt from t1 where t1.id > 1 and t1.dp <> t2_cnt; +------+------+--------------+ | id | dp | single_value | +======+======+==============+ | 2 | 2 | 3 | | 3 | 2 | 3 | | 4 | 2 | 3 | | 7 | 1 | 3 | +------+------+--------------+ 4 tuples (2.050ms) In fact, an other alternative I could imagine also yields the wrong result: sql>select t1.id,t1.dp from t1 where t1.id > 1 and t1.dp <> (select count(*) from t2); +------+------+ | id | dp | +======+======+ | 2 | 2 | | 3 | 2 | | 4 | 2 | | 5 | 3 | | 6 | 3 | | 7 | 1 | +------+------+ 6 tuples (4.260ms) ## Comment 17691 Date: 2012-08-24 14:56:05 +0200 From: @sjoerdmullender Jul2012-SP1 has been released. ## Comment 17710 Date: 2012-08-31 12:23:51 +0200 From: @sjoerdmullender Changeset [58e2e2092b55](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=58e2e2092b55) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=58e2e2092b55](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=58e2e2092b55) Changeset description: Added test for bug #3139. ## Comment 17711 Date: 2012-08-31 13:38:38 +0200 From: @sjoerdmullender Changeset [d2962f95c490](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=d2962f95c490) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=d2962f95c490](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=d2962f95c490) Changeset description: Fixed a bug in BATantijoin when either side is a singleton BAT. This fixes bug #3139.
Not equal evaluation does not work
https://api.github.com/repos/MonetDB/MonetDB/issues/3139/comments
0
2020-11-30T12:12:56Z
2024-06-27T11:57:23Z
https://github.com/MonetDB/MonetDB/issues/3139
753,426,881
3,139
[ "MonetDB", "MonetDB" ]
Date: 2012-08-03 17:02:45 +0200 From: info To: Merovingian devs &lt;<bugs-merovingian>&gt; Version: 11.11.7 (Jul2012-SP1) Last updated: 2012-08-31 15:38:40 +0200 ## Comment 17613 Date: 2012-08-03 17:02:45 +0200 From: info User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/535.1 (KHTML, like Gecko) Chrome/13.0.782.107 Safari/535.1 Build Identifier: When stopping monetdbd multiple mserver5 processes become defunct. And the monetdbd daemon will not shutdown properly. Reproducible: Always ### Steps to Reproduce: monetdbd start /monetdb/dbfarm monetdb stop -a monetdb destroy -f "*" for (( i=1; i<=10; i++ )) do monetdb create DB$i monetdb release DB$i monetdb start DB$i mclient -dDB$i < /data/programs/tests/disk_test/Tables.sql done monetdbd stop /monetdb/dbfarm ### Actual Results: Not all the databases have been stopped correctly and have become defunct. The amount of defunct databases differs per test. In the underlying example 8 of 10 mserver5 processes have stoppen correctly while 2 mserver5 processes remain as defunct processes (these don't give an exit status): 2012-08-03 16:45:31 MSG merovingian[3943]: caught SIGTERM, starting shutdown sequence 2012-08-03 16:45:34 MSG control[3943]: control channel closed 2012-08-03 16:45:34 MSG merovingian[3943]: sending process 4030 (database 'DB7') the TERM signal 2012-08-03 16:45:34 MSG merovingian[3943]: sending process 4056 (database 'DB9') the TERM signal 2012-08-03 16:45:34 MSG merovingian[3943]: sending process 4004 (database 'DB5') the TERM signal 2012-08-03 16:45:34 MSG merovingian[3943]: sending process 4019 (database 'DB6') the TERM signal 2012-08-03 16:45:34 MSG merovingian[3943]: sending process 4045 (database 'DB8') the TERM signal 2012-08-03 16:45:34 MSG merovingian[3943]: sending process 4069 (database 'DB10') the TERM signal 2012-08-03 16:45:34 MSG merovingian[3943]: sending process 3980 (database 'DB3') the TERM signal 2012-08-03 16:45:34 MSG merovingian[3943]: sending process 3955 (database 'DB1') the TERM signal 2012-08-03 16:45:34 MSG merovingian[3943]: sending process 3993 (database 'DB4') the TERM signal 2012-08-03 16:45:34 MSG merovingian[3943]: sending process 3969 (database 'DB2') the TERM signal 2012-08-03 16:45:34 MSG merovingian[3943]: database 'DB7' (4030) has exited with exit status 0 2012-08-03 16:45:34 MSG merovingian[3943]: database 'DB1' (3955) has exited with exit status 0 2012-08-03 16:45:34 MSG merovingian[3943]: database 'DB10' (4069) has exited with exit status 0 2012-08-03 16:45:34 MSG merovingian[3943]: database 'DB8' (4045) has exited with exit status 0 2012-08-03 16:45:34 MSG merovingian[3943]: database 'DB2' (3969) has exited with exit status 0 2012-08-03 16:45:34 MSG merovingian[3943]: database 'DB5' (4004) has exited with exit status 0 2012-08-03 16:45:34 MSG merovingian[3943]: database 'DB6' (4019) has exited with exit status 0 2012-08-03 16:45:34 MSG merovingian[3943]: database 'DB9' (4056) has exited with exit status 0 2012-08-03 16:45:35 MSG merovingian[3943]: database 'DB7' has shut down 2012-08-03 16:45:35 MSG merovingian[3943]: database 'DB9' has shut down 2012-08-03 16:45:35 MSG merovingian[3943]: database 'DB5' has shut down 2012-08-03 16:45:35 MSG merovingian[3943]: database 'DB6' has shut down 2012-08-03 16:45:35 MSG merovingian[3943]: database 'DB8' has shut down 2012-08-03 16:45:35 MSG merovingian[3943]: database 'DB10' has shut down 2012-08-03 16:45:35 MSG merovingian[3943]: database 'DB3' has shut down 2012-08-03 16:45:35 MSG merovingian[3943]: database 'DB1' has shut down 2012-08-03 16:45:35 MSG merovingian[3943]: database 'DB4' has shut down 2012-08-03 16:45:35 MSG merovingian[3943]: database 'DB2' has shut down 2012-08-03 16:45:35 MSG merovingian[3943]: Merovingian 1.6 stopped Although it says that Merovingian has stopped, the process monetdbd is still running and can only be killed with 'kill -9' as just 'kill' doesn't work. ### Expected Results: All the processes should have been stopped properly. See attachment for the complete merovingian logfile. ## Comment 17614 Date: 2012-08-03 17:03:28 +0200 From: info Created attachment 138 Merovingian log > Attached file: [merovingian.log](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3138_merovingian.log_138) (text/plain, 44036 bytes) > Description: Merovingian log ## Comment 17615 Date: 2012-08-03 19:03:18 +0200 From: @grobian I can't reproduce this with the following script: % cat pachupedia-defunct.sh !/usr/bin/env bash monetdbd create testfarm monetdbd set port=23456 testfarm monetdbd start testfarm sleep 1 pid=$(monetdbd get status testfarm | sed '1d') pid=${pid*monetdbd[}; pid=${pid%%] *}; echo "launched monetdbd[${pid}]" monetdb -p23456 stop -a monetdb -p23456 destroy -f "*" for (( i=1; i<=10; i++ )) do monetdb -p23456 create DB$i monetdb -p23456 release DB$i monetdb -p23456 start DB$i mclient -p23456 -dDB$i -s "create table foo (bar char(2), col int, bla varchar(255));" done monetdbd stop testfarm echo waiting for monetdbd to shut down while pgrep monetdbd | grep -q ${pid} ; do sleep 1 done rm -Rf testfarm ## Comment 17626 Date: 2012-08-17 14:01:33 +0200 From: info I have done some additional tests with your and my own script and I can still reproduce it with both scripts, but as it turns out it doesn't always show as it initially seemed. More often not. Some extra information: OS: Ubuntu 10.04.2 LTS Buid options: configure --prefix=/data/programs/MonetDB --enable-debug=no --enable-geom=no --enable-testing=no --enable-developer=no --enable-assert=no --enable-optimize=yes System Monitor (Status): monetdbd ---> Sleeping mserver5 ---> Zombie System Monitor (% CPU): monetdbd ---> 96 mserver5 ---> 0 System Monitor (Waiting Channel): monetdbd ---> futex_wait_queue_me mserver5 ---> do_exit I'll also add a screenshot of the System Monitor Thanks ## Comment 17627 Date: 2012-08-17 14:02:40 +0200 From: info Created attachment 139 Screenshot system monitor > Attached file: [Screenshot-System Monitor.png](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3138_Screenshot-System_Monitor.png_139) (image/png, 122118 bytes) > Description: Screenshot system monitor ## Comment 17668 Date: 2012-08-24 14:55:08 +0200 From: @sjoerdmullender Jul2012-SP1 has been released. ## Comment 17715 Date: 2012-08-31 14:42:05 +0200 From: @grobian It seems the Ubuntu forums are flooded with people experiencing hangs for futex_wait_queue_me for various processes. (And no solutions.) Hence, concluding this is most likely not our bug. It seems to me given your other bug (getnameinfo memleak) you better switch to a decent operating system. (For speed, try FreeBSD.) ## Comment 17719 Date: 2012-08-31 15:38:40 +0200 From: @grobian I tried this on our Distributor ID: Ubuntu Description: Ubuntu 12.04.1 LTS Release: 12.04 Codename: precise it hangs fine: (gdb) thread apply all bt Thread 2 (Thread 0xb7724b40 (LWP 16401)): 0 0x008d7416 in __kernel_vsyscall () 1 0x003b5af1 in select () from /lib/i386-linux-gnu/libc.so.6 2 0x0804e7cf in logListener () 3 0x00182d4c in start_thread () from /lib/i386-linux-gnu/libpthread.so.0 4 0x003bcace in clone () from /lib/i386-linux-gnu/libc.so.6 Thread 1 (Thread 0xb7725740 (LWP 16400)): 0 0x008d7416 in __kernel_vsyscall () 1 0x00183e1c in pthread_join () from /lib/i386-linux-gnu/libpthread.so.0 2 0x0804cf62 in main () which leads to ubuntu bug https://bugs.launchpad.net/ubuntu/+source/eglibc/+bug/775374
Mserver5 becomes defunct/zombie when stopping dbfarm
https://api.github.com/repos/MonetDB/MonetDB/issues/3138/comments
0
2020-11-30T12:12:53Z
2024-06-28T13:18:32Z
https://github.com/MonetDB/MonetDB/issues/3138
753,426,851
3,138
[ "MonetDB", "MonetDB" ]
Date: 2012-08-03 16:23:19 +0200 From: risc &lt;<risc>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.11.5 (Jul2012) CC: risc Last updated: 2012-08-14 11:45:10 +0200 ## Comment 17612 Date: 2012-08-03 16:23:19 +0200 From: risc &lt;<risc>&gt; User-Agent: Mozilla/5.0 (Windows NT 5.1; rv:14.0) Gecko/20100101 Firefox/14.0.1 Build Identifier: SELECT CAST('10' AS TINYINT) gives 49 instead of the expected value 10. Besides, CASTing AS SMALLINT or AS INT values are ok. Reproducible: Always ### Steps to Reproduce: select cast('10' as tinyint) as not_ok_tinyint, cast('10' as int) as ok_int, cast('10' as smallint) as ok_smallint ### Actual Results: not_ok_tinyint ok_int ok_smallint 49 10 10 ### Expected Results: not_ok_tinyint ok_int ok_smallint 10 10 10 ## Comment 17621 Date: 2012-08-13 16:46:59 +0200 From: @sjoerdmullender Changeset [34fcf4e7226d](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=34fcf4e7226d) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=34fcf4e7226d](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=34fcf4e7226d) Changeset description: Test for bug #3137. ## Comment 17622 Date: 2012-08-13 16:48:10 +0200 From: @sjoerdmullender I have tested this on various platforms with both the Jul2012 release and the to-be-released Jul2012-SP1 version. I always get the correct result. ## Comment 17623 Date: 2012-08-14 09:18:45 +0200 From: risc &lt;<risc>&gt; Hi Sjoerd, thanks for your effort to reproduce the bug, it happened to me using JDBC Client "Squirrel" , which is alo mentioned on your monetdb website (at http://www.monetdb.org/Documentation/Cookbooks/SQLrecipies/Clients/SQuirreL). If i execute my test-query there, i get the wrong result '49', interpreting the number 1 in 10 from the result as character and returning the ascii code. Using monetdb client "mclient", i also got the result as 10, as expected. To reproduce the problem, i was now testing it using Eclipse Data Source Explorer, there i also got 10 as result - as expected. Seems to be a problem in datatype mapping over JDBC, but maybe only a problem using SQuirreL. As a workaround, i will alter my table and use smallint instead. Again, thanks for your quick help. best regards, risc ## Comment 17624 Date: 2012-08-14 09:42:04 +0200 From: @grobian >SELECT CAST('10' AS TINYINT); &1 0 1 1 1 % . table_name % single_value name % tinyint type <--- % 2 length [ 10 ] As you can see, the type is reported by the server as "tinyint". From java/src/nl/cwi/monetdb/jdbc/MonetDriver.java: typeMap.put("tinyint", Integer.valueOf(Types.TINYINT)); so, the tinyint is mapped to Java's sql.Types.TINYINT. Now I have no clue how SquirrelSQL can turn that into 49. Perhaps it assumes that TINYINT is a 1-byte, hence CHAR(1). This assumption is wrong besides what happens afterwards. ## Comment 17625 Date: 2012-08-14 11:45:10 +0200 From: @grobian I checked squirrelsql, and it indeed does this, but I think it's a bug in squirrel. The metadata retrieved for tinyint and smallint are fine, it indicates mapping to java.lang.Integer, so no idea why it does this mapping.
Casting CHARACTER to TINYINT
https://api.github.com/repos/MonetDB/MonetDB/issues/3137/comments
0
2020-11-30T12:12:51Z
2024-06-28T13:18:31Z
https://github.com/MonetDB/MonetDB/issues/3137
753,426,818
3,137
[ "MonetDB", "MonetDB" ]
Date: 2012-08-02 13:44:32 +0200 From: info To: SQL devs &lt;<bugs-sql>&gt; Version: 11.11.7 (Jul2012-SP1) CC: @njnes, @yzchang Last updated: 2013-01-22 09:29:03 +0100 ## Comment 17600 Date: 2012-08-02 13:44:32 +0200 From: info User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/535.1 (KHTML, like Gecko) Chrome/13.0.782.107 Safari/535.1 Build Identifier: After disconnecting the clientconnection the querycache doesn't seem to be emptied, as this leak doesn't show when using "SET cache=false". We expected that the leak would only increase when using different queries, since using a query that has already been executed would've already been cached. But even when using the same queries the leak continues to increase with each query. There also seems to be a leak when only creating a clientconnection. Reproducible: Always ### Steps to Reproduce: Test1: Queries=1 Terminal1: valgrind --leak-check=full mserver5 --set gdk_alloc_map=no --dbname=leaktest >& output_mserver5_1.txt Terminal2: mclient -dleaktest Terminal2: SELECT * from types LIMIT 1; Terminal2: \q Terminal1: \q Test2: Queries=2 Terminal1: valgrind --leak-check=full mserver5 --set gdk_alloc_map=no --dbname=leaktest >& output_mserver5_1.txt Terminal2: mclient -dleaktest Terminal2: SELECT * from types LIMIT 1; Terminal2: SELECT * from types LIMIT 1; Terminal2: \q Terminal1: \q Test3: Queries=3 Terminal1: valgrind --leak-check=full mserver5 --set gdk_alloc_map=no --dbname=leaktest >& output_mserver5_1.txt Terminal2: mclient -dleaktest Terminal2: SELECT * from types LIMIT 1; Terminal2: SELECT * from types LIMIT 1; Terminal2: SELECT * from types LIMIT 1; Terminal2: \q Terminal1: \q Test4: Queries=3 + "SET cache=false" Terminal1: valgrind --leak-check=full mserver5 --set gdk_alloc_map=no --dbname=leaktest >& output_mserver5_1.txt Terminal2: mclient -dleaktest Terminal2: SET cache=false; Terminal2: SELECT * from types LIMIT 1; Terminal2: SELECT * from types LIMIT 1; Terminal2: SELECT * from types LIMIT 1; Terminal2: \q Terminal1: \q Test5: Client connection only Terminal1: valgrind --leak-check=full mserver5 --set gdk_alloc_map=no --dbname=leaktest >& output_mserver5_1.txt Terminal2: mclient -dleaktest Terminal2: \q Terminal1: \q ### Actual Results: Test1: Queries=1 ==24266== 40 bytes in 1 blocks are definitely lost in loss record 733 of 2,042 ==24266== at 0x4C274A8: malloc (vg_replace_malloc.c:236) ==24266== by 0x58AEF65: GDKmallocmax (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24266== by 0x58AF3E9: GDKmalloc (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24266== by 0x58AF475: GDKstrdup (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24266== by 0xB1C1827: SQLinitClient (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24266== by 0x4E9FFFF: ??? (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24266== by 0x4EA023E: runScenario (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24266== by 0x4EA118C: MSserveClient (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24266== by 0x6EE69C9: start_thread (pthread_create.c:300) ==24266== by 0xC1376FF: ??? ==24266== 4,272 bytes in 2 blocks are definitely lost in loss record 1,831 of 2,042 ==24266== at 0x4C274A8: malloc (vg_replace_malloc.c:236) ==24266== by 0x58AEF65: GDKmallocmax (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24266== by 0x58AF359: GDKzalloc (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24266== by 0x4E7D8B8: setLifespan (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24266== by 0x543BD22: OPTgroups (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24266== by 0x542719E: optimizeMALBlock (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24266== by 0xB1C92C1: addQueryToCache (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24266== by 0xB1C8B4E: backend_dumpproc (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24266== by 0xB1C0393: SQLparser (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24266== by 0x4EA0069: ??? (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24266== by 0x4EA023E: runScenario (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24266== by 0x4EA118C: MSserveClient (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24266== LEAK SUMMARY: ==24266== definitely lost: 4,312 bytes in 3 blocks ==24266== indirectly lost: 0 bytes in 0 blocks ==24266== possibly lost: 16,105,263 bytes in 114,360 blocks ==24266== still reachable: 136,067 bytes in 226 blocks ==24266== suppressed: 0 bytes in 0 blocks ==24266== Reachable blocks (those to which a pointer was found) are not shown. ==24266== To see them, rerun with: --leak-check=full --show-reachable=yes Test2: Queries=2 ==24292== 40 bytes in 1 blocks are definitely lost in loss record 729 of 2,040 ==24292== at 0x4C274A8: malloc (vg_replace_malloc.c:236) ==24292== by 0x58AEF65: GDKmallocmax (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24292== by 0x58AF3E9: GDKmalloc (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24292== by 0x58AF475: GDKstrdup (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24292== by 0xB1C1827: SQLinitClient (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24292== by 0x4E9FFFF: ??? (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24292== by 0x4EA023E: runScenario (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24292== by 0x4EA118C: MSserveClient (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24292== by 0x6EE69C9: start_thread (pthread_create.c:300) ==24292== by 0xC1376FF: ??? ==24292== 7,368 bytes in 3 blocks are definitely lost in loss record 1,849 of 2,040 ==24292== at 0x4C274A8: malloc (vg_replace_malloc.c:236) ==24292== by 0x58AEF65: GDKmallocmax (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24292== by 0x58AF359: GDKzalloc (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24292== by 0x4E7D8B8: setLifespan (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24292== by 0x543BD22: OPTgroups (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24292== by 0x542719E: optimizeMALBlock (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24292== by 0xB1C92C1: addQueryToCache (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24292== by 0xB1C8B4E: backend_dumpproc (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24292== by 0xB1C0393: SQLparser (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24292== by 0x4EA0069: ??? (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24292== by 0x4EA023E: runScenario (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24292== by 0x4EA118C: MSserveClient (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24292== LEAK SUMMARY: ==24292== definitely lost: 7,408 bytes in 4 blocks ==24292== indirectly lost: 0 bytes in 0 blocks ==24292== possibly lost: 16,105,295 bytes in 114,361 blocks ==24292== still reachable: 136,067 bytes in 226 blocks ==24292== suppressed: 0 bytes in 0 blocks ==24292== Reachable blocks (those to which a pointer was found) are not shown. ==24292== To see them, rerun with: --leak-check=full --show-reachable=yes Test3: Queries=3 ==24355== 40 bytes in 1 blocks are definitely lost in loss record 733 of 2,042 ==24355== at 0x4C274A8: malloc (vg_replace_malloc.c:236) ==24355== by 0x58AEF65: GDKmallocmax (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24355== by 0x58AF3E9: GDKmalloc (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24355== by 0x58AF475: GDKstrdup (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24355== by 0xB1C1827: SQLinitClient (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24355== by 0x4E9FFFF: ??? (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24355== by 0x4EA023E: runScenario (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24355== by 0x4EA118C: MSserveClient (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24355== by 0x6EE69C9: start_thread (pthread_create.c:300) ==24355== by 0xC1376FF: ??? ==24355== 10,464 bytes in 4 blocks are definitely lost in loss record 1,941 of 2,042 ==24355== at 0x4C274A8: malloc (vg_replace_malloc.c:236) ==24355== by 0x58AEF65: GDKmallocmax (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24355== by 0x58AF359: GDKzalloc (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24355== by 0x4E7D8B8: setLifespan (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24355== by 0x543BD22: OPTgroups (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24355== by 0x542719E: optimizeMALBlock (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24355== by 0xB1C92C1: addQueryToCache (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24355== by 0xB1C8B4E: backend_dumpproc (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24355== by 0xB1C0393: SQLparser (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24355== by 0x4EA0069: ??? (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24355== by 0x4EA023E: runScenario (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24355== by 0x4EA118C: MSserveClient (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24355== LEAK SUMMARY: ==24355== definitely lost: 10,504 bytes in 5 blocks ==24355== indirectly lost: 0 bytes in 0 blocks ==24355== possibly lost: 16,105,327 bytes in 114,362 blocks ==24355== still reachable: 136,067 bytes in 226 blocks ==24355== suppressed: 0 bytes in 0 blocks ==24355== Reachable blocks (those to which a pointer was found) are not shown. ==24355== To see them, rerun with: --leak-check=full --show-reachable=yes Test4: Queries=3 + "SET cache=false" ==24374== 40 bytes in 1 blocks are definitely lost in loss record 730 of 2,036 ==24374== at 0x4C274A8: malloc (vg_replace_malloc.c:236) ==24374== by 0x58AEF65: GDKmallocmax (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24374== by 0x58AF3E9: GDKmalloc (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24374== by 0x58AF475: GDKstrdup (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24374== by 0xB1C1827: SQLinitClient (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24374== by 0x4E9FFFF: ??? (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24374== by 0x4EA023E: runScenario (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24374== by 0x4EA118C: MSserveClient (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24374== by 0x6EE69C9: start_thread (pthread_create.c:300) ==24374== by 0xC1376FF: ??? ==24374== 1,176 bytes in 1 blocks are definitely lost in loss record 1,720 of 2,036 ==24374== at 0x4C274A8: malloc (vg_replace_malloc.c:236) ==24374== by 0x58AEF65: GDKmallocmax (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24374== by 0x58AF359: GDKzalloc (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24374== by 0x4E7D8B8: setLifespan (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24374== by 0x543BD22: OPTgroups (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24374== by 0x542719E: optimizeMALBlock (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24374== by 0xB1C92C1: addQueryToCache (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24374== by 0xB1C8B4E: backend_dumpproc (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24374== by 0xB1C0393: SQLparser (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24374== by 0x4EA0069: ??? (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24374== by 0x4EA023E: runScenario (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24374== by 0x4EA118C: MSserveClient (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24374== LEAK SUMMARY: ==24374== definitely lost: 1,216 bytes in 2 blocks ==24374== indirectly lost: 0 bytes in 0 blocks ==24374== possibly lost: 16,105,232 bytes in 114,359 blocks ==24374== still reachable: 136,067 bytes in 226 blocks ==24374== suppressed: 0 bytes in 0 blocks ==24374== Reachable blocks (those to which a pointer was found) are not shown. ==24374== To see them, rerun with: --leak-check=full --show-reachable=yes Test5: Client connection only ==24421== 40 bytes in 1 blocks are definitely lost in loss record 729 of 2,032 ==24421== at 0x4C274A8: malloc (vg_replace_malloc.c:236) ==24421== by 0x58AEF65: GDKmallocmax (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24421== by 0x58AF3E9: GDKmalloc (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24421== by 0x58AF475: GDKstrdup (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24421== by 0xB1C1827: SQLinitClient (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24421== by 0x4E9FFFF: ??? (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24421== by 0x4EA023E: runScenario (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24421== by 0x4EA118C: MSserveClient (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24421== by 0x6EE69C9: start_thread (pthread_create.c:300) ==24421== by 0xC1376FF: ??? ==24421== 1,176 bytes in 1 blocks are definitely lost in loss record 1,716 of 2,032 ==24421== at 0x4C274A8: malloc (vg_replace_malloc.c:236) ==24421== by 0x58AEF65: GDKmallocmax (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24421== by 0x58AF359: GDKzalloc (in /data/programs/MonetDB/lib/libbat.so.6.0.0) ==24421== by 0x4E7D8B8: setLifespan (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24421== by 0x543BD22: OPTgroups (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24421== by 0x542719E: optimizeMALBlock (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24421== by 0xB1C92C1: addQueryToCache (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24421== by 0xB1C8B4E: backend_dumpproc (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24421== by 0xB1C0393: SQLparser (in /data/programs/MonetDB/lib/monetdb5/lib_sql.so) ==24421== by 0x4EA0069: ??? (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24421== by 0x4EA023E: runScenario (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24421== by 0x4EA118C: MSserveClient (in /data/programs/MonetDB/lib/libmonetdb5.so.12.0.0) ==24421== LEAK SUMMARY: ==24421== definitely lost: 1,216 bytes in 2 blocks ==24421== indirectly lost: 0 bytes in 0 blocks ==24421== possibly lost: 16,104,160 bytes in 114,341 blocks ==24421== still reachable: 136,067 bytes in 226 blocks ==24421== suppressed: 0 bytes in 0 blocks ==24421== Reachable blocks (those to which a pointer was found) are not shown. ==24421== To see them, rerun with: --leak-check=full --show-reachable=yes ### Expected Results: No memory leaks ## Comment 17601 Date: 2012-08-02 13:47:32 +0200 From: info Created attachment 137 Logfiles valgrind > Attached file: [queryleak.tar.bz2](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3136_queryleak.tar.bz2_137) (application/x-bzip, 117461 bytes) > Description: Logfiles valgrind ## Comment 17635 Date: 2012-08-22 11:26:00 +0200 From: info Update: monetdb --version MonetDB Database Server Toolkit v1.0 (Jul2012-SP1) We did a new test on empty databases through the funnel, constantly firing the same point-query. When we DON'T use "set cache=false": - The queries seem to get slower over time. - The resident memory of the mservers increases very fast to 2GB then the increase seems to slow down (possibly because the queries are a factor 4 slower by then) When we use set "set cache=false": - The queries don't get slower - The resident memory doesn't increase. - Switching with the funnel results in the same behavior as when NOT using "set cache=false" as "set cache=false" works per client connection which gets disconnected at each switch. ## Comment 17636 Date: 2012-08-22 11:41:02 +0200 From: @grobian thanks for the analysis, it looks like a clear case now ## Comment 17667 Date: 2012-08-24 14:55:08 +0200 From: @sjoerdmullender Jul2012-SP1 has been released. ## Comment 17700 Date: 2012-08-24 15:25:09 +0200 From: @sjoerdmullender After my fixes for bug #3144 I also don't see any "definitely lost" bytes anymore when replaying the tests given here. Setting or not setting cache=false doesn't matter. I din't check slow down or growth of resident set size when doing many of these queries. ## Comment 17716 Date: 2012-08-31 14:45:34 +0200 From: @grobian (In reply to comment 5) > After my fixes for bug #3144 I also don't see any "definitely lost" bytes > anymore when replaying the tests given here. Setting or not setting > cache=false doesn't matter. > I din't check slow down or growth of resident set size when doing many of these > queries. @OP: is the problem still visible to you after these fixes? ## Comment 17717 Date: 2012-08-31 14:53:41 +0200 From: info (In reply to comment 6) > (In reply to comment 5) > > After my fixes for bug #3144 I also don't see any "definitely lost" bytes > > anymore when replaying the tests given here. Setting or not setting > > cache=false doesn't matter. > > I din't check slow down or growth of resident set size when doing many of these > > queries. > > @OP: is the problem still visible to you after these fixes? Yes, the slowdown and growth are still visible. For now we have made the following change to sql_mvc.c: Function mvc_create: m->cache = 1; to m->cache = 0; Function mvc_create: if (m->cache != 1) stack_set_number(m, "cache", 1); m->cache = 1; to if (m->cache != 0) stack_set_number(m, "cache", 0); m->cache = 0; This was done to have 'set cache=false' as the default. Not sure if these changes are completely correct, but it does stop the growth and slowdown for us. ## Comment 18045 Date: 2012-11-27 12:53:29 +0100 From: @njnes maybe we should make the size of the cache tunable. ## Comment 18106 Date: 2012-11-27 15:14:05 +0100 From: @yzchang Not possible to add test for this bug ## Comment 18218 Date: 2012-11-28 21:02:38 +0100 From: @njnes leaks are fixed and where unrelated to the query cache. The sql env variable 'cache' can now be set to the maximum allowed cached queries. Default is 20000. ## Comment 18358 Date: 2013-01-22 09:29:03 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
Memleak (in querycache?) while querying
https://api.github.com/repos/MonetDB/MonetDB/issues/3136/comments
0
2020-11-30T12:12:48Z
2024-06-27T11:57:20Z
https://github.com/MonetDB/MonetDB/issues/3136
753,426,774
3,136
[ "MonetDB", "MonetDB" ]
Date: 2012-08-01 12:21:34 +0200 From: info To: Merovingian devs &lt;<bugs-merovingian>&gt; Version: 11.11.5 (Jul2012) Last updated: 2012-08-23 10:14:39 +0200 ## Comment 17588 Date: 2012-08-01 12:21:34 +0200 From: info User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:14.0) Gecko/20100101 Firefox/14.0.1 Build Identifier: While creating & loading a database through a bash script monetdbd crashes, and the loading action freezes. note: There are 2 different versions of monetdbd running within the network (april-2011 and jul-2012), the april-2011 version doesn't have these crashes, the jul-2012 version does not crash until we create & load a database on that version. OS used: Ubuntu 10.04.2. 64 bits ----------------------------------------- The bash script: monetdb stop testns monetdb destroy -f testns monetdb create testns monetdb release testns monetdb start testns mclient -dtestns -s'CREATE TABLE "sys"."data" ( "col1" CHAR(32) DEFAULT NULL, "col2" CHAR(32) DEFAULT NULL, "col3" TIMESTAMP DEFAULT NULL, "col4" CHAR(1) DEFAULT NULL, "col5" INTEGER DEFAULT NULL, "col6" INTEGER DEFAULT NULL, "col7" INTEGER DEFAULT NULL, "col8" INTEGER DEFAULT NULL, "col9" CHAR(32) DEFAULT NULL );' mclient -dtestns -s"COPY 1242000 OFFSET 1 RECORDS INTO data FROM '/data/testdata/loadfile.csv' USING DELIMITERS '|','\n','\"' NULL AS '' locked;" mclient -dtestns -s"COPY 1242000 OFFSET 1 RECORDS INTO data FROM '/data/testdata/loadfile.csv' USING DELIMITERS '|','\n','\"' NULL AS '' locked;" mclient -dtestns -s"COPY 1242000 OFFSET 1 RECORDS INTO data FROM '/data/testdata/loadfile.csv' USING DELIMITERS '|','\n','\"' NULL AS '' locked;" mclient -dtestns -s"COPY 1242000 OFFSET 1 RECORDS INTO data FROM '/data/testdata/loadfile.csv' USING DELIMITERS '|','\n','\"' NULL AS '' locked;" mclient -dtestns -s"COPY 1242000 OFFSET 1 RECORDS INTO data FROM '/data/testdata/loadfile.csv' USING DELIMITERS '|','\n','\"' NULL AS '' locked;" mclient -dtestns -s"COPY 1242000 OFFSET 1 RECORDS INTO data FROM '/data/testdata/loadfile.csv' USING DELIMITERS '|','\n','\"' NULL AS '' locked;" ----------------------------------------- Reproducible: Always ### Steps to Reproduce: see script in details. ### Actual Results: see attached merovingian.log Merovingian log: 2012-08-01 11:01:09 MSG merovingian[11107]: Merovingian 1.6 (Jul2012) starting 2012-08-01 11:01:09 MSG merovingian[11107]: monitoring dbfarm /monetdb/dbfarm 2012-08-01 11:01:14 MSG merovingian[11107]: accepting connections on TCP socket 0.0.0.0:50000 2012-08-01 11:01:14 MSG merovingian[11107]: accepting connections on UNIX domain socket /tmp/.s.monetdb.50000 2012-08-01 11:01:19 MSG discovery[11107]: listening for UDP messages on 0.0.0.0:50000 2012-08-01 11:01:19 MSG control[11107]: accepting connections on UNIX domain socket /tmp/.s.merovingian.50000 2012-08-01 11:01:19 MSG discovery[11107]: received leave request for unknown database mapi:monetdb://PP-001A:50000/S001A_20120801 from PP-001A 2012-08-01 11:01:19 MSG discovery[11107]: new database mapi:monetdb://PP-001A:50000/S001A_20120801/S001/1/status1 (ttl=660s) 2012-08-01 11:01:19 MSG discovery[11107]: received leave request for unknown database mapi:monetdb://PP-001A:50000/S001A_20120731 from PP-001A 2012-08-01 11:01:19 MSG discovery[11107]: new database mapi:monetdb://PP-001A:50000/S001A_20120731/S001/2/status1 (ttl=660s) 2012-08-01 11:01:19 MSG discovery[11107]: received leave request for unknown database mapi:monetdb://PP-001A:50000/S001A_20120730 from PP-001A 2012-08-01 11:01:19 MSG discovery[11107]: new database mapi:monetdb://PP-001A:50000/S001A_20120730/S001/3/status1 (ttl=660s) 2012-08-01 11:01:19 MSG discovery[11107]: new neighbour PP-002A (PP-002A) 2012-08-01 11:01:20 MSG discovery[11107]: new database mapi:monetdb://PP-002A:50000/testns (ttl=660s) 2012-08-01 11:01:20 MSG discovery[11107]: new database mapi:monetdb://PP-100A:50000/MF_100A0 (ttl=660s) 2012-08-01 11:01:20 MSG discovery[11107]: registered neighbour PP-100A:50001 2012-08-01 11:01:20 MSG discovery[11107]: received leave request for unknown database mapi:monetdb://PP-001B:50000/S001B_20120801 from PP-001B 2012-08-01 11:01:20 MSG discovery[11107]: new database mapi:monetdb://PP-001B:50000/S001B_20120801/S001/1/status2 (ttl=660s) 2012-08-01 11:01:20 MSG discovery[11107]: received leave request for unknown database mapi:monetdb://PP-001B:50000/S001B_20120731 from PP-001B 2012-08-01 11:01:20 MSG discovery[11107]: new database mapi:monetdb://PP-001B:50000/S001B_20120731/S001/2/status2 (ttl=660s) 2012-08-01 11:01:20 MSG discovery[11107]: received leave request for unknown database mapi:monetdb://PP-001B:50000/S001B_20120730 from PP-001B 2012-08-01 11:01:20 MSG discovery[11107]: new database mapi:monetdb://PP-001B:50000/S001B_20120730/S001/3/status2 (ttl=660s) 2012-08-01 11:01:21 MSG discovery[11107]: registered neighbour PP-001A:50001 2012-08-01 11:01:21 MSG discovery[11107]: registered neighbour PP-001B:50001 2012-08-01 11:01:27 MSG control[11107]: (local): served status list 2012-08-01 11:01:30 MSG control[11107]: (local): served status list 2012-08-01 11:01:30 ERR control[11107]: (local): received stop signal for non running database: testns 2012-08-01 11:01:30 MSG control[11107]: (local): served status list 2012-08-01 11:01:30 MSG discovery[11107]: removed neighbour database mapi:monetdb://PP-002A:50000/testns 2012-08-01 11:01:30 MSG control[11107]: (local): destroyed database 'testns' 2012-08-01 11:01:30 MSG control[11107]: (local): created database 'testns' 2012-08-01 11:01:30 MSG control[11107]: (local): served status list 2012-08-01 11:01:30 MSG control[11107]: (local): released database 'testns' 2012-08-01 11:01:30 MSG discovery[11107]: new database mapi:monetdb://PP-002A:50000/testns (ttl=660s) 2012-08-01 11:01:30 MSG control[11107]: (local): served status list 2012-08-01 11:01:30 MSG merovingian[11107]: starting database 'testns', up min/avg/max: 0s/0s/0s, crash average: 0.00 0.00 0.00 (0-0=0) 2012-08-01 11:01:30 MSG testns[11119]: arguments: /data/programs/MonetDB/bin/mserver5 --set gdk_dbfarm=/monetdb/dbfarm --dbname=testns --set merovingian_uri=mapi:monetdb://PP-002A:50000/testns --set mapi_open=false --set mapi_port=0 --set mapi_usock=/monetdb/dbfarm/testns/.mapi.sock --set monet_vault_key=/monetdb/dbfarm/testns/.vaultkey --set gdk_nr_threads=2 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes 2012-08-01 11:01:30 MSG testns[11119]: MonetDB 5 server v11.11.5 "Jul2012" 2012-08-01 11:01:30 MSG testns[11119]: Serving database 'testns', using 2 threads 2012-08-01 11:01:30 MSG testns[11119]: Compiled for x86_64-unknown-linux-gnu/64bit with 64bit OIDs dynamically linked 2012-08-01 11:01:30 MSG testns[11119]: Found 23.583 GiB available main-memory. 2012-08-01 11:01:30 MSG testns[11119]: Copyright (c) 1993-July 2008 CWI. 2012-08-01 11:01:30 MSG testns[11119]: Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved 2012-08-01 11:01:30 MSG testns[11119]: Visit http://www.monetdb.org/ for further information 2012-08-01 11:01:30 MSG testns[11119]: Listening for UNIX domain connection requests on mapi:monetdb:///monetdb/dbfarm/testns/.mapi.sock 2012-08-01 11:01:30 MSG testns[11119]: MonetDB/JAQL module loaded 2012-08-01 11:01:30 MSG testns[11119]: MonetDB/SQL module loaded 2012-08-01 11:01:31 MSG discovery[11107]: removed neighbour database mapi:monetdb://PP-001B:50000/S001B_20120801/S001/1/status2 2012-08-01 11:01:31 MSG discovery[11107]: new database mapi:monetdb://PP-001B:50000/S001B_20120801/S001/1/query (ttl=660s) 2012-08-01 11:01:31 MSG discovery[11107]: removed neighbour database mapi:monetdb://PP-001B:50000/S001B_20120731/S001/2/status2 2012-08-01 11:01:31 MSG discovery[11107]: new database mapi:monetdb://PP-001B:50000/S001B_20120731/S001/2/query (ttl=660s) 2012-08-01 11:01:31 MSG discovery[11107]: removed neighbour database mapi:monetdb://PP-001B:50000/S001B_20120730/S001/3/status2 2012-08-01 11:01:31 MSG discovery[11107]: new database mapi:monetdb://PP-001B:50000/S001B_20120730/S001/3/query (ttl=660s) 2012-08-01 11:01:31 MSG control[11107]: (local): started 'testns' 2012-08-01 11:01:31 MSG merovingian[11107]: proxying client (local) for database 'testns' to mapi:monetdb:///monetdb/dbfarm/testns/.mapi.sock?database=testns 2012-08-01 11:01:31 MSG merovingian[11107]: target connection is on local UNIX domain socket, passing on filedescriptor instead of proxying 2012-08-01 11:01:31 MSG merovingian[11107]: proxying client (local) for database 'testns' to mapi:monetdb:///monetdb/dbfarm/testns/.mapi.sock?database=testns 2012-08-01 11:01:31 MSG merovingian[11107]: target connection is on local UNIX domain socket, passing on filedescriptor instead of proxying 2012-08-01 11:01:31 MSG testns[11119]: SQL catalog created, loading sql scripts once 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 09_like.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 10_math.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 11_times.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 12_url.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 13_date.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 14_inet.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 15_history.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 16_tracelog.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 17_compress.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 18_dictionary.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 19_cluster.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 20_vacuum.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 21_dependency_functions.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 22_clients.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 23_skyserver.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 24_zorder.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 25_debug.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 39_analytics.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 80_udf.sql 2012-08-01 11:01:31 MSG testns[11119]: loading sql script: 99_system.sql 2012-08-01 11:01:31 MSG merovingian[11107]: proxying client (local) for database 'testns' to mapi:monetdb:///monetdb/dbfarm/testns/.mapi.sock?database=testns 2012-08-01 11:01:31 MSG merovingian[11107]: target connection is on local UNIX domain socket, passing on filedescriptor instead of proxying 2012-08-01 11:01:31 MSG merovingian[11107]: proxying client (local) for database 'testns' to mapi:monetdb:///monetdb/dbfarm/testns/.mapi.sock?database=testns 2012-08-01 11:01:31 MSG merovingian[11107]: target connection is on local UNIX domain socket, passing on filedescriptor instead of proxying SEGMENTATION FAULT OCCURRED a fatal error has occurred which prevents monetdbd from operating. This is likely a bug in monetdbd, please report it on http://bugs.monetdb.org/ and include the tail of this log in your bugreport with your explanation of what you were doing, if possible. ABORTING NOW, YOU HAVE TO MANUALLY KILL ALL REMAINING mserver5 PROCESSES 2012-08-01 11:01:31 MSG discovery[11107]: removed neighbour database mapi:monetdb://PP-001A:50000/S001A_20120801/S001/1/status1 ## Comment 17593 Date: 2012-08-01 15:43:53 +0200 From: @grobian not good, hope I can reproduce this ## Comment 17597 Date: 2012-08-02 10:09:24 +0200 From: @grobian Changeset [06126c783aaf](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=06126c783aaf) made by Fabian Groffen <fabian@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=06126c783aaf](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=06126c783aaf) Changeset description: removeRemoteDB: fix crash when removing the only db in the list linked lists can be hard sometimes :( Fix crash observed in bug #3135. The first (and only) database in the remote list was removed and lead to a segfault due to a logic error. ## Comment 17598 Date: 2012-08-02 10:12:23 +0200 From: @grobian I believe this is fixed now, but I'd love when you could try this patch (or current Jul2012 branch head) to see if this fixes the issue completely for you. ## Comment 17599 Date: 2012-08-02 11:27:36 +0200 From: info (In reply to comment 3) > I believe this is fixed now, but I'd love when you could try this patch (or > current Jul2012 branch head) to see if this fixes the issue completely for you. I applied the patch in the juli2012 release, the crash doesn't occur anymore. Thnx! ## Comment 17640 Date: 2012-08-23 10:14:39 +0200 From: @sjoerdmullender Jul2012-SP1 has been released.
monetdbd crash while creating & loading database
https://api.github.com/repos/MonetDB/MonetDB/issues/3135/comments
0
2020-11-30T12:12:45Z
2024-06-27T11:57:19Z
https://github.com/MonetDB/MonetDB/issues/3135
753,426,737
3,135
[ "MonetDB", "MonetDB" ]
Date: 2012-07-29 11:25:45 +0200 From: Christian Braun &lt;<hcb>&gt; To: Merovingian devs &lt;<bugs-merovingian>&gt; Version: 11.11.7 (Jul2012-SP1) CC: ivanzolotuhin Last updated: 2012-09-21 11:51:26 +0200 ## Comment 17583 Date: 2012-07-29 11:25:45 +0200 From: Christian Braun &lt;<hcb>&gt; User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:14.0) Gecko/20100101 Firefox/14.0.1 Build Identifier: A database does not get started if there is a lot of old temporary data to be removed during startup. Happens for me most of the time when a database gets stopped with running query. Reproducible: Always ## Comment 17584 Date: 2012-07-29 11:27:16 +0200 From: Christian Braun &lt;<hcb>&gt; Created attachment 136 Adds property starttimeout Makes the default 10 seconds startup timeout configurable. > Attached file: [monetdbd.diff](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3134_monetdbd.diff_136) (text/plain, 2440 bytes) > Description: Adds property starttimeout ## Comment 17585 Date: 2012-07-29 11:30:43 +0200 From: @grobian Oh, wow, thanks. I was thanking in a different direction, to make merovingian know the difference between a database recovering, and a database not starting up. Another way would be to unify start and exit timeout values. ## Comment 17603 Date: 2012-08-02 16:05:39 +0200 From: @grobian Changeset [ab6705d3d0b1](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=ab6705d3d0b1) made by Fabian Groffen <fabian@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=ab6705d3d0b1](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=ab6705d3d0b1) Changeset description: monetdbd: wait for servers to be fully started This is a solution for bug #3134. Sabaoth now makes a difference between starting and started. mserver5 uses this, such that processing the write ahead log should delay the state of the server becoming started. This way, monetdbd can wait for a server to become fully available. Unfortunately our global lock in combination with a possible indefinite wait is a potential killer of the entire system. ## Comment 17604 Date: 2012-08-02 16:06:48 +0200 From: @grobian This should be implemented without flags now, giving the database as much time as it needs. ## Comment 17606 Date: 2012-08-03 09:53:49 +0200 From: @grobian *** Bug #3133 has been marked as a duplicate of this bug. *** ## Comment 17644 Date: 2012-08-23 10:14:41 +0200 From: @sjoerdmullender Jul2012-SP1 has been released. ## Comment 17645 Date: 2012-08-23 11:48:28 +0200 From: Christian Braun &lt;<hcb>&gt; Hello, i updated to latest release (from 11.11.5-20120710 to 11.11.7-20120813). The database did not start automatically and i had to execute "monetdb start" multiple times. The error i was getting: start: starting 'db' failed: database 'db' started up, but failed to open up a communication channel Regards, Christian. ## Comment 17646 Date: 2012-08-23 11:49:18 +0200 From: Christian Braun &lt;<hcb>&gt; Created attachment 141 monetdb logfile > Attached file: [merovingian.log](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3134_merovingian.log_141) (text/plain, 8578 bytes) > Description: monetdb logfile ## Comment 17647 Date: 2012-08-23 11:49:53 +0200 From: Christian Braun &lt;<hcb>&gt; Created attachment 142 shell commands log > Attached file: [cmd.log](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3134_cmd.log_142) (text/plain, 725 bytes) > Description: shell commands log ## Comment 17648 Date: 2012-08-23 12:24:21 +0200 From: @grobian the database gets a SIGTERM almost immediately after it's been started, I wonder why monetdbd does that ## Comment 17670 Date: 2012-08-24 14:55:09 +0200 From: @sjoerdmullender Jul2012-SP1 has been released. ## Comment 17706 Date: 2012-08-29 15:56:48 +0200 From: @grobian we have confirmed this issue here now, but I have no clue yet why the database is reported "started" while it has no connections and scenarios available ## Comment 17712 Date: 2012-08-31 14:01:11 +0200 From: @grobian Changeset [9e0f79672cf9](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=9e0f79672cf9) made by Fabian Groffen <fabian@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=9e0f79672cf9](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=9e0f79672cf9) Changeset description: sabaoth: resolve race-like condition in determining state Because GDKinit can take some time, GDKlockHome may have been called while msab_registerStarting was not. In this gap, any msab_getStatus call would conclude the database to be running, since the GDK lockfile is locked. Since we cannot set anything before we actually know that we can start the database to be started (e.g. not locked by another process), we now flag when a database is done starting, instead of flagging it is still busy starting up. This resolves the problem reported in bug #3134, comment 7, that was introduced in Jul2012-SP1. ## Comment 17713 Date: 2012-08-31 14:02:26 +0200 From: @grobian Found the cause for this, will be released in Jul2012-SP2
Database gets killed by timeout during startup
https://api.github.com/repos/MonetDB/MonetDB/issues/3134/comments
0
2020-11-30T12:12:43Z
2024-06-27T11:57:18Z
https://github.com/MonetDB/MonetDB/issues/3134
753,426,705
3,134
[ "MonetDB", "MonetDB" ]
Date: 2012-07-25 18:28:50 +0200 From: Ivan Zolotuhin &lt;<ivanzolotuhin>&gt; To: GDK devs &lt;<bugs-common>&gt; Version: 11.11.5 (Jul2012) CC: @mlkersten Duplicates: #3134 Last updated: 2012-08-03 14:09:41 +0200 ## Comment 17574 Date: 2012-07-25 18:28:50 +0200 From: Ivan Zolotuhin &lt;<ivanzolotuhin>&gt; When I am trying to start database it gives me "start: starting 'dm1' failed: timeout while waiting for database 'dm1' to open up a communication channel " What before. OS: CentOS 6.3 + BTRFS HW: HP Proliant DL580 G5, 70 Gb RAM, 8.2 GB BTRFS Partition DB: Tables with 2000000 to 2000000000 rows. First I have compiled MonetDB using standart EL6 GCC (4.4.6), it returned lot of warnings but all RPMs was compiled sucessfully and I have installed them (used SRPMs from SRPMs for Fedora 17) Started to build database, and after some time just stop it and it not started, but after rollback snapshot (thanks for BTRFS) it started and I have continued to build database. Then I have installed GCC 4.7.1 and recompiled MonetDB without errors with standart ./configure options. The same thing. It works, but after some queries if I will stop it it will never start again. Then I have recompiled it with "./configure --enable-merocontrol --enable-optimize". The same result. Everything works very fast, impressive. To run query takes 5-10+ times faster than Oracle on the same HW, but then do some query like show table content in SquirrelSQL, and for 5 hours it returns nothing but some CPU cores do something. And when execute same queries it works much much slower than before. And it is possible to restart SquirrelSQL and run another queries. Trace shows something which looks suspicios (but I am not expert): [root@monet ~] strace -p 3187 -F Process 3187 attached with 16 threads - interrupt to quit [pid 3196] futex(0x7fc3f01f3cb8, FUTEX_WAIT_PRIVATE, 0, NULL <unfinished ...> [pid 3509] read(29, <unfinished ...> [pid 3200] futex(0x7fc3f01f3cb8, FUTEX_WAIT_PRIVATE, 0, NULL <unfinished ...> [pid 3198] futex(0x7fc3f01f3cb8, FUTEX_WAIT_PRIVATE, 0, NULL <unfinished ...> [pid 3197] futex(0x7fc3f01f3cb8, FUTEX_WAIT_PRIVATE, 0, NULL <unfinished ...> [pid 3195] futex(0x7fc3f01f3cb8, FUTEX_WAIT_PRIVATE, 0, NULL <unfinished ...> [pid 3189] select(26, [25], NULL, NULL, {0, 257269} <unfinished ...> [pid 3199] futex(0x7fc3f01f3cb8, FUTEX_WAIT_PRIVATE, 0, NULL <unfinished ...> [pid 3194] futex(0x7fc3f01f3cb8, FUTEX_WAIT_PRIVATE, 0, NULL <unfinished ...> [pid 3193] futex(0x7fc3f01f3cb8, FUTEX_WAIT_PRIVATE, 0, NULL <unfinished ...> [pid 3192] read(28, <unfinished ...> [pid 3188] select(0, NULL, NULL, NULL, {0, 32057} <unfinished ...> [pid 3758] read(30, <unfinished ...> [pid 3187] select(0, NULL, NULL, NULL, {0, 112499} <unfinished ...> [pid 3190] select(0, NULL, NULL, NULL, {4, 437377} <unfinished ...> [pid 3188] <... select resumed> ) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000} <unfinished ...> [pid 3187] <... select resumed> ) = 0 (Timeout) [pid 3187] select(0, NULL, NULL, NULL, {5, 0} <unfinished ...> [pid 3188] <... select resumed> ) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000} <unfinished ...> [pid 3189] <... select resumed> ) = 0 (Timeout) [pid 3189] select(26, [25], NULL, NULL, {0, 500000} <unfinished ...> [pid 3188] <... select resumed> ) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000} <unfinished ...> [pid 3189] <... select resumed> ) = 0 (Timeout) [pid 3189] select(26, [25], NULL, NULL, {0, 500000} <unfinished ...> [pid 3188] <... select resumed> ) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) [pid 3188] select(0, NULL, NULL, NULL, {0, 50000}) = 0 (Timeout) After this I am tring to restart MonetDB to remove CPU usage. [root@rgsl033 ~] monetdb stop dm1 [root@rgsl033 ~] monetdb start dm1 starting database 'dm1'... FAILED start: starting 'dm1' failed: timeout while waiting for database 'dm1' to open up a communication channel Should I install Fedora 17 and use only precompiled RPMs? Should I rebuild DB. ## Comment 17575 Date: 2012-07-26 22:23:06 +0200 From: Ivan Zolotuhin &lt;<ivanzolotuhin>&gt; The same behavior. Set database to readonly mode, open SquirrelSQL, browse content and exacly same behavior: nothing goes as result, 2 cpu cores do something, after "monetdb stop db" and then "start" the same message, but the same database (rollback snaphot) works fine ## Comment 17576 Date: 2012-07-26 22:25:54 +0200 From: @grobian can you please attach merovingian.log or post the relevant part from your failed start attempt? ## Comment 17577 Date: 2012-07-26 23:10:10 +0200 From: Ivan Zolotuhin &lt;<ivanzolotuhin>&gt; It is funny, now, after 6 hours I am able to start it. Anyway attaching last day of log 2012-07-26 09:58:59 MSG dm1[3230]: MonetDB 5 server v11.11.5 "Jul2012" 2012-07-26 09:58:59 MSG dm1[3230]: Serving database 'dm1', using 8 threads 2012-07-26 09:58:59 MSG dm1[3230]: Compiled for x86_64-unknown-linux-gnu/64bit with 64bit OIDs dynamically linked 2012-07-26 09:58:59 MSG dm1[3230]: Found 70.932 GiB available main-memory. 2012-07-26 09:58:59 MSG dm1[3230]: Copyright (c) 1993-July 2008 CWI. 2012-07-26 09:58:59 MSG dm1[3230]: Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved 2012-07-26 09:58:59 MSG dm1[3230]: Visit http://www.monetdb.org/ for further information 2012-07-26 09:58:59 MSG dm1[3230]: Listening for UNIX domain connection requests on mapi:monetdb:///data02/MonetDB/dm1/.mapi.sock 2012-07-26 09:58:59 MSG dm1[3230]: MonetDB/JAQL module loaded 2012-07-26 09:58:59 MSG dm1[3230]: MonetDB/SQL module loaded 2012-07-26 09:59:03 MSG control[3164]: (local): served status list 2012-07-26 09:59:52 MSG control[3164]: (local): served status list 2012-07-26 09:59:52 MSG control[3164]: (local): served default property list 2012-07-26 09:59:52 MSG control[3164]: (local): served property list for database 'dm1' 2012-07-26 09:59:52 MSG control[3164]: (local): served property list for database 'dm1_20120724-crash' 2012-07-26 09:59:52 MSG control[3164]: (local): served property list for database 'dm1_20120724_ok' 2012-07-26 09:59:52 MSG control[3164]: (local): served property list for database 'voc' 2012-07-26 10:00:32 MSG control[3164]: (local): served status list 2012-07-26 10:00:32 ERR control[3164]: (local): cannot set property 'readonly' on running database 2012-07-26 10:00:44 MSG control[3164]: (local): served status list 2012-07-26 10:00:44 MSG control[3164]: (local): locked database 'dm1' 2012-07-26 10:00:44 MSG discovery[3164]: removed neighbour database mapi:monetdb://rgsl033.lmuk.local:50000/dm1 2012-07-26 10:00:45 MSG control[3164]: (local): served status list 2012-07-26 10:00:45 ERR control[3164]: (local): cannot set property 'readonly' on running database 2012-07-26 10:00:50 MSG control[3164]: (local): served status list 2012-07-26 10:00:50 MSG merovingian[3164]: sending process 3230 (database 'dm1') the TERM signal 2012-07-26 10:00:50 MSG merovingian[3164]: database 'dm1' (3230) has exited with exit status 0 2012-07-26 10:00:50 MSG merovingian[3164]: database 'dm1' has shut down 2012-07-26 10:00:50 MSG control[3164]: (local): stopped database 'dm1' 2012-07-26 10:00:52 MSG control[3164]: (local): served status list 2012-07-26 10:00:52 MSG control[3164]: (local): set property 'readonly' for database 'dm1' to 'yes' 2012-07-26 10:00:56 MSG control[3164]: (local): served status list 2012-07-26 10:00:56 MSG merovingian[3164]: startup of database under maintenance 'dm1' forced 2012-07-26 10:00:56 MSG merovingian[3164]: starting database 'dm1', up min/avg/max: 4s/10h/4d, crash average: 0.00 0.30 0.17 (30-25=5) 2012-07-26 10:00:57 MSG merovingian[3164]: database 'dm1' has been put into maintenance mode during startup 2012-07-26 10:00:57 MSG control[3164]: (local): started 'dm1' 2012-07-26 10:00:57 MSG dm1[3253]: arguments: /usr/local/bin/mserver5 --set gdk_dbfarm=/data02/MonetDB --dbname=dm1 --set merovingian_uri=mapi:monetdb://rgsl033.lmuk.local:50000/dm1 --set mapi_open=false --set mapi_port=0 --set mapi_usock=/data02/MonetDB/dm1/.mapi.sock --set monet_vault_key=/data02/MonetDB/dm1/.vaultkey --set gdk_nr_threads=8 --set max_clients=64 --set sql_optimizer=default_pipe --readonly --set monet_daemon=yes 2012-07-26 10:00:57 MSG dm1[3253]: MonetDB 5 server v11.11.5 "Jul2012" 2012-07-26 10:00:57 MSG dm1[3253]: Serving database 'dm1', using 8 threads 2012-07-26 10:00:57 MSG dm1[3253]: Compiled for x86_64-unknown-linux-gnu/64bit with 64bit OIDs dynamically linked 2012-07-26 10:00:57 MSG dm1[3253]: Found 70.932 GiB available main-memory. 2012-07-26 10:00:57 MSG dm1[3253]: Copyright (c) 1993-July 2008 CWI. 2012-07-26 10:00:57 MSG dm1[3253]: Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved 2012-07-26 10:00:57 MSG dm1[3253]: Visit http://www.monetdb.org/ for further information 2012-07-26 10:00:57 MSG dm1[3253]: Listening for UNIX domain connection requests on mapi:monetdb:///data02/MonetDB/dm1/.mapi.sock 2012-07-26 10:00:57 MSG dm1[3253]: MonetDB/JAQL module loaded 2012-07-26 10:00:57 MSG dm1[3253]: MonetDB/SQL module loaded 2012-07-26 10:01:03 MSG control[3164]: (local): served status list 2012-07-26 10:01:03 MSG control[3164]: (local): released database 'dm1' 2012-07-26 10:01:03 MSG discovery[3164]: new database mapi:monetdb://rgsl033.lmuk.local:50000/dm1 (ttl=660s) 2012-07-26 10:01:07 MSG merovingian[3164]: proxying client gallap210.lmuk.local:1819 for database 'dm1' to mapi:monetdb:///data02/MonetDB/dm1/.mapi.sock?database=dm1 2012-07-26 10:01:07 MSG merovingian[3164]: target connection is on local UNIX domain socket, passing on filedescriptor instead of proxying 2012-07-26 10:06:02 MSG merovingian[3164]: proxying client gallap210.lmuk.local:1898 for database 'dm1' to mapi:monetdb:///data02/MonetDB/dm1/.mapi.sock?database=dm1 2012-07-26 10:06:02 MSG merovingian[3164]: target connection is on local UNIX domain socket, passing on filedescriptor instead of proxying 2012-07-26 10:06:43 MSG discovery[3164]: new database mapi:monetdb://rgsl033.lmuk.local:50000/dm1_20120724-crash (ttl=660s) 2012-07-26 10:06:43 MSG discovery[3164]: new database mapi:monetdb://rgsl033.lmuk.local:50000/dm1_20120724_ok (ttl=660s) 2012-07-26 12:37:07 MSG discovery[3164]: new neighbour monetdbtest.lmuk.local (192.168.23.81) 2012-07-26 15:39:35 MSG merovingian[3164]: proxying client gallap210.lmuk.local:2220 for database 'dm1' to mapi:monetdb:///data02/MonetDB/dm1/.mapi.sock?database=dm1 2012-07-26 15:39:35 MSG merovingian[3164]: target connection is on local UNIX domain socket, passing on filedescriptor instead of proxying 2012-07-26 15:55:24 MSG control[3164]: (local): served status list 2012-07-26 15:55:24 MSG merovingian[3164]: sending process 3253 (database 'dm1') the TERM signal 2012-07-26 15:55:24 MSG merovingian[3164]: database 'dm1' has shut down 2012-07-26 15:55:24 MSG control[3164]: (local): stopped database 'dm1' 2012-07-26 15:55:25 MSG merovingian[3164]: database 'dm1' (3253) has exited with exit status 0 2012-07-26 15:55:27 MSG control[3164]: (local): served status list 2012-07-26 15:55:27 MSG merovingian[3164]: starting database 'dm1', up min/avg/max: 4s/10h/4d, crash average: 0.00 0.30 0.17 (31-26=5) 2012-07-26 15:55:28 MSG dm1[7206]: arguments: /usr/local/bin/mserver5 --set gdk_dbfarm=/data02/MonetDB --dbname=dm1 --set merovingian_uri=mapi:monetdb://rgsl033.lmuk.local:50000/dm1 --set mapi_open=false --set mapi_port=0 --set mapi_usock=/data02/MonetDB/dm1/.mapi.sock --set monet_vault_key=/data02/MonetDB/dm1/.vaultkey --set gdk_nr_threads=8 --set max_clients=64 --set sql_optimizer=default_pipe --readonly --set monet_daemon=yes 2012-07-26 15:55:38 MSG merovingian[3164]: sending process 7206 (database 'dm1') the TERM signal 2012-07-26 15:55:38 MSG merovingian[3164]: database 'dm1' (7206) has exited with exit status 15 2012-07-26 15:55:38 MSG merovingian[3164]: database 'dm1' has shut down 2012-07-26 15:55:38 ERR control[3164]: (local): failed to fork mserver: timeout while waiting for database 'dm1' to open up a communication channel 2012-07-26 16:18:00 MSG control[3164]: (local): served status list 2012-07-26 16:18:00 MSG merovingian[3164]: starting database 'dm1', up min/avg/max: 4s/10h/4d, crash average: 0.00 0.30 0.17 (31-26=5) 2012-07-26 16:18:01 MSG dm1[7233]: arguments: /usr/local/bin/mserver5 --set gdk_dbfarm=/data02/MonetDB --dbname=dm1 --set merovingian_uri=mapi:monetdb://rgsl033.lmuk.local:50000/dm1 --set mapi_open=false --set mapi_port=0 --set mapi_usock=/data02/MonetDB/dm1/.mapi.sock --set monet_vault_key=/data02/MonetDB/dm1/.vaultkey --set gdk_nr_threads=8 --set max_clients=64 --set sql_optimizer=default_pipe --readonly --set monet_daemon=yes 2012-07-26 16:18:15 MSG merovingian[3164]: sending process 7233 (database 'dm1') the TERM signal 2012-07-26 16:18:15 MSG merovingian[3164]: database 'dm1' (7233) has exited with exit status 15 2012-07-26 16:18:15 MSG merovingian[3164]: database 'dm1' has shut down 2012-07-26 16:18:15 ERR control[3164]: (local): failed to fork mserver: timeout while waiting for database 'dm1' to open up a communication channel 2012-07-26 22:03:38 MSG control[3164]: (local): served status list 2012-07-26 22:03:38 MSG merovingian[3164]: starting database 'dm1', up min/avg/max: 4s/10h/4d, crash average: 0.00 0.30 0.17 (31-26=5) 2012-07-26 22:03:39 MSG dm1[7601]: arguments: /usr/local/bin/mserver5 --set gdk_dbfarm=/data02/MonetDB --dbname=dm1 --set merovingian_uri=mapi:monetdb://rgsl033.lmuk.local:50000/dm1 --set mapi_open=false --set mapi_port=0 --set mapi_usock=/data02/MonetDB/dm1/.mapi.sock --set monet_vault_key=/data02/MonetDB/dm1/.vaultkey --set gdk_nr_threads=8 --set max_clients=64 --set sql_optimizer=default_pipe --readonly --set monet_daemon=yes 2012-07-26 22:03:44 MSG dm1[7601]: MonetDB 5 server v11.11.5 "Jul2012" 2012-07-26 22:03:44 MSG dm1[7601]: Serving database 'dm1', using 8 threads 2012-07-26 22:03:44 MSG dm1[7601]: Compiled for x86_64-unknown-linux-gnu/64bit with 64bit OIDs dynamically linked 2012-07-26 22:03:44 MSG dm1[7601]: Found 70.932 GiB available main-memory. 2012-07-26 22:03:44 MSG dm1[7601]: Copyright (c) 1993-July 2008 CWI. 2012-07-26 22:03:44 MSG dm1[7601]: Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved 2012-07-26 22:03:44 MSG dm1[7601]: Visit http://www.monetdb.org/ for further information 2012-07-26 22:03:44 MSG dm1[7601]: Listening for UNIX domain connection requests on mapi:monetdb:///data02/MonetDB/dm1/.mapi.sock 2012-07-26 22:03:44 MSG dm1[7601]: MonetDB/JAQL module loaded 2012-07-26 22:03:44 MSG dm1[7601]: MonetDB/SQL module loaded 2012-07-26 22:03:44 MSG control[3164]: (local): started 'dm1' 2012-07-26 22:03:58 MSG control[3164]: (local): served status list [root@rgsl033 MonetDB] ## Comment 17578 Date: 2012-07-27 08:26:44 +0200 From: @grobian How big is your dbfarm? (you only mention a 8.2 GB partition, did you mean TB?) Maybe the server just needs more time to startup, which monetdbd doesn't give it. ## Comment 17579 Date: 2012-07-27 10:45:15 +0200 From: Ivan Zolotuhin &lt;<ivanzolotuhin>&gt; It was mistake. 8.2 TB partition, not GB, Whole database - 845Gb [root@server ~] du -hs /data02/MonetDB/dm1 845G /data02/MonetDB/dm1 Usually database starts within seconds. But after this errors it don't starts. As I told. I have snapshot of DB, it start within few seconds [root@rgsl033 dm3_owner] time monetdb start dm1 starting database 'dm1'... done real 0m0.509s user 0m0.003s sys 0m0.004s Compressed CSV.BZ2 total about 100 Gbs, Biggest table compressed 66 Gb (2 billion rows). But the same error was on smaller tables ( even 2 000 000 rows). Now I have installed Fedora 17 to test server (HP Proliant DL360G8 with Xeon E5-2650), will try with your RPMs. Also will try to rebuild database from start. But anyway, not sure what request exactly SquirrelSQL send on "browse content", but 2 CPUs works for long time and during this time (hours) berformance decreases 5-10 times). ## Comment 17580 Date: 2012-07-27 15:38:50 +0200 From: Ivan Zolotuhin &lt;<ivanzolotuhin>&gt; I have copied database to new DL 360 G8, Fedora 17, 64 Gb RAM, RPMs installed from here: http://dev.monetdb.org/downloads/Fedora/17/x86_64/ Exactly same result. Start database. all works, browse content in SquirrelSQL, wait for one hour (nothing coming, but 2 CPU cores in use, and during this time execution of other queries takes 10x more than before). Stop, wait for minute and try to start. the same result (timeout), but database was not modified (but after 5 minutes it starts). Part of log (new server, forget to adjust clock) 2012-03-12 23:34:43 MSG dm1[41378]: GDKrealloc(77309411344) fails, try to free up space [memory in use=55506520984,virtual memory in use=138389506968] 2012-03-12 23:34:43 MSG dm1[41378]: GDKrealloc(77309411344) result [mem=55506520984,vm=138389506968] 2012-03-12 23:34:43 MSG dm1[41378]: GDKrealloc(77309411344) fails, try to free up space [memory in use=55506520984,virtual memory in use=138389506968] 2012-03-12 23:34:43 MSG dm1[41378]: GDKrealloc(77309411344) result [mem=55506520984,vm=138389506968] 2012-03-12 23:34:43 MSG dm1[41378]: GDKrealloc(77309411344) fails, try to free up space [memory in use=55506520984,virtual memory in use=138389506968] 2012-03-12 23:34:43 MSG dm1[41378]: GDKrealloc(77309411344) result [mem=55506520984,vm=138389506968] 2012-03-12 23:34:43 MSG dm1[41378]: GDKrealloc(77309411344) fails, try to free up space [memory in use=55506520984,virtual memory in use=138389506968] 2012-03-12 23:34:43 MSG dm1[41378]: GDKrealloc(77309411344) result [mem=55506520984,vm=138389506968] 2012-03-12 23:34:44 MSG merovingian[1986]: database 'dm1' (41378) has exited with exit status 0 2012-03-12 23:34:44 MSG merovingian[1986]: database 'dm1' has shut down 2012-03-12 23:34:44 MSG control[1986]: (local): stopped database 'dm1' 2012-03-12 23:34:46 MSG control[1986]: (local): served status list 2012-03-12 23:34:46 MSG merovingian[1986]: starting database 'dm1', up min/avg/max: 4s/9h/4d, crash average: 0.00 0.20 0.13 (30-26=4) 2012-03-12 23:34:47 MSG dm1[41715]: arguments: /usr/bin/mserver5 --set gdk_dbfarm=/data02/MonetDB --dbname=dm1 --set merovingian_uri=mapi:monetdb://monetdbtest.lmuk.local:50000/dm1 --set mapi_open=false --set mapi_port=0 --set mapi_usock=/data02/MonetDB/dm1/.mapi.sock --set monet_vault_key=/data02/MonetDB/dm1/.vaultkey --set gdk_nr_threads=32 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes 2012-03-12 23:34:57 MSG merovingian[1986]: sending process 41715 (database 'dm1') the TERM signal 2012-03-12 23:34:57 MSG merovingian[1986]: database 'dm1' (41715) has exited with exit status 15 2012-03-12 23:34:57 MSG merovingian[1986]: database 'dm1' has shut down 2012-03-12 23:34:57 ERR control[1986]: (local): failed to fork mserver: timeout while waiting for database 'dm1' to open up a communication channel 2012-03-12 23:34:59 MSG control[1986]: (local): served status list 2012-03-12 23:34:59 ERR control[1986]: (local): received stop signal for non running database: dm1 2012-03-12 23:35:00 MSG control[1986]: (local): served status list 2012-03-12 23:35:00 ERR control[1986]: (local): received stop signal for non running database: dm1 2012-03-12 23:35:03 MSG control[1986]: (local): served status list 2012-03-12 23:35:03 MSG merovingian[1986]: starting database 'dm1', up min/avg/max: 4s/9h/4d, crash average: 0.00 0.20 0.13 (30-26=4) 2012-03-12 23:35:04 MSG dm1[41719]: arguments: /usr/bin/mserver5 --set gdk_dbfarm=/data02/MonetDB --dbname=dm1 --set merovingian_uri=mapi:monetdb://monetdbtest.lmuk.local:50000/dm1 --set mapi_open=false --set mapi_port=0 --set mapi_usock=/data02/MonetDB/dm1/.mapi.sock --set monet_vault_key=/data02/MonetDB/dm1/.vaultkey --set gdk_nr_threads=32 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes 2012-03-12 23:35:15 MSG merovingian[1986]: sending process 41719 (database 'dm1') the TERM signal 2012-03-12 23:35:15 MSG merovingian[1986]: database 'dm1' (41719) has exited with exit status 15 2012-03-12 23:35:15 MSG merovingian[1986]: database 'dm1' has shut down 2012-03-12 23:35:15 ERR control[1986]: (local): failed to fork mserver: timeout while waiting for database 'dm1' to open up a communication channel 2012-03-12 23:36:08 MSG control[1986]: (local): served status list 2012-03-12 23:36:08 MSG merovingian[1986]: starting database 'dm1', up min/avg/max: 4s/9h/4d, crash average: 0.00 0.20 0.13 (30-26=4) 2012-03-12 23:36:09 MSG dm1[41857]: arguments: /usr/bin/mserver5 --set gdk_dbfarm=/data02/MonetDB --dbname=dm1 --set merovingian_uri=mapi:monetdb://monetdbtest.lmuk.local:50000/dm1 --set mapi_open=false --set mapi_port=0 --set mapi_usock=/data02/MonetDB/dm1/.mapi.sock --set monet_vault_key=/data02/MonetDB/dm1/.vaultkey --set gdk_nr_threads=32 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes 2012-03-12 23:36:18 MSG merovingian[1986]: sending process 41857 (database 'dm1') the TERM signal 2012-03-12 23:36:18 MSG merovingian[1986]: database 'dm1' (41857) has exited with exit status 15 2012-03-12 23:36:18 MSG merovingian[1986]: database 'dm1' has shut down 2012-03-12 23:36:18 ERR control[1986]: (local): failed to fork mserver: timeout while waiting for database 'dm1' to open up a communication channel 2012-03-12 23:40:29 MSG control[1986]: (local): served status list 2012-03-12 23:40:29 MSG merovingian[1986]: starting database 'dm1', up min/avg/max: 4s/9h/4d, crash average: 0.00 0.20 0.13 (30-26=4) 2012-03-12 23:40:30 MSG dm1[41860]: arguments: /usr/bin/mserver5 --set gdk_dbfarm=/data02/MonetDB --dbname=dm1 --set merovingian_uri=mapi:monetdb://monetdbtest.lmuk.local:50000/dm1 --set mapi_open=false --set mapi_port=0 --set mapi_usock=/data02/MonetDB/dm1/.mapi.sock --set monet_vault_key=/data02/MonetDB/dm1/.vaultkey --set gdk_nr_threads=32 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes 2012-03-12 23:40:30 MSG dm1[41860]: MonetDB 5 server v11.11.5 "Jul2012" 2012-03-12 23:40:30 MSG dm1[41860]: Serving database 'dm1', using 32 threads 2012-03-12 23:40:30 MSG dm1[41860]: Compiled for x86_64-unknown-linux-gnu/64bit with 64bit OIDs dynamically linked 2012-03-12 23:40:30 MSG dm1[41860]: Found 62.885 GiB available main-memory. 2012-03-12 23:40:30 MSG dm1[41860]: Copyright (c) 1993-July 2008 CWI. 2012-03-12 23:40:30 MSG dm1[41860]: Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved 2012-03-12 23:40:30 MSG dm1[41860]: Visit http://www.monetdb.org/ for further information 2012-03-12 23:40:30 MSG dm1[41860]: Listening for UNIX domain connection requests on mapi:monetdb:///data02/MonetDB/dm1/.mapi.sock 2012-03-12 23:40:30 MSG dm1[41860]: MonetDB/GIS module loaded 2012-03-12 23:40:30 MSG dm1[41860]: MonetDB/JAQL module loaded 2012-03-12 23:40:30 MSG dm1[41860]: MonetDB/SQL module loaded 2012-03-12 23:40:30 MSG control[1986]: (local): started 'dm1' ## Comment 17581 Date: 2012-07-27 18:00:44 +0200 From: Ivan Zolotuhin &lt;<ivanzolotuhin>&gt; It what shows strace during unsuccesfull operation browse content in SquirrelSQL. Not sure what command SquirrelSQL send during this operation. SELECT * FROM table? Is it possible to check history of all queries via JDBC/ODBC in MonetDB? [root@monet ~] strace -p 16409 -F Process 16409 attached with 4 threads - interrupt to quit [pid 16412] select(21, [20], NULL, NULL, {1, 99681} <unfinished ...> [pid 16411] select(22, [21], NULL, NULL, {3, 951858} <unfinished ...> [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {0, 909703} <unfinished ...> [pid 16409] select(20, [17 19], NULL, NULL, {0, 826666}) = 0 (Timeout) [pid 16409] select(20, [17 19], NULL, NULL, {5, 0} <unfinished ...> [pid 16410] <... select resumed> ) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0} <unfinished ...> [pid 16412] <... select resumed> ) = 0 (Timeout) [pid 16412] select(21, [20], NULL, NULL, {5, 0} <unfinished ...> [pid 16410] <... select resumed> ) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0}) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0}) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0} <unfinished ...> [pid 16411] <... select resumed> ) = 0 (Timeout) [pid 16411] select(22, [21], NULL, NULL, {5, 0} <unfinished ...> [pid 16410] <... select resumed> ) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0} <unfinished ...> [pid 16409] <... select resumed> ) = 0 (Timeout) [pid 16409] select(20, [17 19], NULL, NULL, {5, 0} <unfinished ...> [pid 16410] <... select resumed> ) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0} <unfinished ...> [pid 16412] <... select resumed> ) = 0 (Timeout) [pid 16412] select(21, [20], NULL, NULL, {5, 0} <unfinished ...> [pid 16410] <... select resumed> ) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0}) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0}) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0} <unfinished ...> [pid 16411] <... select resumed> ) = 0 (Timeout) [pid 16411] select(22, [21], NULL, NULL, {5, 0} <unfinished ...> [pid 16410] <... select resumed> ) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0} <unfinished ...> [pid 16409] <... select resumed> ) = 0 (Timeout) [pid 16409] select(20, [17 19], NULL, NULL, {5, 0} <unfinished ...> [pid 16410] <... select resumed> ) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0} <unfinished ...> [pid 16412] <... select resumed> ) = 0 (Timeout) [pid 16412] select(21, [20], NULL, NULL, {5, 0} <unfinished ...> [pid 16410] <... select resumed> ) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0}) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0}) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0} <unfinished ...> [pid 16411] <... select resumed> ) = 0 (Timeout) [pid 16411] select(22, [21], NULL, NULL, {5, 0} <unfinished ...> [pid 16410] <... select resumed> ) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0} <unfinished ...> [pid 16409] <... select resumed> ) = 0 (Timeout) [pid 16409] select(20, [17 19], NULL, NULL, {5, 0} <unfinished ...> [pid 16410] <... select resumed> ) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0} <unfinished ...> [pid 16412] <... select resumed> ) = 0 (Timeout) [pid 16412] select(21, [20], NULL, NULL, {5, 0} <unfinished ...> [pid 16410] <... select resumed> ) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0}) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0}) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0} <unfinished ...> [pid 16411] <... select resumed> ) = 0 (Timeout) [pid 16411] select(22, [21], NULL, NULL, {5, 0} <unfinished ...> [pid 16410] <... select resumed> ) = 0 (Timeout) [pid 16410] select(31, [6 7 8 11 13 15 23 30], NULL, NULL, {1, 0} <unfinished ...> [pid 16409] <... select resumed> ) = 0 (Timeout) ## Comment 17582 Date: 2012-07-27 18:08:46 +0200 From: @mlkersten SquirrelSQL most likely sends updates one-by-one as individual transactions. This creates a large delta table (log file), which is merged upon system restart. That could explain the delay. ## Comment 17586 Date: 2012-07-30 15:56:08 +0200 From: Ivan Zolotuhin &lt;<ivanzolotuhin>&gt; I have installed Toad for Data Analysts. (It is what analysts use in our company) Similar behavior. When trying to browse content it loads one core 100%. In Toad log it shows that it runs "SELECT * FROM schema.table". And after killing Toad (log off from remote RDP session) cpu still 100% in use. Not sure that it is expected behaviour. Is it possible somehow to deny execution via ODBC queries like this or to automatically add "LIMIT 100000" for example". [root@aimiapersot ~] monetdb start dm1 starting database 'dm1'... FAILED start: starting 'dm1' failed: timeout while waiting for database 'dm1' to open up a communication channel [root@aimiapersot ~] sync && echo 3 > /proc/sys/vm/drop_caches [root@aimiapersot ~] monetdb start dm1 starting database 'dm1'... done [root@aimiapersot ~] 2012-07-30 14:44:32 MSG merovingian[53840]: target connection is on local UNIX domain socket, passing on filedescriptor instead of proxying 2012-07-30 14:46:47 MSG merovingian[53840]: proxying client (local) for database 'dm1' to mapi:monetdb:///data02/MonetDB/dm1/.mapi.sock?database=dm1 2012-07-30 14:46:47 MSG merovingian[53840]: target connection is on local UNIX domain socket, passing on filedescriptor instead of proxying 2012-07-30 14:46:47 MSG merovingian[53840]: proxying client (local) for database 'dm1' to mapi:monetdb:///data02/MonetDB/dm1/.mapi.sock?database=dm1 2012-07-30 14:46:47 MSG merovingian[53840]: target connection is on local UNIX domain socket, passing on filedescriptor instead of proxying 2012-07-30 14:48:15 MSG control[53840]: (local): served status list 2012-07-30 14:48:16 MSG merovingian[53840]: sending process 16677 (database 'dm1') the TERM signal 2012-07-30 14:48:16 MSG merovingian[53840]: database 'dm1' has shut down 2012-07-30 14:48:16 MSG control[53840]: (local): stopped database 'dm1' 2012-07-30 14:48:17 MSG merovingian[53840]: database 'dm1' (16677) has exited with exit status 0 2012-07-30 14:49:24 MSG control[53840]: (local): served status list 2012-07-30 14:49:24 MSG merovingian[53840]: starting database 'dm1', up min/avg/max: 3s/10h/4d, crash average: 0.00 0.00 0.10 (36-32=4) 2012-07-30 14:49:25 MSG dm1[16821]: arguments: /usr/bin/mserver5 --set gdk_dbfarm=/data02/MonetDB --dbname=dm1 --set merovingian_uri=mapi:monetdb://aimiapersot.lmuk.local:50000/dm1 --set mapi_open=false --set mapi_port=0 --set mapi_usock=/data02/MonetDB/dm1/.mapi.sock --set monet_vault_key=/data02/MonetDB/dm1/.vaultkey --set gdk_nr_threads=32 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes 2012-07-30 14:49:36 MSG merovingian[53840]: sending process 16821 (database 'dm1') the TERM signal 2012-07-30 14:49:36 MSG merovingian[53840]: database 'dm1' (16821) has exited with exit status 15 2012-07-30 14:49:36 MSG merovingian[53840]: database 'dm1' has shut down 2012-07-30 14:49:36 ERR control[53840]: (local): failed to fork mserver: timeout while waiting for database 'dm1' to open up a communication channel 2012-07-30 14:53:25 MSG control[53840]: (local): served status list 2012-07-30 14:53:25 MSG merovingian[53840]: starting database 'dm1', up min/avg/max: 3s/10h/4d, crash average: 0.00 0.00 0.10 (36-32=4) 2012-07-30 14:53:26 MSG dm1[16826]: arguments: /usr/bin/mserver5 --set gdk_dbfarm=/data02/MonetDB --dbname=dm1 --set merovingian_uri=mapi:monetdb://aimiapersot.lmuk.local:50000/dm1 --set mapi_open=false --set mapi_port=0 --set mapi_usock=/data02/MonetDB/dm1/.mapi.sock --set monet_vault_key=/data02/MonetDB/dm1/.vaultkey --set gdk_nr_threads=32 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes 2012-07-30 14:53:36 MSG merovingian[53840]: sending process 16826 (database 'dm1') the TERM signal 2012-07-30 14:53:36 MSG merovingian[53840]: database 'dm1' (16826) has exited with exit status 15 2012-07-30 14:53:36 MSG merovingian[53840]: database 'dm1' has shut down 2012-07-30 14:53:36 ERR control[53840]: (local): failed to fork mserver: timeout while waiting for database 'dm1' to open up a communication channel 2012-07-30 14:54:38 MSG control[53840]: (local): served status list 2012-07-30 14:54:38 MSG merovingian[53840]: starting database 'dm1', up min/avg/max: 3s/10h/4d, crash average: 0.00 0.00 0.10 (36-32=4) 2012-07-30 14:54:39 MSG dm1[16837]: arguments: /usr/bin/mserver5 --set gdk_dbfarm=/data02/MonetDB --dbname=dm1 --set merovingian_uri=mapi:monetdb://aimiapersot.lmuk.local:50000/dm1 --set mapi_open=false --set mapi_port=0 --set mapi_usock=/data02/MonetDB/dm1/.mapi.sock --set monet_vault_key=/data02/MonetDB/dm1/.vaultkey --set gdk_nr_threads=32 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes 2012-07-30 14:54:46 MSG dm1[16837]: MonetDB 5 server v11.11.5 "Jul2012" 2012-07-30 14:54:46 MSG dm1[16837]: Serving database 'dm1', using 32 threads 2012-07-30 14:54:46 MSG dm1[16837]: Compiled for x86_64-unknown-linux-gnu/64bit with 64bit OIDs dynamically linked 2012-07-30 14:54:46 MSG dm1[16837]: Found 63.072 GiB available main-memory. 2012-07-30 14:54:46 MSG dm1[16837]: Copyright (c) 1993-July 2008 CWI. 2012-07-30 14:54:46 MSG dm1[16837]: Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved 2012-07-30 14:54:46 MSG dm1[16837]: Visit http://www.monetdb.org/ for further information 2012-07-30 14:54:46 MSG dm1[16837]: Listening for UNIX domain connection requests on mapi:monetdb:///data02/MonetDB/dm1/.mapi.sock 2012-07-30 14:54:46 MSG dm1[16837]: MonetDB/JAQL module loaded 2012-07-30 14:54:46 MSG dm1[16837]: MonetDB/SQL module loaded 2012-07-30 14:54:46 MSG control[53840]: (local): started 'dm1' ## Comment 17605 Date: 2012-08-03 09:53:49 +0200 From: @grobian I believe this is in fact a duplicate of bug #3134, monetdbd doesn't wait long enough for the database to process its write ahead log, for which I have committed a fix yesterday. *** This bug has been marked as a duplicate of bug #3134 *** ## Comment 17610 Date: 2012-08-03 14:03:49 +0200 From: Ivan Zolotuhin &lt;<ivanzolotuhin>&gt; Thank you. Seems like fixed for me (no previous error, but right after stopping database it still unable to start it, should wait for minute (+/-) Is it expected behaviour now? Does MonetDB does any kind of work after stopping database? If yes may be modify it somehow like process of stopping MySQL that it writes "stopped" after all work done (but stopping database it is usually takes long time, but it is more verbose). [root@server ~] monetdb start dm1 starting database 'dm1'... FAILED start: starting 'dm1' failed: database 'dm1' started up, but failed to open up a communication channel [root@server ~] monetdb start dm1 starting database 'dm1'... FAILED start: starting 'dm1' failed: database 'dm1' started up, but failed to open up a communication channel [root@server ~] monetdb start dm1 starting database 'dm1'... done [root@server ~] 2012-08-03 12:51:18 MSG merovingian[38771]: sending process 39377 (database 'dm1') the TERM signal 2012-08-03 12:51:18 MSG dm1[39377]: arguments: /usr/bin/mserver5 --set gdk_dbfarm=/data02/MonetDB --dbname=dm1 --set merovingian_uri=mapi:monetdb://aimiapersot.lmuk.local:50000/dm1 --set mapi_open=false --set mapi_port=0 --set mapi_usock=/data02/MonetDB/dm1/.mapi.sock --set monet_vault_key=/data02/MonetDB/dm1/.vaultkey --set gdk_nr_threads=32 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes 2012-08-03 12:51:19 MSG merovingian[38771]: database 'dm1' (39377) has exited with exit status 15 2012-08-03 12:51:19 MSG merovingian[38771]: database 'dm1' has shut down 2012-08-03 12:51:19 ERR control[38771]: (local): failed to fork mserver: database 'dm1' started up, but failed to open up a communication channel 2012-08-03 12:51:21 MSG control[38771]: (local): served status list 2012-08-03 12:51:21 ERR control[38771]: (local): received stop signal for non running database: dm1 2012-08-03 12:51:22 MSG control[38771]: (local): served status list 2012-08-03 12:51:22 ERR control[38771]: (local): received stop signal for non running database: dm1 2012-08-03 12:51:26 MSG control[38771]: (local): served status list 2012-08-03 12:51:27 MSG control[38771]: (local): served status list 2012-08-03 12:51:36 MSG control[38771]: (local): served status list 2012-08-03 12:51:38 MSG control[38771]: (local): served status list 2012-08-03 12:51:38 MSG merovingian[38771]: starting database 'dm1', up min/avg/max: 0s/11h/4d, crash average: 0.00 0.00 0.07 (41-37=4) 2012-08-03 12:51:39 MSG merovingian[38771]: sending process 39384 (database 'dm1') the TERM signal 2012-08-03 12:51:39 MSG dm1[39384]: arguments: /usr/bin/mserver5 --set gdk_dbfarm=/data02/MonetDB --dbname=dm1 --set merovingian_uri=mapi:monetdb://aimiapersot.lmuk.local:50000/dm1 --set mapi_open=false --set mapi_port=0 --set mapi_usock=/data02/MonetDB/dm1/.mapi.sock --set monet_vault_key=/data02/MonetDB/dm1/.vaultkey --set gdk_nr_threads=32 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes 2012-08-03 12:51:39 MSG merovingian[38771]: database 'dm1' (39384) has exited with exit status 15 2012-08-03 12:51:39 MSG merovingian[38771]: database 'dm1' has shut down 2012-08-03 12:51:39 ERR control[38771]: (local): failed to fork mserver: database 'dm1' started up, but failed to open up a communication channel 2012-08-03 12:51:47 MSG control[38771]: (local): served status list 2012-08-03 12:51:47 MSG merovingian[38771]: starting database 'dm1', up min/avg/max: 0s/11h/4d, crash average: 0.00 0.00 0.07 (41-37=4) 2012-08-03 12:51:48 MSG merovingian[38771]: sending process 39393 (database 'dm1') the TERM signal 2012-08-03 12:51:48 MSG dm1[39393]: arguments: /usr/bin/mserver5 --set gdk_dbfarm=/data02/MonetDB --dbname=dm1 --set merovingian_uri=mapi:monetdb://aimiapersot.lmuk.local:50000/dm1 --set mapi_open=false --set mapi_port=0 --set mapi_usock=/data02/MonetDB/dm1/.mapi.sock --set monet_vault_key=/data02/MonetDB/dm1/.vaultkey --set gdk_nr_threads=32 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes 2012-08-03 12:52:48 ERR merovingian[38771]: timeout of 60 seconds expired, sending process 39393 (database 'dm1') the KILL signal 2012-08-03 12:52:48 ERR control[38771]: (local): failed to fork mserver: database 'dm1' started up, but failed to open up a communication channel 2012-08-03 12:52:48 MSG merovingian[38771]: database 'dm1' (39393) was killed by signal SIGKILL 2012-08-03 12:52:52 MSG control[38771]: (local): served status list 2012-08-03 12:52:52 MSG merovingian[38771]: database 'dm1' has crashed after start on 2012-08-03 12:51:48, attempting restart, up min/avg/max: 0s/11h/4d, crash average: 1.00 0.10 0.10 (42-37=5) 2012-08-03 12:52:52 MSG control[38771]: (local): started 'dm1' 2012-08-03 12:52:52 MSG dm1[39397]: arguments: /usr/bin/mserver5 --set gdk_dbfarm=/data02/MonetDB --dbname=dm1 --set merovingian_uri=mapi:monetdb://aimiapersot.lmuk.local:50000/dm1 --set mapi_open=false --set mapi_port=0 --set mapi_usock=/data02/MonetDB/dm1/.mapi.sock --set monet_vault_key=/data02/MonetDB/dm1/.vaultkey --set gdk_nr_threads=32 --set max_clients=64 --set sql_optimizer=default_pipe --set monet_daemon=yes 2012-08-03 12:52:52 MSG dm1[39397]: MonetDB 5 server v11.11.5 "Jul2012" 2012-08-03 12:52:52 MSG dm1[39397]: Serving database 'dm1', using 32 threads 2012-08-03 12:52:52 MSG dm1[39397]: Compiled for x86_64-unknown-linux-gnu/64bit with 64bit OIDs dynamically linked 2012-08-03 12:52:52 MSG dm1[39397]: Found 63.072 GiB available main-memory. 2012-08-03 12:52:52 MSG dm1[39397]: Copyright (c) 1993-July 2008 CWI. 2012-08-03 12:52:52 MSG dm1[39397]: Copyright (c) August 2008-2012 MonetDB B.V., all rights reserved 2012-08-03 12:52:52 MSG dm1[39397]: Visit http://www.monetdb.org/ for further information 2012-08-03 12:52:52 MSG dm1[39397]: Listening for UNIX domain connection requests on mapi:monetdb:///data02/MonetDB/dm1/.mapi.sock 2012-08-03 12:52:52 MSG dm1[39397]: MonetDB/JAQL module loaded 2012-08-03 12:52:52 MSG dm1[39397]: MonetDB/SQL module loaded ## Comment 17611 Date: 2012-08-03 14:09:41 +0200 From: @grobian you'll need [642a58298ed5](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=642a58298ed5) as well, monetdbd used to return too early it was done starting The log you just posted actually suggests you're on Jul2012, so no fixes included.
start: starting 'dm1' failed: timeout while waiting for database 'dm1' to open up a communication channel
https://api.github.com/repos/MonetDB/MonetDB/issues/3133/comments
0
2020-11-30T12:12:38Z
2024-06-28T13:18:30Z
https://github.com/MonetDB/MonetDB/issues/3133
753,426,662
3,133
[ "MonetDB", "MonetDB" ]
Date: 2012-07-24 19:40:19 +0200 From: @grobian To: SQL devs &lt;<bugs-sql>&gt; Version: 11.11.5 (Jul2012) CC: @drstmane Last updated: 2012-08-23 10:14:40 +0200 ## Comment 17566 Date: 2012-07-24 19:40:19 +0200 From: @grobian http://monetdb.cwi.nl/testweb/web/testchange.php?test=44753:7968805ec43d/GNU-Darwin-x86_64-propcheck/sql/mTests/test/BugTracker-2011/func_iter_vs_bulk.Bug-2826 last ok on default was 44062:8fc883b7fdef Merge from Apr2012 Apr2012 branch suggests the test never ran correctly: http://monetdb.cwi.nl/testweb/web/testchange.php?test=44466:6cd986132b9e/GNU-Darwin-x86_64-propcheck/sql/mTests/test/BugTracker-2011/func_iter_vs_bulk.Bug-2826 ## Comment 17569 Date: 2012-07-25 10:01:57 +0200 From: @drstmane This is a known difference, i.e., variable IDs for barriers appear to differ between systems, but I/we could not recognize a simple pattern, yet; hence, they are treated as "minor differences". ## Comment 17571 Date: 2012-07-25 11:06:30 +0200 From: @grobian this output seems to depend on the number of cores the system has available ## Comment 17573 Date: 2012-07-25 15:47:33 +0200 From: @drstmane Changeset [93446c850c0a](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=93446c850c0a) made by Stefan Manegold <Stefan.Manegold@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=93446c850c0a](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=93446c850c0a) Changeset description: func_iter_vs_bulk.Bug-2826: use sequential pipeline to ensure deterministic output also on multi-core systems This fixes bug #3132. ## Comment 17642 Date: 2012-08-23 10:14:40 +0200 From: @sjoerdmullender Jul2012-SP1 has been released.
test/BugTracker-2011/func_iter_vs_bulk.Bug-2826 fails
https://api.github.com/repos/MonetDB/MonetDB/issues/3132/comments
0
2020-11-30T12:12:35Z
2024-06-27T11:57:16Z
https://github.com/MonetDB/MonetDB/issues/3132
753,426,623
3,132
[ "MonetDB", "MonetDB" ]
Date: 2012-07-24 08:49:34 +0200 From: @drstmane To: MonetDB5 devs &lt;<bugs-monetdb5>&gt; Version: -- development CC: @yzchang Last updated: 2012-11-27 13:20:40 +0100 ## Comment 17559 Date: 2012-07-24 08:49:34 +0200 From: @drstmane Test monetdb5/modules/mal/Tests/xidlist.mal fails with: mserver5: .../MonetDB/gdk/gdk_bat.c:2910: BATassertHeadProps: Assertion `!b->H->revsorted || cmp >= 0' failed. I.e., the "revsorted" property is not set correctly (i.e., set while it does not hold) for some BAT (possibly created by module "xid"). cf., http://monetdb.cwi.nl/testweb/tests/44753:7968805ec43d/GNU-Fedora-x86_64-propcheck-assert/monetdb5/mTests/modules/mal/xidlist.err.diff.html ## Comment 17560 Date: 2012-07-24 08:54:40 +0200 From: @drstmane I suspect that unconditionally copying all properties from an uncompressed oid column to a compressed xid column, and vice versa, is not generally correct. ## Comment 17568 Date: 2012-07-25 00:28:12 +0200 From: @drstmane Fixed in "xid" branch by changesets [6d504fd277af](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=6d504fd277af) [805110fd0096](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=805110fd0096) [b33eba6cfb09](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=b33eba6cfb09) ## Comment 17570 Date: 2012-07-25 10:06:18 +0200 From: @drstmane fixed refined in changesets [14d241bcb5d7](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=14d241bcb5d7) & [4da710a71d6f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=4da710a71d6f) ## Comment 18050 Date: 2012-11-27 13:20:40 +0100 From: @yzchang This is about an existing test monetdb5/modules/mal/Tests/xidlist.mal
test "xidlist": Assertion `!b->H->revsorted || cmp >= 0' failed.
https://api.github.com/repos/MonetDB/MonetDB/issues/3131/comments
0
2020-11-30T12:12:33Z
2024-06-27T11:57:15Z
https://github.com/MonetDB/MonetDB/issues/3131
753,426,603
3,131
[ "MonetDB", "MonetDB" ]
Date: 2012-07-24 08:40:22 +0200 From: @drstmane To: MonetDB5 devs &lt;<bugs-monetdb5>&gt; Version: -- development CC: @mlkersten, @yzchang Last updated: 2012-11-27 13:21:24 +0100 ## Comment 17558 Date: 2012-07-24 08:40:22 +0200 From: @drstmane The new "xid" module fails to compile on all Windows platforms we test as well as on most unix-like platforms except 64-bit with 64-bit OIDs; see links below. This is mainly due to three reasons: 1) Type "long" is variable length (32-or 64- bit), thus a hard-wired bit battern of 3 + 61 bits does not fit in case long is 32. In fact, it is highly system-/compiler-dependent and everything but obvious, let alone standard, whether long is 32- or 64-bit (e.g., on 64-bit Windows, long is "only" 32-bit). Consequently, in MonetDB we generally refrain from using type long, and rather resort to types size_t & ssize_t (respectively wrd & oid) for, respectively, unsigned and signed integer types that predictably and consistently vary between 32-bit on 32-bit architectures and 64-bit on 64-bit architectures. Please note that on 64-bit systems type oid can be chosen to be 32-bit at MonetDB configure-/compile-time. Consequently, in the new "xid" module, type long must be replaced by on of the above. Given the purpose of xid, I assume type oid is the natural choice. 2) For non-basic integer (and other) types (i.e., any type but char, short, & int), format strings are not necessarily standardized across platforms. Consequently, for these types, including size_t, ssize_t, wrd, oid (and long if we did not refrain from using it), we need to use our own "standardized" (within the MonetDB code base) format string macros: respectively, SZFMT, SSZFMT, SSZFMT, OIDFMT (given that we do not use type long, there is no format string macro for it). 3) Assigning a 64-bit lng to a possibly 32-bit long (or size_t, ssize_t, wrd, oid) fails due to a potential overflow (loss of significant bits and thus data). In case such assignment cannot be avoided, and an overflow has been excluded (e.g., by a suitable check or assertion), a proper typecast needs to be used. cf., http://monetdb.cwi.nl/testweb/web/status.php?branch=default&n=5&order=platform%2Carch%2Ccompiler&submit=refresh http://monetdb.cwi.nl/testweb/logs/44753:7968805ec43d/GNU-Darwin-i386-propcheck/make.htmll1046 http://monetdb.cwi.nl/testweb/logs/44753:7968805ec43d/GNU-Darwin-powerpc/make.htmll1042 http://monetdb.cwi.nl/testweb/logs/44753:7968805ec43d/GNU-Fedora-i386-propcheck/make.htmll1050 http://monetdb.cwi.nl/testweb/logs/44753:7968805ec43d/GNU-Fedora-x86_64-propcheck-oid32/make.htmll1047 http://monetdb.cwi.nl/testweb/logs/44753:7968805ec43d/GNU-Gentoo-powerpc-propcheck/make.htmll1049 http://monetdb.cwi.nl/testweb/logs/44753:7968805ec43d/GNU-Solaris-sparc/make.htmll1049 http://monetdb.cwi.nl/testweb/logs/44753:7968805ec43d/GNU-Solaris-sparcv9-oid32/make.htmll1041 http://monetdb.cwi.nl/testweb/logs/44753:7968805ec43d/GNU-Ubuntu-i386-propcheck/make.htmll1047 http://monetdb.cwi.nl/testweb/logs/44753:7968805ec43d/Int-WindowsXP-i386-propcheck/make.htmll1366 http://monetdb.cwi.nl/testweb/logs/44753:7968805ec43d/Mic-Windows2008-i386-propcheck-installer/make.htmll1399 http://monetdb.cwi.nl/testweb/logs/44753:7968805ec43d/Int-Windows2008-x86_64-propcheck-oid32/make.htmll1359 http://monetdb.cwi.nl/testweb/logs/44753:7968805ec43d/Mic-Windows7-x86_64-propcheck-oid32-installer/make.htmll1405 http://monetdb.cwi.nl/testweb/logs/44753:7968805ec43d/Int-Windows7-x86_64-propcheck/make.htmll1366 http://monetdb.cwi.nl/testweb/logs/44753:7968805ec43d/Mic-Windows2008-x86_64-propcheck-installer/make.htmll1404 ## Comment 17563 Date: 2012-07-24 11:11:58 +0200 From: @drstmane For the records, "xid" related changes comprise changeset [3e3beae5932c](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=3e3beae5932c) [75375e1015a5](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=75375e1015a5) [5a7e0071e980](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=5a7e0071e980) [cde1783a60e0](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=cde1783a60e0) [7968805ec43d](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=7968805ec43d) ## Comment 17564 Date: 2012-07-24 11:16:07 +0200 From: @mlkersten Yes, all is packed in a well-identified collection of patches. and yes, my first concern was platform compilation issues. The code could be made to work with both 32 and 64 bits and, yes, (un)packing calls for proper compiler directives. Yes, doing (de)compression over heaps will be tricky, because under the hood, the heap does *not hold a list of OIDs in the traditional sense anymore*. Between the Z:= compress(B) and B:= decompress(Z) Z should not be used as an ordinary BAT, because it isn't. However, to make sure that after decompression the properties are set to the original state, calls for the blind copying. One 'hack' until we know if the approach makes sense is to check for xidcompressed flags and skip testing properties. A prospect of the experiment is to support other data type compressions as well, where the column is decompressed upon first use (e.g. the bind) or (longer term) apply operations, e.g. select, directly to a compressed column. We know that in airtraffic and skyserver there are many columns with essential a default (error) value. The same will hold for the array world. These would be aided with a runlength encoding. Overall, this is an experimental step, first aimed at seeing if we can reduce the footprint of the intermediates. ## Comment 17567 Date: 2012-07-25 00:26:15 +0200 From: @drstmane For 64-bit Linux using both 64-bit 7 32-bit OIDs and both gcc & icc, the code has been fixed in the "xid" branch. Testing on other platforms is pending. ## Comment 17589 Date: 2012-08-01 14:13:05 +0200 From: @drstmane Fixed code appears to compile on all out testing platforms: http://monetdb.cwi.nl/testweb/web/status.php?branch=xid&n=5&order=platform%2Carch%2Ccompiler&submit=refresh ## Comment 18051 Date: 2012-11-27 13:21:24 +0100 From: @yzchang Compilation issue, no need to add a test
new "xid" module breaks compilation & portability
https://api.github.com/repos/MonetDB/MonetDB/issues/3130/comments
0
2020-11-30T12:12:31Z
2024-06-27T11:57:14Z
https://github.com/MonetDB/MonetDB/issues/3130
753,426,576
3,130
[ "MonetDB", "MonetDB" ]
Date: 2012-07-20 21:48:39 +0200 From: @drstmane To: SQL devs &lt;<bugs-sql>&gt; Version: -- development Last updated: 2012-08-01 14:20:48 +0200 ## Comment 17538 Date: 2012-07-20 21:48:39 +0200 From: @drstmane Only with multi-threaded server, test sql/test/testdb/Tests/testdb-dump.sql fails with ERROR = !GDK reported error.can not find element cf., http://monetdb.cwi.nl/testweb/web/testgrid.php?serial=44702:17e97402292f&order=platform,arch,compiler&targets=&module=sql&tstlimit=test/testdb http://monetdb.cwi.nl/testweb/tests/44702:17e97402292f/GNU-Fedora-x86_64-propcheck-assert/sql/mTests/test/testdb/testdb-dump.err.diff.html See also bug #3128 ## Comment 17592 Date: 2012-08-01 14:20:48 +0200 From: @drstmane fixed by changeset [3db75b2ec791](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=3db75b2ec791)
testdb-dump test fails with "can not find element", only when multi-threaded
https://api.github.com/repos/MonetDB/MonetDB/issues/3129/comments
0
2020-11-30T12:12:28Z
2024-06-27T11:57:13Z
https://github.com/MonetDB/MonetDB/issues/3129
753,426,552
3,129
[ "MonetDB", "MonetDB" ]
Date: 2012-07-20 21:43:06 +0200 From: @drstmane To: MonetDB5 devs &lt;<bugs-monetdb5>&gt; Version: -- development CC: @yzchang Last updated: 2012-11-27 13:21:58 +0100 ## Comment 17536 Date: 2012-07-20 21:43:06 +0200 From: @drstmane Since changeset [657e04cdaf74](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=657e04cdaf74) test monetdb5/tests/gdkTests/Tests/void.mal fails with !MALException:algebra.find:GDK reported error.can not find element ## Comment 17537 Date: 2012-07-20 21:43:38 +0200 From: @drstmane (In reply to comment 0) > Since changeset [657e04cdaf74](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=657e04cdaf74) cf., http://dev.monetdb.org/hg/MonetDB/rev/657e04cdaf74 > test monetdb5/tests/gdkTests/Tests/void.mal > fails with > !MALException:algebra.find:GDK reported error.can not find element ## Comment 17539 Date: 2012-07-20 21:48:58 +0200 From: @drstmane see also bug #3129 ## Comment 17540 Date: 2012-07-21 07:21:12 +0200 From: @drstmane cf., http://monetdb.cwi.nl/testweb/web/testgrid.php?serial=44732:ee63516d78f5&order=platform,arch,compiler&targets=&module=monetdb5&tstlimit=tests/gdkTests http://monetdb.cwi.nl/testweb/tests/44732:ee63516d78f5/GNU-Fedora-x86_64-propcheck-assert/monetdb5/mTests/tests/gdkTests/void.out.diff.html ## Comment 17594 Date: 2012-08-01 15:48:52 +0200 From: @drstmane Test appears to work fine, again since changeset [8f632a9fa242](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=8f632a9fa242) ## Comment 18052 Date: 2012-11-27 13:21:58 +0100 From: @yzchang This is about an existing test monetdb5/tests/gdkTests/Tests/void.mal
gdkTests.void fails since changeset 657e04cdaf74 with "can not find element"
https://api.github.com/repos/MonetDB/MonetDB/issues/3128/comments
0
2020-11-30T12:12:26Z
2024-06-27T11:57:12Z
https://github.com/MonetDB/MonetDB/issues/3128
753,426,529
3,128
[ "MonetDB", "MonetDB" ]
Date: 2012-07-20 09:31:26 +0200 From: @drstmane To: MonetDB5 devs &lt;<bugs-monetdb5>&gt; Version: -- development CC: @yzchang Last updated: 2012-11-27 13:22:34 +0100 ## Comment 17522 Date: 2012-07-20 09:31:26 +0200 From: @drstmane Test monetdb5/modules/mal/Tests/modulechk.mal has been failing even since it has been introduced with changeset [95370bb07d9f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=95370bb07d9f) "Iterator semantics changes" (!?) (http://dev.monetdb.org/hg/MonetDB/rev/95370bb07d9f); cf., http://monetdb.cwi.nl/testweb/web/testgrid.php?serial=44702:17e97402292f&order=platform,arch,compiler&targets=&module=monetdb5 ## Comment 17595 Date: 2012-08-01 15:54:31 +0200 From: @drstmane Changeset [180c2c110cad](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=180c2c110cad) made by Stefan Manegold <Stefan.Manegold@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=180c2c110cad](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=180c2c110cad) Changeset description: modulechk: simplified & fixed test and stable output; this should fix bug #3127 ## Comment 17596 Date: 2012-08-01 16:20:52 +0200 From: @drstmane fixed by changeset [180c2c110cad](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=180c2c110cad) ## Comment 18053 Date: 2012-11-27 13:22:34 +0100 From: @yzchang This is about an existing test monetdb5/modules/mal/Tests/modulechk.mal
modulechk test fails since introduced with changeset 95370bb07d9f "Iterator semantics changes"
https://api.github.com/repos/MonetDB/MonetDB/issues/3127/comments
0
2020-11-30T12:12:23Z
2024-06-27T11:57:11Z
https://github.com/MonetDB/MonetDB/issues/3127
753,426,504
3,127
[ "MonetDB", "MonetDB" ]
Date: 2012-07-20 08:56:05 +0200 From: @drstmane To: MonetDB5 devs &lt;<bugs-monetdb5>&gt; Version: -- development CC: @yzchang Last updated: 2012-11-27 13:23:13 +0100 ## Comment 17521 Date: 2012-07-20 08:56:05 +0200 From: @drstmane Since changeset [95370bb07d9f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=95370bb07d9f) "Iterator semantics changes" (http://dev.monetdb.org/hg/MonetDB/rev/95370bb07d9f), test sql/test/sql_xml/Tests/xml.sql fails with mserver5: /export/scratch1/monet/GNU-Fedora-x86_64-propcheck-assert-17e97402292f-default/MonetDB/monetdb5/modules/mal/mat.c:722: MATproject: Assertion `bcnt == ((map)->U->count)' failed. only with multi-threaded mserver5; cf., http://monetdb.cwi.nl/testweb/web/testgrid.php?serial=44702:17e97402292f&order=platform,arch,compiler&targets=&module=sql&tstlimit=test/sql_xml ## Comment 17591 Date: 2012-08-01 14:18:06 +0200 From: @drstmane fixed by changeset [3db75b2ec791](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=3db75b2ec791) ## Comment 18054 Date: 2012-11-27 13:23:13 +0100 From: @yzchang This is about an existing test sql/test/sql_xml/Tests/xml.sql
sql_xml test asserts since changeset 95370bb07d9f "Iterator semantics changes" only multi-threaded
https://api.github.com/repos/MonetDB/MonetDB/issues/3126/comments
0
2020-11-30T12:12:20Z
2024-06-27T11:57:10Z
https://github.com/MonetDB/MonetDB/issues/3126
753,426,470
3,126
[ "MonetDB", "MonetDB" ]
Date: 2012-07-20 08:14:33 +0200 From: @drstmane To: clients devs &lt;<bugs-clients>&gt; Version: -- development CC: @gijzelaerr, @mlkersten Last updated: 2013-02-19 13:18:00 +0100 ## Comment 17518 Date: 2012-07-20 08:14:33 +0200 From: @drstmane Since recent Python API changes, two Python tests fail; cf., http://monetdb.cwi.nl/testweb/web/testgrid.php?serial=44702:17e97402292f&order=platform,arch,compiler&targets=&module=sql&tstlimit=test/mapi ... at least I assume that there is a relation between the changes and the failing tests ... ## Comment 17519 Date: 2012-07-20 08:35:48 +0200 From: @drstmane Test has been failing since changeset [d3c1ae10f807](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=d3c1ae10f807) (http://dev.monetdb.org/hg/MonetDB/rev/d3c1ae10f807); initially like this http://monetdb.cwi.nl/testweb/tests/44602:f8a0abfbd2d7/GNU-Fedora-x86_64-propcheck-assert/sql/mTests/test/mapi/python_test_monetdb_sql.err.diff.html now like this http://monetdb.cwi.nl/testweb/tests/44702:17e97402292f/GNU-Fedora-x86_64-propcheck-assert/sql/mTests/test/mapi/python_test_monetdb_sql.err.diff.html ## Comment 17520 Date: 2012-07-20 08:37:04 +0200 From: @drstmane (In reply to comment 1) I meant to say/type > Test python_test_monetdb_sql ## Comment 17526 Date: 2012-07-20 14:15:20 +0200 From: @gijzelaerr The python_dbapi should be updated to match the output, since all strings outputted by the API are always unicode now. The failing python_test_monetdb_sql is due to a incorrect import in the test, it is fixed nou in the default branch. ## Comment 17527 Date: 2012-07-20 14:24:10 +0200 From: @drstmane Thanks, Gijs! Did you (or can you) also update the test output of python_dbapi (since you already calosed this bug report)? Thanks! Stefan ## Comment 17528 Date: 2012-07-20 14:27:37 +0200 From: @gijzelaerr sorry, I have no idea how to that, I was so modest to assume you would do that :) ## Comment 17529 Date: 2012-07-20 15:08:32 +0200 From: @drstmane In this case, I assume using your favorite editor to add two 'u' in sql/test/mapi/Tests/python_dbapi.stable.out should be sufficient --- or in other works, there is no "magic" involved. Just in case, more info about MonetDB's testing environment is available at http://dev.monetdb.org/hg/MonetDB/file/def966c3b4e7/testing/README ;-) ... but of course, I can also add the two 'u' in sql/test/mapi/Tests/python_dbapi.stable.out if you prefer that ... ;-) S. ## Comment 17541 Date: 2012-07-21 07:32:09 +0200 From: @drstmane Test python_test_monetdb_sql still (again?) fails in default branch: http://monetdb.cwi.nl/testweb/web/testgrid.php?serial=44732:ee63516d78f5&order=platform,arch,compiler&targets=&module=sql&tstlimit=test/mapi http://monetdb.cwi.nl/testweb/tests/44732:ee63516d78f5/GNU-Fedora-x86_64-propcheck-assert/sql/mTests/test/mapi/python_test_monetdb_sql.err.diff.html ## Comment 17542 Date: 2012-07-21 07:39:45 +0200 From: @drstmane In fact, test python_test_monetdb_sql fails since changeset [d3c1ae10f807](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=d3c1ae10f807) "Split the timezones catalog" (http://dev.monetdb.org/hg/MonetDB/rev/d3c1ae10f807), i.e., not necessarily since / due to python api changes ... ## Comment 17543 Date: 2012-07-21 10:37:14 +0200 From: @gijzelaerr Hm this is weird. i'll look at this on monday. ## Comment 17544 Date: 2012-07-21 10:53:05 +0200 From: @drstmane Maybe, the errors are not related to changeset [d3c1ae10f807](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=d3c1ae10f807) after all, as the errors back than were different from those now; cf., http://monetdb.cwi.nl/testweb/tests/44602:f8a0abfbd2d7/GNU-Fedora-x86_64-propcheck-assert/sql/mTests/test/mapi/python_test_monetdb_sql.err.diff.html vs., http://monetdb.cwi.nl/testweb/tests/44732:ee63516d78f5/GNU-Fedora-x86_64-propcheck-assert/sql/mTests/test/mapi/python_test_monetdb_sql.err.diff.html ## Comment 17557 Date: 2012-07-23 11:28:18 +0200 From: @gijzelaerr i discovered some of the testcases where not correctly using TSTHOSTNAME environment variable and such. I made the connection error a bit more useful and fixed the issue with env var. ## Comment 17561 Date: 2012-07-24 09:41:28 +0200 From: @gijzelaerr is this issue solved now? Probably I didn't invest enough time to get to know the test infrastructure web interface, but I can't find a failing python test for the last test run. ## Comment 17562 Date: 2012-07-24 09:50:18 +0200 From: @drstmane Yes, after your recent fixes and my (hopefully correct) approval, cf., http://dev.monetdb.org/hg/MonetDB/rev/5f659ae8c1a1 , the python tests appear to work fine, now: http://monetdb.cwi.nl/testweb/web/testgrid.php?serial=44753:7968805ec43d&order=platform,arch,compiler&module=sql&tstlimit=test/mapi&nocondense Thanks! ps: feel free to try cd .../MonetDB/sql/test/mapi/Tests && Mtest.py See also Mtest.py --help ;-) ## Comment 18515 Date: 2013-02-19 13:18:00 +0100 From: @sjoerdmullender Feb2013 has been released.
Python tests fail after recent Python API changes
https://api.github.com/repos/MonetDB/MonetDB/issues/3125/comments
0
2020-11-30T12:12:17Z
2024-06-27T11:57:09Z
https://github.com/MonetDB/MonetDB/issues/3125
753,426,426
3,125
[ "MonetDB", "MonetDB" ]
Date: 2012-07-19 09:51:41 +0200 From: @bartscheers To: SQL devs &lt;<bugs-sql>&gt; Version: 11.11.7 (Jul2012-SP1) CC: @njnes Last updated: 2013-01-22 09:29:16 +0100 ## Comment 17512 Date: 2012-07-19 09:51:41 +0200 From: @bartscheers User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:13.0) Gecko/20100101 Firefox/13.0.1 Build Identifier: Table t1 has fk to t2 and another fk to t3; t2 has a fk to t1; We want to do an insert into t1 where the inserts are based on a select from t2; If we select a fk column that needs to be inserted into t1 that has the column and fk this particular insert causes a crash. Reproducible: Always ### Steps to Reproduce: see attachments: 1. fk_insert.sql contains the statements 2. run fk_insert.sh ### Actual Results: stopping database 'fk_insert'... done destroyed database: fk_insert created database in maintenance mode: fk_insert starting database 'fk_insert'... done taken database out of maintenance mode: fk_insert MAPI = (monetdb) /tmp/.s.monetdb.60000 ACTION= read_line QUERY = create table t3 (id int auto_increment ,text varchar(8) ,primary key (id) ) ; create table t2 (id int auto_increment ,ds int not null ,ra double not null ,primary key (id) ,foreign key (ds) references t3 (id) ) ; create table t1 (id int auto_increment ,runcat int ,ds int not null ,ra double default 0 ,primary key (id) ,foreign key (runcat) references t2 (id) ,foreign key (ds) references t3 (id) ) ; insert into t3 (text) values ('test'); insert into t2 (ds,ra) select id,20 from t3; --This one does not work: insert into t1 (runcat,ds,ra) select id,ds,0 from t2; --This one does work: --insert into t1 (runcat,ds,ra) select id,1,0 from t2; ERROR = !Connection terminated ### Expected Results: Something like : Commenting and uncommenting the last two sql lines, resp. stopping database 'fk_insert'... FAILED stop: database is not running: fk_insert destroyed database: fk_insert created database in maintenance mode: fk_insert starting database 'fk_insert'... done taken database out of maintenance mode: fk_insert operation successful operation successful operation successful 1 affected row, last generated key: 1 1 affected row 1 affected row ## Comment 17513 Date: 2012-07-19 09:52:51 +0200 From: @bartscheers Created attachment 133 run script > Attached file: [fk_insert.sh](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3124_fk_insert.sh_133) (application/x-shellscript, 177 bytes) > Description: run script ## Comment 17514 Date: 2012-07-19 09:53:14 +0200 From: @bartscheers Created attachment 134 table definitions & insert statements > Attached file: [fk_insert.sql](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3124_fk_insert.sql_134) (text/x-sql, 686 bytes) > Description: table definitions & insert statements ## Comment 17683 Date: 2012-08-24 14:55:59 +0200 From: @sjoerdmullender Jul2012-SP1 has been released. ## Comment 18017 Date: 2012-11-26 19:57:19 +0100 From: @njnes added test insert_into_table_with_2_foreignkeys.Bug-3124.sql ## Comment 18018 Date: 2012-11-26 19:58:23 +0100 From: @njnes fixed by checking if the index-column still exists in the outer most relation (part just under the join). ## Comment 18019 Date: 2012-11-26 21:08:28 +0100 From: @njnes Changeset [54d040897b07](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=54d040897b07) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=54d040897b07](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=54d040897b07) Changeset description: fixed bug #3124 prevent usage of idx when its not part of the current relation ## Comment 18378 Date: 2013-01-22 09:29:16 +0100 From: @sjoerdmullender Oct2012-SP3 has been released.
insert into table with two foreign keys crashes mserver5
https://api.github.com/repos/MonetDB/MonetDB/issues/3124/comments
0
2020-11-30T12:12:15Z
2024-06-27T11:57:08Z
https://github.com/MonetDB/MonetDB/issues/3124
753,426,401
3,124
[ "MonetDB", "MonetDB" ]
Date: 2012-07-18 16:07:55 +0200 From: @drstmane To: MonetDB5 devs &lt;<bugs-monetdb5>&gt; Version: -- development CC: @yzchang Last updated: 2012-11-27 13:24:05 +0100 ## Comment 17509 Date: 2012-07-18 16:07:55 +0200 From: @drstmane Since changeset [95370bb07d9f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=95370bb07d9f) (http://dev.monetdb.org/hg/MonetDB/rev/95370bb07d9f) two geom tests fail on multi-threaded platforms, only, producing less output (fewer result items) than before; cf., http://monetdb.cwi.nl/testweb/web/testgrid.php?serial=44435:4d99b536bd1d,44403:e86c3cf880a0&module=geom&targets=&order=platform,arch,compiler&diff http://monetdb.cwi.nl/testweb/web/testgrid.php?serial=44657:98789bcfbf66&module=geom&targets=&order=platform,arch,compiler ## Comment 17510 Date: 2012-07-19 06:37:06 +0200 From: @drstmane One of the two failing tests, null-mbr.Bug-2814, appears to be fixed by changeset [8cb9aaea0019](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=8cb9aaea0019) (http://dev.monetdb.org/hg/MonetDB/rev/8cb9aaea0019), while the other one, geom-null-tests, still fails: http://monetdb.cwi.nl/testweb/web/testgrid.php?serial=44678:8cb9aaea0019,44657:98789bcfbf66&module=geom&targets=&order=platform,arch,compiler&diff ## Comment 17590 Date: 2012-08-01 14:17:48 +0200 From: @drstmane fixed by changeset [3db75b2ec791](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=3db75b2ec791) ## Comment 18055 Date: 2012-11-27 13:24:05 +0100 From: @yzchang This is about existing GEOM tests
Geom tests fail multi-threaded (only) since changeset 95370bb07d9f
https://api.github.com/repos/MonetDB/MonetDB/issues/3123/comments
0
2020-11-30T12:12:12Z
2024-06-27T11:57:07Z
https://github.com/MonetDB/MonetDB/issues/3123
753,426,363
3,123
[ "MonetDB", "MonetDB" ]
Date: 2012-07-18 08:32:41 +0200 From: @grobian To: MonetDB5 devs &lt;<bugs-monetdb5>&gt; Version: -- development CC: @yzchang Last updated: 2012-11-27 13:30:13 +0100 ## Comment 17496 Date: 2012-07-18 08:32:41 +0200 From: @grobian the code no longer compiles on non-Linux (Windows already is if-deffed, I suppose) so please hurry in evaluating if setting affinity is beneficial at all, or properly implement autoconf-based tests to use the sometimes non-existing functionality ## Comment 17497 Date: 2012-07-18 10:53:19 +0200 From: @grobian removed ## Comment 18056 Date: 2012-11-27 13:30:13 +0100 From: @yzchang Compilation issue, no need to test. Probably fixed by changesets: [55fa619d7dfa](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=55fa619d7dfa) [4c9ca8e24c24](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=4c9ca8e24c24)
cpu affinity calls are Linux specific
https://api.github.com/repos/MonetDB/MonetDB/issues/3122/comments
0
2020-11-30T12:12:09Z
2024-06-27T11:57:06Z
https://github.com/MonetDB/MonetDB/issues/3122
753,426,329
3,122
[ "MonetDB", "MonetDB" ]
Date: 2012-07-17 10:12:49 +0200 From: suchitradaemon To: SQL devs &lt;<bugs-sql>&gt; Version: 11.11.5 (Jul2012) CC: @drstmane Last updated: 2012-07-17 17:58:25 +0200 ## Comment 17468 Date: 2012-07-17 10:12:49 +0200 From: suchitradaemon ## Comment 17469 Date: 2012-07-17 10:31:29 +0200 From: suchitradaemon Created attachment 130 buildtool nmake install fails > Attached file: [buildtool_nmake_fail.png](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3121_buildtool_nmake_fail.png_130) (image/png, 70076 bytes) > Description: buildtool nmake install fails ## Comment 17470 Date: 2012-07-17 10:40:50 +0200 From: @drstmane Which source code version are you using? Please note that compilation on Windows is only available from HG source, not from source tarballs. Please also note that calling `nmake` in .../buildtools/ is not part of the Windows build instructions; cf., http://dev.monetdb.org/hg/MonetDB/file/8dace860d137/buildtools/doc/windowsbuild.rst ## Comment 17471 Date: 2012-07-17 11:29:16 +0200 From: suchitradaemon Thanks for the reply. I was using the source tarball. I'll use the HG source. (In reply to comment 2) > Which source code version are you using? > > Please note that compilation on Windows is only available from HG source, not > from source tarballs. > > Please also note that calling `nmake` in .../buildtools/ is not part of the > Windows build instructions; cf., > http://dev.monetdb.org/hg/MonetDB/file/8dace860d137/buildtools/doc/windowsbuild.rst ## Comment 17494 Date: 2012-07-17 17:58:25 +0200 From: @drstmane Compiling MonetDB on Windows from source tarballs is currently not supported, and will likely remain unsupported for the foreseeable future. On Windows, we strongly recommend to use binary installers; cf., http://dev.monetdb.org/downloads/Windows/Latest/ . If you indeed need to compile from source on Windows, we assume you know why and what you are doing. In that case, you need to use the sources directly from HG (http://dev.monetdb.org/hg/MonetDB/), and we strongly recommend to checkout the latest release tag or branch. Windows build instructions for experts are available at http://dev.monetdb.org/hg/MonetDB/file/7a616de6829a/buildtools/doc/windowsbuild.rst .
Windows build not working using the Makefile.msc (already provided or the one generated using autogen)
https://api.github.com/repos/MonetDB/MonetDB/issues/3121/comments
0
2020-11-30T12:12:07Z
2024-06-28T13:18:29Z
https://github.com/MonetDB/MonetDB/issues/3121
753,426,298
3,121
[ "MonetDB", "MonetDB" ]
Date: 2012-07-16 05:29:04 +0200 From: gaumann To: Documentation maintainers &lt;<bugs-docs>&gt; Version: unspecified CC: gaumann Last updated: 2012-07-19 14:43:26 +0200 ## Comment 17466 Date: 2012-07-16 05:29:04 +0200 From: gaumann User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:13.0) Gecko/20100101 Firefox/13.0.1 Build Identifier: I receive an Access Denied error when attempting to access http://www.monetdb.org/Documentation/Extensions/Streams. This page is the target of links on various pages that I can access such as http://www.monetdb.org/Documentation/Extensions/Streams/DataCell Reproducible: Always ### Steps to Reproduce: 1. try to access http://www.monetdb.org/Documentation/Extensions/Streams in a web browser 2. 3. ### Actual Results: Access denied You are not authorized to access this page. ### Expected Results: delivered a web page ## Comment 17498 Date: 2012-07-18 10:54:09 +0200 From: @grobian DataCell is experimental at this time, we likely have to remove the references to that page for the time being. Thanks for reporting! ## Comment 17515 Date: 2012-07-19 14:43:26 +0200 From: @grobian references removed
not authorized to access streams documentation
https://api.github.com/repos/MonetDB/MonetDB/issues/3120/comments
0
2020-11-30T12:12:03Z
2024-06-27T11:57:04Z
https://github.com/MonetDB/MonetDB/issues/3120
753,426,246
3,120
[ "MonetDB", "MonetDB" ]
Date: 2012-07-12 20:47:19 +0200 From: Joseph &lt;<jpfourny>&gt; To: clients devs &lt;<bugs-clients>&gt; Version: 11.11.5 (Jul2012) Last updated: 2012-08-23 10:14:37 +0200 ## Comment 17454 Date: 2012-07-12 20:47:19 +0200 From: Joseph &lt;<jpfourny>&gt; User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:10.0.4) Gecko/20100101 Firefox/10.0.4 Build Identifier: In cases where Free Heap Memory in JVM approaches 0 bytes, the cacheSize in MonetConnection$ResultSetResponse gets assigned to 0, causing a divide-by-zero condition when computing the block size in getLine(). Here is a sample stack trace: Caused by: java.lang.ArithmeticException: divide by zero at nl.cwi.monetdb.jdbc.MonetConnection$ResultSetResponse.getLine(MonetConnection.java:1580) at nl.cwi.monetdb.jdbc.MonetResultSet.absolute(MonetResultSet.java:194) at nl.cwi.monetdb.jdbc.MonetResultSet.relative(MonetResultSet.java:2149) at nl.cwi.monetdb.jdbc.MonetResultSet.next(MonetResultSet.java:2116) This condition is rare, but occurs often enough to be quite disruptive. Please note: this is NOT an out-of-memory condition. Although Free Memory is momentarily exhausted, the Max Memory available to the JVM is still several gigabytes away. What would normally happen is GC would run to reclaim memory and / or the Total Memory would be increased (IE: The Java Heap would grow). I am running a memory-intensive application, so it is not unusual for the Free Memory in the Heap to be exhausted (several times) until the Total Memory has expanded to its peak size. Reproducible: Sometimes ### Steps to Reproduce: 1. Start the JVM (only tested on IBM Java 6.0) with very conservative min heap size, but a very large max heap size. 2. Run several queries through JDBC client (in a loop). 3. Concurrently, run a process that leaks memory until Free Memory reaches is threshold. ### Actual Results: If you are (un)lucky, MonetConnection$ResultSetResponse.getLine() will be invoked around the time Free Memory reaches 0, which will cause a divide-by-zero. It may take many runs before this occurs (it is NOT deterministic). ### Expected Results: No error should have happened. Recommend enforcing a min cacheSize (never let it go below some threshold) to avoid divide-by-zero. You can always expect Free Memory to reach 0 at some point, although this is rare. ## Comment 17467 Date: 2012-07-16 14:08:19 +0200 From: @grobian thanks for the report, I'll look into this for Jul2012-SP1 ## Comment 17502 Date: 2012-07-18 11:11:47 +0200 From: @grobian Which JDBC driver do you use? Your line numbers don't match with the latest (Apr2012-SP2/Jul2012) code. ## Comment 17505 Date: 2012-07-18 11:48:06 +0200 From: @grobian Created attachment 131 jdbc-cache-size-no-freemem.patch The free memory thing was completely bogus, as it was counting how much memory was free, but used it to check how many rows of data we could hold. A row obviously requires more than just 2 bytes (UTF-16), so this is flawed. Instead, I think it's better just to rely on the JVM to do the right thing with memory management, and hence not to keep on increasing the cacheSize until memory seems to be short. Instead I now just use a fixed increment of the cacheSize, to fetch bigger blocks, this should gain the efficiency aimed at, while not blowing up the memory requirements to a rediculous amount either. Can you try this patch, or would you prefer a JDBC jar instead? > Attached file: [jdbc-cache-size-no-freemem.patch](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3119_jdbc-cache-size-no-freemem.patch_131) (text/plain, 3301 bytes) > Description: jdbc-cache-size-no-freemem.patch ## Comment 17506 Date: 2012-07-18 13:51:54 +0200 From: Joseph &lt;<jpfourny>&gt; Thanks. I would prefer a JAR, please. ## Comment 17507 Date: 2012-07-18 13:55:25 +0200 From: @grobian Created attachment 132 monetdb-jdbc-3119.jar Here it is, compiled with Java 7, hope that's ok for you > Attached file: [monetdb-jdbc-2.3.jar](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3119_monetdb-jdbc-2.3.jar_132) (application/octet-stream, 107640 bytes) > Description: monetdb-jdbc-3119.jar ## Comment 17517 Date: 2012-07-19 21:07:03 +0200 From: Joseph &lt;<jpfourny>&gt; I don't suppose you can compile it against Java 6 for me to test it out? ## Comment 17523 Date: 2012-07-20 10:16:41 +0200 From: @grobian Created attachment 135 monetdb-jdbc-3119.jar Here is the 1.6 built version > Attached file: [monetdb-jdbc-3119.jar](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3119_monetdb-jdbc-3119.jar_135) (application/octet-stream, 107653 bytes) > Description: monetdb-jdbc-3119.jar ## Comment 17530 Date: 2012-07-20 16:04:31 +0200 From: Joseph &lt;<jpfourny>&gt; Thanks! This client appears to work good. ## Comment 17531 Date: 2012-07-20 17:03:29 +0200 From: @grobian Changeset [84ad1fe6eac3](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=84ad1fe6eac3) made by Fabian Groffen <fabian@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=84ad1fe6eac3](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=84ad1fe6eac3) Changeset description: ResultsetResponse.getLine: fix possible divide by zero error cacheSize can turn 0 when the amount of free memory becomes 0, with a divide by zero as a result. The free memory thing was completely bogus, as it was counting how much memory was free, but used it to check how many rows of data we could hold. A row obviously requires more than just 2 bytes (UTF-16), so this is flawed. Instead, it's better just to rely on the JVM to do the right thing with memory management, and hence not to keep on increasing the cacheSize until memory seems to be short. Instead we now just use a fixed increment of the cacheSize, to fetch bigger blocks, this should gain the efficiency aimed at, while not blowing up the memory requirements to a rediculous amount either. This fixes bug #3119. ## Comment 17532 Date: 2012-07-20 17:04:02 +0200 From: @grobian ok, thanks for testing! ## Comment 17638 Date: 2012-08-23 10:14:37 +0200 From: @sjoerdmullender Jul2012-SP1 has been released.
MonetConnection$ResultSetResponse throws java.lang.ArithmeticException: divide by zero
https://api.github.com/repos/MonetDB/MonetDB/issues/3119/comments
0
2020-11-30T12:12:00Z
2024-06-27T11:57:03Z
https://github.com/MonetDB/MonetDB/issues/3119
753,426,209
3,119
[ "MonetDB", "MonetDB" ]
Date: 2012-07-11 03:54:14 +0200 From: shahbazc To: SQL devs &lt;<bugs-sql>&gt; Version: 11.11.7 (Jul2012-SP1) CC: @mlkersten, @njnes, shahbazc, @drstmane, @yzchang Last updated: 2012-11-28 19:54:35 +0100 ## Comment 17441 Date: 2012-07-11 03:54:14 +0200 From: shahbazc User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/536.11 (KHTML, like Gecko) Chrome/20.0.1132.47 Safari/536.11 Build Identifier: This message is the original description of the error: http://sourceforge.net/mailarchive/forum.php?thread_name=4FF56AD7.2080001%40cwi.nl&forum_name=monetdb-users Reproducible: Always ### Steps to Reproduce: 1. Execute this: select sum(date), sum(time), count(ticker) from trades where date = 20120501 and time > 34200000; 2. Execute this: select sum(date), sum(time), count(ticker) from trades where date = 20120501 and time > 34200000 and time < 37800000; The first query should run in a second or so, the second query should run in a minute or so. This is despite the fact that the second query has more constraints! ### Actual Results: =============EXPLAIN=============== sql>explain select sum(date), sum(time), count(ticker) from trades where date = 20120501 and time > 34200000; +----------------------------------------------------------------------+ | mal | +======================================================================+ | function user.s1_1{autoCommit=true}(A0:int,A1:int):void; | | X_4 := sql.mvc(); | | X_5:bat[:oid,:int] := sql.bind(X_4,"sys","trades","time",0); | | X_10:bat[:oid,:int] := sql.bind(X_4,"sys","trades","time",2); | | X_12 := algebra.kdifference(X_5,X_10); | | X_13 := algebra.kunion(X_12,X_10); | | X_14:bat[:oid,:int] := sql.bind(X_4,"sys","trades","time",1); | | X_16 := algebra.kunion(X_13,X_14); | | X_17:bat[:oid,:oid] := sql.bind_dbat(X_4,"sys","trades",1); | | X_18 := bat.reverse(X_17); | | X_19 := algebra.kdifference(X_16,X_18); | | X_20:bat[:oid,:int] := sql.bind(X_4,"sys","trades","date",0); | | X_22 := algebra.uselect(X_20,A0); | | X_23:bat[:oid,:int] := sql.bind(X_4,"sys","trades","date",2); | | X_24 := algebra.kdifference(X_22,X_23); | | X_25 := algebra.uselect(X_23,A0); | | X_26 := algebra.kunion(X_24,X_25); | | X_27:bat[:oid,:int] := sql.bind(X_4,"sys","trades","date",1); | | X_28 := algebra.uselect(X_27,A0); | | X_29 := algebra.kunion(X_26,X_28); | | X_30 := algebra.kdifference(X_29,X_18); | | X_31 := algebra.semijoin(X_19,X_30); | | X_32 := algebra.thetauselect(X_31,A1,">"); | | X_34 := algebra.kdifference(X_32,X_10); | | X_35 := algebra.semijoin(X_10,X_30); | | X_36 := algebra.thetauselect(X_35,A1,">"); | | X_37 := algebra.kunion(X_34,X_36); | | X_38 := algebra.semijoin(X_14,X_30); | | X_39 := algebra.thetauselect(X_38,A1,">"); | | X_41 := algebra.kunion(X_37,X_39); | | X_42 := algebra.kdifference(X_41,X_18); | | X_43 := algebra.markT(X_42,0@0:oid); | | X_44 := bat.reverse(X_43); | | X_45 := algebra.kdifference(X_20,X_23); | | X_46 := algebra.kunion(X_45,X_23); | | X_47 := algebra.kunion(X_46,X_27); | | X_48 := algebra.leftjoin(X_44,X_47); | | X_49 := algebra.selectNotNil(X_48); | | X_50:lng := aggr.sum(X_49); | | X_58:bat[:oid,:str] := sql.bind(X_4,"sys","trades","ticker",0); | | X_62:bat[:oid,:str] := sql.bind(X_4,"sys","trades","ticker",2); | | X_64 := algebra.kdifference(X_58,X_62); | | X_65 := algebra.kunion(X_64,X_62); | | X_66:bat[:oid,:str] := sql.bind(X_4,"sys","trades","ticker",1); | | X_68 := algebra.kunion(X_65,X_66); | | X_69 := algebra.leftjoin(X_44,X_68); | | X_70 := algebra.selectNotNil(X_69); | | X_71 := aggr.count(X_70); | | X_51 := algebra.kdifference(X_19,X_10); | | X_52 := algebra.kunion(X_51,X_10); | | X_53 := algebra.kunion(X_52,X_14); | | X_54 := algebra.leftjoin(X_44,X_53); | | X_55 := algebra.selectNotNil(X_54); | | X_56:lng := aggr.sum(X_55); | | X_73 := sql.resultSet(3,1,X_50); | | sql.rsColumn(X_73,"sys.trades","L1","bigint",32,0,X_50); | | sql.rsColumn(X_73,"sys.trades","L2","bigint",32,0,X_56); | | sql.rsColumn(X_73,"sys.trades","L3","wrd",64,0,X_71); | | X_85 := io.stdout(); | | sql.exportResult(X_85,X_73); | | end s1_1; | | optimizer.mitosis() | | optimizer.dataflow() | +----------------------------------------------------------------------+ 63 tuples (1.696ms) sql>explain select sum(date), sum(time), count(ticker) from trades where date = 20120501 and time > 34200000 and time < 37800000; +----------------------------------------------------------------------+ | mal | +======================================================================+ | function user.s2_1{autoCommit=true}(A0:int,A1:int,A2:int):void; | | X_5 := sql.mvc(); | | X_6:bat[:oid,:int] := sql.bind(X_5,"sys","trades","date",0); | | X_11:bat[:oid,:int] := sql.bind(X_5,"sys","trades","date",2); | | X_13 := algebra.kdifference(X_6,X_11); | | X_14 := algebra.kunion(X_13,X_11); | | X_15:bat[:oid,:int] := sql.bind(X_5,"sys","trades","date",1); | | X_17 := algebra.kunion(X_14,X_15); | | X_18:bat[:oid,:oid] := sql.bind_dbat(X_5,"sys","trades",1); | | X_19 := bat.reverse(X_18); | | X_20 := algebra.kdifference(X_17,X_19); | | X_21:bat[:oid,:int] := sql.bind(X_5,"sys","trades","time",0); | | X_23 := algebra.uselect(X_21,A1,A2,false,false); | | X_25:bat[:oid,:int] := sql.bind(X_5,"sys","trades","time",2); | | X_26 := algebra.kdifference(X_23,X_25); | | X_27 := algebra.uselect(X_25,A1,A2,false,false); | | X_28 := algebra.kunion(X_26,X_27); | | X_29:bat[:oid,:int] := sql.bind(X_5,"sys","trades","time",1); | | X_30 := algebra.uselect(X_29,A1,A2,false,false); | | X_31 := algebra.kunion(X_28,X_30); | | X_32 := algebra.kdifference(X_31,X_19); | | X_33 := algebra.semijoin(X_20,X_32); | | X_34 := algebra.uselect(X_33,A0); | | X_35 := algebra.kdifference(X_34,X_11); | | X_36 := algebra.semijoin(X_11,X_32); | | X_37 := algebra.uselect(X_36,A0); | | X_38 := algebra.kunion(X_35,X_37); | | X_39 := algebra.semijoin(X_15,X_32); | | X_40 := algebra.uselect(X_39,A0); | | X_41 := algebra.kunion(X_38,X_40); | | X_42 := algebra.kdifference(X_41,X_19); | | X_43 := algebra.markT(X_42,0@0:oid); | | X_44 := bat.reverse(X_43); | | X_45 := algebra.kdifference(X_20,X_11); | | X_46 := algebra.kunion(X_45,X_11); | | X_47 := algebra.kunion(X_46,X_15); | | X_48 := algebra.leftjoin(X_44,X_47); | | X_49 := algebra.selectNotNil(X_48); | | X_50:lng := aggr.sum(X_49); | | X_58:bat[:oid,:str] := sql.bind(X_5,"sys","trades","ticker",0); | | X_62:bat[:oid,:str] := sql.bind(X_5,"sys","trades","ticker",2); | | X_64 := algebra.kdifference(X_58,X_62); | | X_65 := algebra.kunion(X_64,X_62); | | X_66:bat[:oid,:str] := sql.bind(X_5,"sys","trades","ticker",1); | | X_68 := algebra.kunion(X_65,X_66); | | X_69 := algebra.leftjoin(X_44,X_68); | | X_70 := algebra.selectNotNil(X_69); | | X_71 := aggr.count(X_70); | | X_51 := algebra.kdifference(X_21,X_25); | | X_52 := algebra.kunion(X_51,X_25); | | X_53 := algebra.kunion(X_52,X_29); | | X_54 := algebra.leftjoin(X_44,X_53); | | X_55 := algebra.selectNotNil(X_54); | | X_56:lng := aggr.sum(X_55); | | X_73 := sql.resultSet(3,1,X_50); | | sql.rsColumn(X_73,"sys.trades","L1","bigint",32,0,X_50); | | sql.rsColumn(X_73,"sys.trades","L2","bigint",32,0,X_56); | | sql.rsColumn(X_73,"sys.trades","L3","wrd",64,0,X_71); | | X_85 := io.stdout(); | | sql.exportResult(X_85,X_73); | | end s2_1; | | optimizer.mitosis() | | optimizer.dataflow() | +----------------------------------------------------------------------+ 63 tuples (1.652ms) =============TRACE=============== sql>trace select sum(date), sum(time), count(ticker) from trades where date = 20120501 and time > 34200000; +-----------------+------------------+----------+ | L1 | L2 | L3 | +=================+==================+==========+ | 627280562071190 | 1457128841315000 | 31176190 | +-----------------+------------------+----------+ 1 tuple (1.7s) +---------+---------------------------------------------------------------------------------------------------------------+ | ticks | stmt | +=========+===============================================================================================================+ | 2 | X_4 := sql.mvc(); | | 11 | X_5:bat[:oid,:int] =<tmp_1061>[906780265] := sql.bind(X_4=0,"sys","trades","time",0); | | 3 | X_10:bat[:oid,:int] =<tmp_1114>[0] := sql.bind(X_4=0,"sys","trades","time",2); | | 15 | X_12=<tmp_1405>[906780265] := algebra.kdifference(X_5=nil:bat[:oid,:int],X_10=<tmp_1114>:bat[:oid,:int][0]); | | 13 | X_13=<tmp_1407>[906780265] := algebra.kunion(X_12=nil,X_10=<tmp_1114>:bat[:oid,:int][0]); | | 4 | X_14:bat[:oid,:int] =<tmp_1115>[0] := sql.bind(X_4=0,"sys","trades","time",1); | | 7 | X_16=<tmp_1405>[906780265] := algebra.kunion(X_13=nil,X_14=<tmp_1115>:bat[:oid,:int][0]); | | 3 | X_17:bat[:oid,:oid] =<tmp_1117>[0] := sql.bind_dbat(X_4=0,"sys","trades",1); | | 5 | X_18=<tmpr_1117>[0] := bat.reverse(X_17=nil:bat[:oid,:oid]); | | 10 | X_19=<tmp_1407>[906780265] := algebra.kdifference(X_16=nil,X_18=<tmpr_1117>[0]); | | 5 | X_20:bat[:oid,:int] =<tmp_1064>[906780265] := sql.bind(X_4=0,"sys","trades","date",0); | | 330631 | X_22=<tmp_1403>[31268285] := algebra.uselect(X_20=<tmp_1064>:bat[:oid,:int][906780265],A0=20120501); | | 11 | X_23:bat[:oid,:int] =<tmp_1114>[0] := sql.bind(X_4=0,"sys","trades","date",2); | | 11 | X_24=<tmp_1405>[31268285] := algebra.kdifference(X_22=nil,X_23=<tmp_1114>:bat[:oid,:int][0]); | | 13 | X_25=<tmp_1410>[0] := algebra.uselect(X_23=<tmp_1114>:bat[:oid,:int][0],A0=20120501); | | 9 | X_26=<tmp_1403>[31268285] := algebra.kunion(X_24=nil,X_25=nil); | | 4 | X_27:bat[:oid,:int] =<tmp_1115>[0] := sql.bind(X_4=0,"sys","trades","date",1); | | 7 | X_28=<tmp_1405>[0] := algebra.uselect(X_27=<tmp_1115>:bat[:oid,:int][0],A0=20120501); | | 5 | X_29=<tmp_1410>[31268285] := algebra.kunion(X_26=nil,X_28=nil); | | 5 | X_30=<tmp_1405>[31268285] := algebra.kdifference(X_29=nil,X_18=<tmpr_1117>[0]); | | 663673 | X_31=<tmpr_1410>[31268285] := algebra.semijoin(X_19=<tmp_1407>[906780265],X_30=<tmp_1405>[31268285]); | | 31 | X_32=<tmp_1411>[31176190] := algebra.thetauselect(X_31=nil,A1=34200000,">"); | | 10 | X_34=<tmp_1410>[31176190] := algebra.kdifference(X_32=nil,X_10=<tmp_1114>:bat[:oid,:int][0]); | | 9 | X_35=<tmpr_1411>[0] := algebra.semijoin(X_10=<tmp_1114>:bat[:oid,:int][0],X_30=<tmp_1405>[31268285]); | | 9 | X_36=<tmp_1406>[0] := algebra.thetauselect(X_35=nil,A1=34200000,">"); | | 8 | X_37=<tmp_1411>[31176190] := algebra.kunion(X_34=nil,X_36=nil); | | 8 | X_38=<tmpr_1406>[0] := algebra.semijoin(X_14=<tmp_1115>:bat[:oid,:int][0],X_30=nil); | | 8 | X_39=<tmp_1410>[0] := algebra.thetauselect(X_38=nil,A1=34200000,">"); | | 6 | X_41=<tmp_1405>[31176190] := algebra.kunion(X_37=nil,X_39=nil); | | 5 | X_42=<tmp_1410>[31176190] := algebra.kdifference(X_41=nil,X_18=nil); | | 6 | X_43=<tmp_1405>[31176190] := algebra.markT(X_42=nil,0@0:oid); | | 4 | X_44=<tmpr_1405>[31176190] := bat.reverse(X_43=nil); | | 6 | X_45=<tmp_1410>[906780265] := algebra.kdifference(X_20=nil:bat[:oid,:int],X_23=<tmp_1114>:bat[:oid,:int][0]); | | 7 | X_46=<tmp_1411>[906780265] := algebra.kunion(X_45=nil,X_23=nil:bat[:oid,:int]); | | 7 | X_47=<tmp_1410>[906780265] := algebra.kunion(X_46=nil,X_27=nil:bat[:oid,:int]); | | 15 | X_48=<tmp_1406>[31176190] := algebra.leftjoin(X_44=<tmpr_1405>[31176190],X_47=nil); | | 4 | X_49=<tmp_1406>[31176190] := algebra.selectNotNil(X_48=nil); | | 576670 | return sum := aggr.sum(b=<tmp_1406>[31176190],true); | | 576754 | X_50:lng := aggr.sum(X_49=nil); | | 13 | X_58:bat[:oid,:str] =<tmp_1057>[906780265] := sql.bind(X_4=0,"sys","trades","ticker",0); | | 6 | X_62:bat[:oid,:str] =<tmp_1132>[0] := sql.bind(X_4=0,"sys","trades","ticker",2); | | 15 | X_64=<tmp_1406>[906780265] := algebra.kdifference(X_58=nil:bat[:oid,:str],X_62=<tmp_1132>:bat[:oid,:str][0]); | | 9 | X_65=<tmp_1410>[906780265] := algebra.kunion(X_64=nil,X_62=nil:bat[:oid,:str]); | | 3 | X_66:bat[:oid,:str] =<tmp_1133>[0] := sql.bind(X_4=0,"sys","trades","ticker",1); | | 7 | X_68=<tmp_1406>[906780265] := algebra.kunion(X_65=nil,X_66=nil:bat[:oid,:str]); | | 20 | X_69=<tmp_1411>[31176190] := algebra.leftjoin(X_44=<tmpr_1405>[31176190],X_68=nil); | | 4 | X_70=<tmp_1411>[31176190] := algebra.selectNotNil(X_69=nil); | | 5 | X_71 := aggr.count(X_70=nil); | | 9 | X_51=<tmp_1411>[906780265] := algebra.kdifference(X_19=nil,X_10=<tmp_1114>:bat[:oid,:int][0]); | | 7 | X_52=<tmp_1407>[906780265] := algebra.kunion(X_51=nil,X_10=nil:bat[:oid,:int]); | | 7 | X_53=<tmp_1411>[906780265] := algebra.kunion(X_52=nil,X_14=nil:bat[:oid,:int]); | | 79111 | X_54=<tmp_1406>[31176190] := algebra.leftjoin(X_44=nil,X_53=nil); | | 6 | X_55=<tmp_1406>[31176190] := algebra.selectNotNil(X_54=nil); | | 46744 | return sum := aggr.sum(b=<tmp_1406>[31176190],true); | | 46818 | X_56:lng := aggr.sum(X_55=nil); | | 7 | X_73 := sql.resultSet(3,1,X_50=627280562071190:lng); | | 6 | sql.rsColumn(X_73=1,"sys.trades","L1","bigint",32,0,X_50=627280562071190:lng); | | 3 | sql.rsColumn(X_73=1,"sys.trades","L2","bigint",32,0,X_56=1457128841315000:lng); | | 3 | sql.rsColumn(X_73=1,"sys.trades","L3","wrd",64,0,X_71=31176190:wrd); | | 2 | X_85 := io.stdout(); | | 11 | sql.exportResult(X_85=="140089821812416":streams,X_73=1); | | 6 | end s3_1; | | 16 | function user.s3_1(A0=20120501,A1=34200000); | | 1698942 | X_5:void := user.s3_1(20120501,34200000); | +---------+---------------------------------------------------------------------------------------------------------------+ 64 tuples (1.7s) sql>trace select sum(date), sum(time), count(ticker) from trades where date = 20120501 and time > 34200000 and time < 37800000; +-----------------+-----------------+---------+ | L1 | L2 | L3 | +=================+=================+=========+ | 120106051077837 | 214559715617000 | 5969337 | +-----------------+-----------------+---------+ 1 tuple (1m 58s) +-----------+-------------------------------------------------------------------------------------------------------------------------------+ | ticks | stmt | +===========+===============================================================================================================================+ | 3 | X_5 := sql.mvc(); | | 11 | X_6:bat[:oid,:int] =<tmp_1064>[906780265] := sql.bind(X_5=0,"sys","trades","date",0); | | 3 | X_11:bat[:oid,:int] =<tmp_1114>[0] := sql.bind(X_5=0,"sys","trades","date",2); | | 15 | X_13=<tmp_1411>[906780265] := algebra.kdifference(X_6=nil:bat[:oid,:int],X_11=<tmp_1114>:bat[:oid,:int][0]); | | 12 | X_14=<tmp_1406>[906780265] := algebra.kunion(X_13=nil,X_11=<tmp_1114>:bat[:oid,:int][0]); | | 4 | X_15:bat[:oid,:int] =<tmp_1115>[0] := sql.bind(X_5=0,"sys","trades","date",1); | | 7 | X_17=<tmp_1411>[906780265] := algebra.kunion(X_14=nil,X_15=<tmp_1115>:bat[:oid,:int][0]); | | 4 | X_18:bat[:oid,:oid] =<tmp_1117>[0] := sql.bind_dbat(X_5=0,"sys","trades",1); | | 4 | X_19=<tmpr_1117>[0] := bat.reverse(X_18=nil:bat[:oid,:oid]); | | 9 | X_20=<tmp_1406>[906780265] := algebra.kdifference(X_17=nil,X_19=<tmpr_1117>[0]); | | 4 | X_21:bat[:oid,:int] =<tmp_1061>[906780265] := sql.bind(X_5=0,"sys","trades","time",0); | | 50407137 | X_23=<tmp_1404>[173110773] := algebra.uselect(X_21=<tmp_1061>:bat[:oid,:int][906780265],A1=34200000,A2=37800000,false,false); | | 10 | X_25:bat[:oid,:int] =<tmp_1114>[0] := sql.bind(X_5=0,"sys","trades","time",2); | | 14 | X_26=<tmp_1411>[173110773] := algebra.kdifference(X_23=nil,X_25=<tmp_1114>:bat[:oid,:int][0]); | | 16 | X_27=<tmp_1407>[0] := algebra.uselect(X_25=<tmp_1114>:bat[:oid,:int][0],A1=34200000,A2=37800000,false,false); | | 10 | X_28=<tmp_1405>[173110773] := algebra.kunion(X_26=nil,X_27=nil); | | 4 | X_29:bat[:oid,:int] =<tmp_1115>[0] := sql.bind(X_5=0,"sys","trades","time",1); | | 9 | X_30=<tmp_1411>[0] := algebra.uselect(X_29=<tmp_1115>:bat[:oid,:int][0],A1=34200000,A2=37800000,false,false); | | 7 | X_31=<tmp_1407>[173110773] := algebra.kunion(X_28=nil,X_30=nil); | | 6 | X_32=<tmp_1411>[173110773] := algebra.kdifference(X_31=nil,X_19=<tmpr_1117>[0]); | | 61019466 | X_33=<tmp_1407>[173110773] := algebra.semijoin(X_20=<tmp_1406>[906780265],X_32=<tmp_1411>[173110773]); | | 287369 | X_34=<tmp_1410>[5969337] := algebra.uselect(X_33=nil,A0=20120501); | | 17 | X_35=<tmp_1405>[5969337] := algebra.kdifference(X_34=nil,X_11=<tmp_1114>:bat[:oid,:int][0]); | | 19 | X_36=<tmp_1261>[0] := algebra.semijoin(X_11=<tmp_1114>:bat[:oid,:int][0],X_32=<tmp_1411>[173110773]); | | 13 | X_37=<tmp_1403>[0] := algebra.uselect(X_36=nil,A0=20120501); | | 10 | X_38=<tmp_1410>[5969337] := algebra.kunion(X_35=nil,X_37=nil); | | 290714 | X_39=<tmp_1261>[0] := algebra.semijoin(X_15=<tmp_1115>:bat[:oid,:int][0],X_32=nil); | | 27 | X_40=<tmp_1411>[0] := algebra.uselect(X_39=nil,A0=20120501); | | 13 | X_41=<tmp_1404>[5969337] := algebra.kunion(X_38=nil,X_40=nil); | | 8 | X_42=<tmp_1411>[5969337] := algebra.kdifference(X_41=nil,X_19=nil); | | 13 | X_43=<tmp_1404>[5969337] := algebra.markT(X_42=nil,0@0:oid); | | 5 | X_44=<tmpr_1404>[5969337] := bat.reverse(X_43=nil); | | 9 | X_45=<tmp_1411>[906780265] := algebra.kdifference(X_20=nil,X_11=<tmp_1114>:bat[:oid,:int][0]); | | 7 | X_46=<tmp_1406>[906780265] := algebra.kunion(X_45=nil,X_11=nil:bat[:oid,:int]); | | 7 | X_47=<tmp_1411>[906780265] := algebra.kunion(X_46=nil,X_15=nil:bat[:oid,:int]); | | 25 | X_48=<tmp_1410>[5969337] := algebra.leftjoin(X_44=<tmpr_1404>[5969337],X_47=nil); | | 4 | X_49=<tmp_1410>[5969337] := algebra.selectNotNil(X_48=nil); | | 487413 | return sum := aggr.sum(b=<tmp_1410>[5969337],true); | | 1118369 | X_50:lng := aggr.sum(X_49=nil); | | 14 | X_58:bat[:oid,:str] =<tmp_1057>[906780265] := sql.bind(X_5=0,"sys","trades","ticker",0); | | 3 | X_62:bat[:oid,:str] =<tmp_1132>[0] := sql.bind(X_5=0,"sys","trades","ticker",2); | | 16 | X_64=<tmp_1410>[906780265] := algebra.kdifference(X_58=nil:bat[:oid,:str],X_62=<tmp_1132>:bat[:oid,:str][0]); | | 9 | X_65=<tmp_1411>[906780265] := algebra.kunion(X_64=nil,X_62=nil:bat[:oid,:str]); | | 3 | X_66:bat[:oid,:str] =<tmp_1133>[0] := sql.bind(X_5=0,"sys","trades","ticker",1); | | 6 | X_68=<tmp_1410>[906780265] := algebra.kunion(X_65=nil,X_66=nil:bat[:oid,:str]); | | 155918 | X_69=<tmp_1406>[5969337] := algebra.leftjoin(X_44=<tmpr_1404>[5969337],X_68=nil); | | 7 | X_70=<tmp_1406>[5969337] := algebra.selectNotNil(X_69=nil); | | 5 | X_71 := aggr.count(X_70=nil); | | 13 | X_51=<tmp_1406>[906780265] := algebra.kdifference(X_21=nil:bat[:oid,:int],X_25=<tmp_1114>:bat[:oid,:int][0]); | | 8 | X_52=<tmp_1410>[906780265] := algebra.kunion(X_51=nil,X_25=nil:bat[:oid,:int]); | | 7 | X_53=<tmp_1406>[906780265] := algebra.kunion(X_52=nil,X_29=nil:bat[:oid,:int]); | | 5325689 | X_54=<tmp_1411>[5969337] := algebra.leftjoin(X_44=nil,X_53=nil); | | 10 | X_55=<tmp_1411>[5969337] := algebra.selectNotNil(X_54=nil); | | 8932 | return sum := aggr.sum(b=<tmp_1411>[5969337],true); | | 9016 | X_56:lng := aggr.sum(X_55=nil); | | 6 | X_73 := sql.resultSet(3,1,X_50=120106051077837:lng); | | 6 | sql.rsColumn(X_73=3,"sys.trades","L1","bigint",32,0,X_50=120106051077837:lng); | | 3 | sql.rsColumn(X_73=3,"sys.trades","L2","bigint",32,0,X_56=214559715617000:lng); | | 3 | sql.rsColumn(X_73=3,"sys.trades","L3","wrd",64,0,X_71=5969337:wrd); | | 1 | X_85 := io.stdout(); | | 11 | sql.exportResult(X_85=="140089821812416":streams,X_73=3); | | 6 | end s4_1; | | 15 | function user.s4_1(A0=20120501,A1=34200000,A2=37800000); | | 118615812 | X_5:void := user.s4_1(20120501,34200000,37800000); | +-----------+-------------------------------------------------------------------------------------------------------------------------------+ 64 tuples (1m 58s) ## Comment 17445 Date: 2012-07-11 23:25:39 +0200 From: shahbazc Server version: Database: MonetDB v11.9.7 (Apr2012-SP2); Client: MonetDB/SQL interactive terminal (Apr2012-SP2) ## Comment 17446 Date: 2012-07-11 23:37:10 +0200 From: @mlkersten Did you ran the both queries multiple times within the same session? Did you ran them on a 'quiet' system? (close mailers, browsers,...anything that consumes a lot of memory) The trace hints at that the query is affected by 'other' work on the system ## Comment 17447 Date: 2012-07-12 02:16:43 +0200 From: shahbazc (In reply to comment 2) > Did you ran the both queries multiple times within the same session? > Did you ran them on a 'quiet' system? (close mailers, browsers,...anything that > consumes a lot of memory) > > The trace hints at that the query is affected by 'other' work on the system I've been able to re-produce this consistently. The machine I'm running this on is basically a server. I ssh into it remotely and although it has a GUI, no one is using it. When I did these test, I was the only one logged in. I did the test sequentially. I ran one query, then did the second query. Then I did one query with explain, then second query with explain. Then I did the same thing with trace. If you like, I'll be happy to give you temporary access to my machine so you can run the queries yourself, and confirm that the machine is not doing anything else. I didn't mention this earlier in the bug report, but I also tried using "time between a and b" instead of "time > a and time < b," which didn't seem to help (actually made the query time slightly worse). ## Comment 17448 Date: 2012-07-12 06:50:19 +0200 From: @drstmane Created attachment 124 diff between MAL plans (EXPLAIN) > Attached file: [explain.html](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3118_explain.html_124) (text/html, 30978 bytes) > Description: diff between MAL plans (EXPLAIN) ## Comment 17449 Date: 2012-07-12 06:51:03 +0200 From: @drstmane Created attachment 125 diff between profiles (TRACEs) > Attached file: [trace.html](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3118_trace.html_125) (text/html, 59369 bytes) > Description: diff between profiles (TRACEs) ## Comment 17450 Date: 2012-07-12 06:53:38 +0200 From: @drstmane The problem appears to be that in the second (slow) case our SQL optimizer chooses to evaluate the double-sided range predicate on time before the point predicate on date, while in the first (fast) case, it evaluates the point predicate on date before the single-sided range predicate on time. See the attached diffs for details. ## Comment 17451 Date: 2012-07-12 15:03:03 +0200 From: shahbazc (In reply to comment 6) > The problem appears to be that in the second (slow) case our SQL optimizer > chooses to evaluate the double-sided range predicate on time before the point > predicate on date, while in the first (fast) case, it evaluates the point > predicate on date before the single-sided range predicate on time. > See the attached diffs for details. So how can this be resolved? From the perspective of a user, this is a fairly big problem! Since monetdb is supposed to compress columns, the relative cardinality of the date column vs time column should make it obvious to the optimizer that date should always be processed first (there are a total of about 30 unique date values...all in sequential order, but many tens of thousands of unique time values (10s of millions actually, since time is not sorted across days). This still looks like a bug to me, a fairly big one since the data model is so simple and optimizable. If I had done the second query first, I would have thought that monetdb performance is terrible and simply given up. In reality, monetdb really does have awesome performance, which can be achieved with almost no tuning. However, looks like the optimizer is not optimizing very well. ## Comment 17452 Date: 2012-07-12 16:17:05 +0200 From: @drstmane (In reply to comment 7) > So how can this be resolved? We need to check, whether and how we can fix our SQL optimizer. > From the perspective of a user, this is a fairly big problem! > > Since monetdb is supposed to compress columns, the relative cardinality of the > date column vs time column should make it obvious to the optimizer that date > should always be processed first (there are a total of about 30 unique date > values...all in sequential order, but many tens of thousands of unique time > values (10s of millions actually, since time is not sorted across days). > > This still looks like a bug to me, a fairly big one since the data model is so > simple and optimizable. If I had done the second query first, I would have > thought that monetdb performance is terrible and simply given up. In reality, > monetdb really does have awesome performance, which can be achieved with almost > no tuning. However, looks like the optimizer is not optimizing very well. We appreciate your feedback! ## Comment 17453 Date: 2012-07-12 16:48:25 +0200 From: @mlkersten You might consider sorting the table on the time domain. This would speed up most time-related operations. ## Comment 17455 Date: 2012-07-12 22:34:54 +0200 From: shahbazc (In reply to comment 9) > You might consider sorting the table on the time domain. > This would speed up most time-related operations. I was hoping to avoid hacks such as these. I don't mind optimizing database parameters, but I'm a little hesitant to mess with the semantics of data. If I do with to experiment with this, do you mean I should pre-sort my data on time, then insert it into monetdb or is there a way to change the layout once the data is already in monetdb (perhaps insert into trades 2 select * from trades, order by time?) ## Comment 17456 Date: 2012-07-12 22:41:56 +0200 From: @mlkersten You might try out the experimental code in sql/scripts/19_cluster (no guarantees!) ## Comment 17457 Date: 2012-07-13 05:16:51 +0200 From: shahbazc Created attachment 126 very simple 'explain' of sql query with where clause in date, ticker order > Attached file: [simple-dateticker.explain](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3118_simple-dateticker.explain_126) (text/plain, 3542 bytes) > Description: very simple 'explain' of sql query with where clause in date, ticker order ## Comment 17458 Date: 2012-07-13 05:18:56 +0200 From: shahbazc Created attachment 127 very simple 'explain' of sql query with where clause in ticker, date order > Attached file: [simple-tickerdate.explain](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3118_simple-tickerdate.explain_127) (text/plain, 3539 bytes) > Description: very simple 'explain' of sql query with where clause in ticker, date order ## Comment 17459 Date: 2012-07-13 05:19:26 +0200 From: shahbazc Created attachment 128 very simple 'trace' of sql query with where clause in date, ticker order > Attached file: [simple-dateticker.trace](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3118_simple-dateticker.trace_128) (text/plain, 5927 bytes) > Description: very simple 'trace' of sql query with where clause in date, ticker order ## Comment 17460 Date: 2012-07-13 05:19:49 +0200 From: shahbazc Created attachment 129 very simple 'trace' of sql query with where clause in ticker, date order > Attached file: [simple-tickerdate.trace](https://github.com/MonetDB/monetdb-issues-attachments/blob/master/issue_3118_simple-tickerdate.trace_129) (text/plain, 5795 bytes) > Description: very simple 'trace' of sql query with where clause in ticker, date order ## Comment 17461 Date: 2012-07-13 05:22:27 +0200 From: shahbazc Just uploaded 'explain' and 'trace' of two queries which are even simpler than the previous queries. What's most interesting here is that these two queries should be EXACTLY the same! The only thing which is different is that the order of constraints in the where clause is switched! Here are the queries: select count(ticker) from trades where date = 20120501 and ticker = 'eSPY' select count(ticker) from trades where ticker='eSPY' and date = 20120501; One of them returns in less than a second, one of them takes over a minute!! :) ## Comment 17495 Date: 2012-07-18 02:49:21 +0200 From: shahbazc Just upgraded to version 11.11.5 (Jul2012) and the results are still the same: sql>select count(ticker) from trades where date = 20120501 and ticker = 'eSPY'; +--------+ | L1 | +========+ | 535214 | +--------+ 1 tuple (1m 3s) sql>select count(ticker) from trades where ticker='eSPY' and date = 20120501; +--------+ | L1 | +========+ | 535214 | +--------+ 1 tuple (1.5s) sql>select count(ticker) from trades where date = 20120501 and ticker = 'eSPY'; +--------+ | L1 | +========+ | 535214 | +--------+ 1 tuple (1m 1s) sql>select count(ticker) from trades where ticker='eSPY' and date = 20120501; +--------+ | L1 | +========+ | 535214 | +--------+ 1 tuple (1.5s) ## Comment 17607 Date: 2012-08-03 10:09:12 +0200 From: @grobian (In reply to comment 16) > Here are the queries: > > select count(ticker) from trades where date = 20120501 and ticker = 'eSPY' > select count(ticker) from trades where ticker='eSPY' and date = 20120501; > > One of them returns in less than a second, one of them takes over a minute!! :) Maybe this is good for you to know, because it seems you and others are very confused by this behaviour. MonetDB SQL has no cost-based optimiser in place. This means that it can not, and will not, reorder the WHERE conditions to reduce the data input as soon as possible. For instance PostgreSQL and many commercial systems do this, which yields in the database seemingly not caring in which order you give the WHERE conditions. Note that a cost-based optimiser at the SQL level is not desirable at the moment because it would most likely make wrong decisions in a distributed environment. We do acknowledge this is a problem, though. ## Comment 17687 Date: 2012-08-24 14:56:02 +0200 From: @sjoerdmullender Jul2012-SP1 has been released. ## Comment 18135 Date: 2012-11-27 15:53:56 +0100 From: @yzchang No test needed for performance issues
Adding an additional constraint to the where clause actually REDUCES performance (by orders of magnitude)
https://api.github.com/repos/MonetDB/MonetDB/issues/3118/comments
0
2020-11-30T12:11:54Z
2024-06-27T11:57:02Z
https://github.com/MonetDB/MonetDB/issues/3118
753,426,138
3,118
[ "MonetDB", "MonetDB" ]
Date: 2012-07-10 19:11:49 +0200 From: @drstmane To: SQL devs &lt;<bugs-sql>&gt; Version: 11.11.7 (Jul2012-SP1) Last updated: 2012-09-21 11:51:26 +0200 ## Comment 17440 Date: 2012-07-10 19:11:49 +0200 From: @drstmane Since changeset [817328b74e2f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=817328b74e2f) " partial de-Mx mal_interpreter Move the performance profiling to the runtime module. " cf., http://dev.monetdb.org/hg/MonetDB/rev/817328b74e2f test sql/test/BugTracker-2011/Tests/history.Bug-2909.sql fails, producing extra profiling output, cf., http://monetdb.cwi.nl/testweb/tests/44546:a01144d4a0f9/GNU-Fedora-x86_64-propcheck-assert/sql/mTests/test/BugTracker-2011/history.Bug-2909.out.diff.html Approving the output is not really an option as it varies between runs. Rather, the extra output should be disabled, again. Unfortunately, I failed to do so myself ... ## Comment 17608 Date: 2012-08-03 10:14:57 +0200 From: @grobian the extra output is simply illegal, it's in a SQL/MAPI session, so whatever did this, should revert it again If any extra output is necessary, it should be prefixed with , and NOT positioned between the SQL header and the data (but before or after). ## Comment 17609 Date: 2012-08-03 14:03:29 +0200 From: @grobian This seems to be bigfoot stuff, but I don't know why it is enabled now, nothing seems to do it. ## Comment 17696 Date: 2012-08-24 14:56:08 +0200 From: @sjoerdmullender Jul2012-SP1 has been released. ## Comment 17702 Date: 2012-08-24 16:09:19 +0200 From: @sjoerdmullender Changeset [0901d759538f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=0901d759538f) made by Sjoerd Mullender <sjoerd@acm.org> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=0901d759538f](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=0901d759538f) Changeset description: Only print runtimeTiming information when in the (mdb) debugger. This fixes bugs 3117 and 3145.
test sql/test/BugTracker-2011/Tests/history.Bug-2909.sql produces extra profiling output since changeset 817328b74e2f
https://api.github.com/repos/MonetDB/MonetDB/issues/3117/comments
0
2020-11-30T12:11:51Z
2024-06-27T11:57:01Z
https://github.com/MonetDB/MonetDB/issues/3117
753,426,094
3,117
[ "MonetDB", "MonetDB" ]
Date: 2012-07-09 15:51:43 +0200 From: @mlkersten To: SQL devs &lt;<bugs-sql>&gt; Version: 11.9.7 (Apr2012-SP2) [obsolete] CC: @njnes Last updated: 2012-07-17 13:57:43 +0200 ## Comment 17434 Date: 2012-07-09 15:51:43 +0200 From: @mlkersten In the VOC demo database, the following query (double use of IS NOT NULL) causes a segfault SELECT hired, count(*) FROM voyages WHERE true AND hired IS NOT NULL AND hired is not null GROUP BY hired ORDER BY hired; in 0x00007fadc5d4857e in exp_bin (sql=0x7fadb8005470, e=0x7fadb8115ea0, left=0x7fadb8118af0, right=0x0, grp=0x0, sel=0x0) at /export/scratch1/mk/current//package/sql/server/rel_bin.c:690 ## Comment 17435 Date: 2012-07-09 22:55:23 +0200 From: @njnes fixed bug in rel_push_select_down (down project) ## Comment 17483 Date: 2012-07-17 13:57:43 +0200 From: @grobian Fix released in Jul2012
Segfault in SQL
https://api.github.com/repos/MonetDB/MonetDB/issues/3116/comments
0
2020-11-30T12:11:49Z
2024-06-27T11:57:00Z
https://github.com/MonetDB/MonetDB/issues/3116
753,426,066
3,116
[ "MonetDB", "MonetDB" ]
Date: 2012-07-05 23:22:22 +0200 From: @mlkersten To: SQL devs &lt;<bugs-sql>&gt; Version: -- development CC: @njnes Last updated: 2012-07-06 13:38:43 +0200 ## Comment 17417 Date: 2012-07-05 23:22:22 +0200 From: @mlkersten User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.7; rv:13.0) Gecko/20100101 Firefox/13.0.1 Build Identifier: The median() function should also work for char and varchar using lexical orderings. Reproducible: Always ## Comment 17419 Date: 2012-07-06 13:38:43 +0200 From: @njnes median is usually only defined over numeric or date types.
Median for all types
https://api.github.com/repos/MonetDB/MonetDB/issues/3115/comments
0
2020-11-30T12:11:46Z
2024-06-28T13:18:29Z
https://github.com/MonetDB/MonetDB/issues/3115
753,426,034
3,115
[ "MonetDB", "MonetDB" ]
Date: 2012-07-05 22:58:47 +0200 From: Benjie Chen &lt;<benjie>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.11.5 (Jul2012) CC: @bartscheers, @njnes Last updated: 2012-11-27 14:19:57 +0100 ## Comment 17415 Date: 2012-07-05 22:58:47 +0200 From: Benjie Chen &lt;<benjie>&gt; Consider the following model: CREATE TABLE "sys"."first" ( "id" int NOT NULL, CONSTRAINT "first_id_pkey" PRIMARY KEY ("id") ); CREATE TABLE "sys"."second" ( "id" int NOT NULL, "ref" int, CONSTRAINT "second_id_pkey" PRIMARY KEY ("id"), CONSTRAINT "second_ref_fkey" FOREIGN KEY ("ref") REFERENCES "sys"."first" ("id") ); What works, and should work: insert into "second" values (100, null); What does not work, and should not work: sql>insert into "second" values (101, 1); M0M29!INSERT INTO: FOREIGN KEY constraint 'second.second_ref_fkey' violated What work, but should not work (note that I've never added anything to first): sql>update "second" set ref = 1 WHERE id = 100; 1 affected row (2.020ms) What does not work, but should work (note that this is executed after the last statement): sql>update "second" set ref = null WHERE id = 100; M0M29!UPDATE: FOREIGN KEY constraint 'second.second_ref_fkey' violated ## Comment 17416 Date: 2012-07-05 22:59:35 +0200 From: Benjie Chen &lt;<benjie>&gt; Database: MonetDB v11.9.7 (Apr2012-SP2) ## Comment 17423 Date: 2012-07-06 15:36:31 +0200 From: Benjie Chen &lt;<benjie>&gt; (In reply to comment 1) > Database: MonetDB v11.9.7 (Apr2012-SP2) I want to add that if table "first" is not empty, then the constraints are checked correctly. I.e. here is the complete trace: CREATE TABLE "sys"."first" ( "id" int NOT NULL, CONSTRAINT "first_id_pkey" PRIMARY KEY ("id") ); CREATE TABLE "sys"."second" ( "id" int NOT NULL, "ref" int, CONSTRAINT "second_id_pkey" PRIMARY KEY ("id"), CONSTRAINT "second_ref_fkey" FOREIGN KEY ("ref") REFERENCES "sys"."first" ("id") ); What works, and should work: insert into "second" values (100, null); What does not work, and should not work: sql>insert into "second" values (101, 1); M0M29!INSERT INTO: FOREIGN KEY constraint 'second.second_ref_fkey' violated What work, but should not work (note that I've never added anything to first): sql>update "second" set ref = 1 WHERE id = 100; 1 affected row (2.020ms) What does not work, but should work (note that this is executed after the last statement): sql>update "second" set ref = null WHERE id = 100; M0M29!UPDATE: FOREIGN KEY constraint 'second.second_ref_fkey' violated Now insert something into "first" insert into "first" values (200); Try update again - this succeeded when it suppose to fail earlier, and now correctly fails. sql>update "second" set ref = 1 WHERE id = 100; M0M29!UPDATE: FOREIGN KEY constraint 'second.second_ref_fkey' violated ## Comment 17427 Date: 2012-07-06 17:12:10 +0200 From: @njnes Changeset [03516346b4d5](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=03516346b4d5) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=03516346b4d5](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=03516346b4d5) Changeset description: fixed bugs 3113 and 3114 3113: single column indices aren't stored, ie don't have updates 3114: properly use the update 'column expression' instead of the original column expression. ## Comment 17429 Date: 2012-07-06 17:13:41 +0200 From: @njnes use proper updated column expression ## Comment 17430 Date: 2012-07-07 05:36:03 +0200 From: Benjie Chen &lt;<benjie>&gt; Applied and compiled the changeset, and confirming that the bug has been solved. Thanks. Eagerly awaiting for the official release. (In reply to comment 3) > Changeset [03516346b4d5](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=03516346b4d5) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, > refers to this bug. > > For complete details, see > [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=03516346b4d5](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=03516346b4d5) > > Changeset description: > > fixed bugs 3113 and 3114 > > 3113: single column indices aren't stored, ie don't have updates > > 3114: properly use the update 'column expression' instead of the original > column expression. ## Comment 17473 Date: 2012-07-17 13:46:39 +0200 From: @grobian Fix delivered in Jul2012 release
Foreign Key prblems
https://api.github.com/repos/MonetDB/MonetDB/issues/3114/comments
0
2020-11-30T12:11:44Z
2024-06-27T11:56:58Z
https://github.com/MonetDB/MonetDB/issues/3114
753,426,001
3,114
[ "MonetDB", "MonetDB" ]
Date: 2012-07-05 20:59:27 +0200 From: Benjie Chen &lt;<benjie>&gt; To: SQL devs &lt;<bugs-sql>&gt; Version: 11.11.5 (Jul2012) CC: @njnes Last updated: 2012-07-17 13:46:40 +0200 ## Comment 17413 Date: 2012-07-05 20:59:27 +0200 From: Benjie Chen &lt;<benjie>&gt; User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_6_7) AppleWebKit/536.5 (KHTML, like Gecko) Chrome/19.0.1084.56 Safari/536.5 Build Identifier: MonetDB v11.9.7 (Apr2012-SP2) I have a table called "datastore_predicate", which a column "unit_id" that is a FK to another table. I ran the following and got an error. sql>update datastore_predicate set unit_id = NULL where id = 30005; MAPI = (monetdb) /tmp/.s.monetdb.50000 ACTION= read_line QUERY = update datastore_predicate set unit_id = NULL where id = 30005; ERROR = !Connection terminated I also tried unit_id = 1, etc. Running on Linux MonetDB v11.9.7 (Apr2012-SP2) Reproducible: Always ## Comment 17414 Date: 2012-07-05 21:08:54 +0200 From: Benjie Chen &lt;<benjie>&gt; Update: the issue is NOT due to column being a FK, but because the FK is indexed. My ORM automatically adds index for FK columns. When I remove that index, the UPDATE works. So it seems like updating a column with index breaks. ## Comment 17421 Date: 2012-07-06 13:53:39 +0200 From: @njnes do you have an example test (sql script) to reproduce the problem. ## Comment 17424 Date: 2012-07-06 15:51:52 +0200 From: Benjie Chen &lt;<benjie>&gt; (In reply to comment 2) > do you have an example test (sql script) to reproduce the problem. Yes. I am going to post a trace that does not work, then 3 traces that do work. The 3 traces that do show that to re-produce the bug, you need FK constraint, an index, and more than one row in second table. First, trace that does NOT work: sql>create table "x"("id" int not null primary key); operation successful (2.242ms) sql>create table "y"("id" int not null primary key,"x_id" int,constraint "x_id_refs_id" FOREIGN KEY("x_id") references "x"("id")); operation successful (1.279ms) sql>\d y CREATE TABLE "sys"."y" ( "id" INTEGER NOT NULL, "x_id" INTEGER, CONSTRAINT "y_id_pkey" PRIMARY KEY ("id"), CONSTRAINT "x_id_refs_id" FOREIGN KEY ("x_id") REFERENCES "sys"."x" ("id") ); sql>\d x CREATE TABLE "sys"."x" ( "id" INTEGER NOT NULL, CONSTRAINT "x_id_pkey" PRIMARY KEY ("id") ); sql>create index "y_x_id" ON "y"("x_id"); operation successful (3.404ms) sql>insert into "x" VALUES(1),(2),(3); 3 affected rows (1.209ms) sql>insert into "y" VALUES(100,1),(101,2); 2 affected rows (2.040ms) sql>update y SET x_id = 3 WHERE id = 101; MAPI = (monetdb) /tmp/.s.monetdb.50000 ACTION= read_line QUERY = update y SET x_id = 3 WHERE id = 101; ERROR = !Connection terminated Now a similar trace that does work - this shows that the FK constraint is necessary to re-create the bug: sql>create table "x"("id" int not null primary key); operation successful (1.294ms) sql>create table "y"("id" int not null primary key,"x_id" int); operation successful (1.329ms) sql>create index "y_x_id" ON "y"("x_id"); operation successful (1.109ms) sql>insert into "x" VALUES(1),(2),(3); 3 affected rows (1.137ms) sql>insert into "y" VALUES(100,1),(101,2); 2 affected rows (1.195ms) sql>update y SET x_id = 3 WHERE id = 101; 1 affected row (1.261ms) Another similar trace that does work - this shows the index is necessary to re-create the bug: sql>create table "x"("id" int not null primary key); operation successful (1.303ms) sql>create table "y"("id" int not null primary key,"x_id" int,constraint "x_id_refs_id" FOREIGN KEY("x_id") references "x"("id")); operation successful (1.470ms) sql>insert into "x" VALUES(1),(2),(3); 3 affected rows (1.288ms) sql>insert into "y" VALUES(100,1),(101,2); 2 affected rows (2.372ms) sql>update y SET x_id = 3 WHERE id = 101; 1 affected row (2.226ms) Another trace that does work, shows that the second table must have more than one row to re-produce the bug: sql>create table "x"("id" int not null primary key); operation successful (1.316ms) sql>create table "y"("id" int not null primary key,"x_id" int); operation successful (1.320ms) sql>create index "y_x_id" ON "y"("x_id"); operation successful (1.063ms) sql>insert into "x" VALUES(1),(2),(3); 3 affected rows (1.152ms) sql>insert into "y" VALUES(100,1); 1 affected row (1.059ms) sql>update y SET x_id = 3 WHERE id = 100; 1 affected row (1.212ms) ## Comment 17426 Date: 2012-07-06 17:12:10 +0200 From: @njnes Changeset [03516346b4d5](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=03516346b4d5) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=03516346b4d5](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=03516346b4d5) Changeset description: fixed bugs 3113 and 3114 3113: single column indices aren't stored, ie don't have updates 3114: properly use the update 'column expression' instead of the original column expression. ## Comment 17428 Date: 2012-07-06 17:12:45 +0200 From: @njnes fixed crash, index updates do not exist for single column indices ## Comment 17431 Date: 2012-07-07 05:38:18 +0200 From: Benjie Chen &lt;<benjie>&gt; Similar to 3114, applied changeset to last stable release code, confirming the bug has been solved. Thanks. (In reply to comment 4) > Changeset [03516346b4d5](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=03516346b4d5) made by Niels Nes <niels@cwi.nl> in the MonetDB repo, > refers to this bug. > > For complete details, see > [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=03516346b4d5](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=03516346b4d5) > > Changeset description: > > fixed bugs 3113 and 3114 > > 3113: single column indices aren't stored, ie don't have updates > > 3114: properly use the update 'column expression' instead of the original > column expression. ## Comment 17478 Date: 2012-07-17 13:46:40 +0200 From: @grobian Fix delivered in Jul2012 release
Cannot set value of indexed column when doing UPDATE
https://api.github.com/repos/MonetDB/MonetDB/issues/3113/comments
0
2020-11-30T12:11:41Z
2024-06-27T11:56:57Z
https://github.com/MonetDB/MonetDB/issues/3113
753,425,981
3,113
[ "MonetDB", "MonetDB" ]
Date: 2012-07-05 14:12:45 +0200 From: @mlkersten To: SQL devs &lt;<bugs-sql>&gt; Version: 11.11.5 (Jul2012) CC: @njnes Last updated: 2012-07-17 13:46:39 +0200 ## Comment 17412 Date: 2012-07-05 14:12:45 +0200 From: @mlkersten User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:13.0) Gecko/20100101 Firefox/13.0 Build Identifier: It appears that the SQL median() function does not produce the split anticipated. Moreover, there is an average over dates missing. Reproducible: Always ### Steps to Reproduce: sql>select min(departure_date) from voyages; +------------+ | L1 | +============+ | 1595-04-02 | +------------+ 1 tuple (1.724ms) sql>select max(departure_date) from voyages; +------------+ | L1 | +============+ | 1796-10-19 | +------------+ 1 tuple (1.921ms) sql>select avg(departure_date) from voyages; types date(0,0) and double(53,0) are not equal for column 'departure_date' sql>select median(departure_date) from voyages; +------------+ | L1 | +============+ | 1770-02-23 | +------------+ 1 tuple (5.759ms) sql>select count(*) from voyages where departure_date < date '1770-02-23'; +------+ | L1 | +======+ | 6836 | +------+ 1 tuple (2.758ms) sql>select count(*) from voyages where departure_date >= date '1770-02-23'; +------+ | L1 | +======+ | 1279 | +------+ 1 tuple (2.359ms) ## Comment 17420 Date: 2012-07-06 13:42:18 +0200 From: @njnes median part is fixed. ## Comment 17474 Date: 2012-07-17 13:46:39 +0200 From: @grobian Fix delivered in Jul2012 release
Median over temporal domains
https://api.github.com/repos/MonetDB/MonetDB/issues/3112/comments
0
2020-11-30T12:11:39Z
2024-06-27T11:56:56Z
https://github.com/MonetDB/MonetDB/issues/3112
753,425,952
3,112
[ "MonetDB", "MonetDB" ]
Date: 2012-07-03 13:47:14 +0200 From: info To: Merovingian devs &lt;<bugs-merovingian>&gt; Version: 11.9.7 (Apr2012-SP2) [obsolete] Last updated: 2012-07-17 13:57:41 +0200 ## Comment 17402 Date: 2012-07-03 13:47:14 +0200 From: info User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:13.0) Gecko/20100101 Firefox/13.0.1 Build Identifier: Ubuntu 10.04 LTS Dear MonetDB team, For our project we are using monetdb, we want to make a jump from our current version: monetdb release monetdb-hg-april_11.3.4-1_bed1350dc1be to the MonetDB (Apr2012-SP2) release. To make this a succesful “jump” we are currently testing the MonetDB (Apr2012-SP2) release on Ubuntu 10.04.2 LTS , 64 bits. To get more insight information about the problems we did run the tests with Valgrind, the following issues where reported when using the "monetdb set" commando: ==31739== HEAP SUMMARY: ==31739==     in use at exit: 21,276 bytes in 239 blocks ==31739==   total heap usage: 6,158 allocs, 5,920 frees, 6,465,213 bytes allocated ==31739== ==31739== Searching for pointers to 239 not-freed blocks ==31739== Checked 456,600 bytes ==31739== ==31739== 4,018 bytes in 98 blocks are definitely lost in loss record 13 of 14 ==31739==    at 0x4C274A8: malloc (vg_replace_malloc.c:236) ==31739==    by 0x54EAD81: strdup (strdup.c:43) ==31739==    by 0x50467F7: mcrypt_hashPassword (in /data/programs/MonetDB/lib/libmapi.so.6.0.1) ==31739==    by 0x40A855: control_authorise (in /data/programs/MonetDB/bin/monetdbd) ==31739==    by 0x409A11: ??? (in /data/programs/MonetDB/bin/monetdbd) ==31739==    by 0x409EA2: acceptConnections (in /data/programs/MonetDB/bin/monetdbd) ==31739==    by 0x40752A: main (in /data/programs/MonetDB/bin/monetdbd) ==31739== ==31739== 11,760 bytes in 49 blocks are definitely lost in loss record 14 of 14 ==31739==    at 0x4C274A8: malloc (vg_replace_malloc.c:236) ==31739==    by 0x4141CD: getDefaultProps (in /data/programs/MonetDB/bin/monetdbd) ==31739==    by 0x41463D: setProp (in /data/programs/MonetDB/bin/monetdbd) ==31739==    by 0x40B61A: ??? (in /data/programs/MonetDB/bin/monetdbd) ==31739==    by 0x409A28: ??? (in /data/programs/MonetDB/bin/monetdbd) ==31739==    by 0x409EA2: acceptConnections (in /data/programs/MonetDB/bin/monetdbd) ==31739==    by 0x40752A: main (in /data/programs/MonetDB/bin/monetdbd) ==31739== ==31739== LEAK SUMMARY: ==31739==    definitely lost: 15,778 bytes in 147 blocks ==31739==    indirectly lost: 0 bytes in 0 blocks ==31739==      possibly lost: 0 bytes in 0 blocks ==31739==    still reachable: 5,498 bytes in 92 blocks ==31739==         suppressed: 0 bytes in 0 blocks ==31739== Reachable blocks (those to which a pointer was found) are not shown. ==31739== To see them, rerun with: --leak-check=full --show-reachable=yes Using the "monetdb set" command multiple times shows an increase in the “definitely lost” memory blocks. Investigating the monetdb sources we found the following: In monetdb.c the value of the variable props (assigned via confkeyval *props = getDefaultProps();) allocates memory that IS free-ed as expected. But the variable defprops (assigned via confkeyval *defprops = getDefaultProps();) allocs memory that IS NOT free-ed. If we understand it correctly than there seems to be a problem in this piece of code. Something similar is happening when we use the "monetdb get" command, below the Valgrind report for this: ==32049== HEAP SUMMARY: ==32049==     in use at exit: 6,895 bytes in 101 blocks ==32049==   total heap usage: 563 allocs, 463 frees, 533,667 bytes allocated ==32049== ==32049== Searching for pointers to 101 not-freed blocks ==32049== Checked 456,600 bytes ==32049== ==32049== 202 bytes in 1 blocks are definitely lost in loss record 4 of 15 ==32049==    at 0x4C274A8: malloc (vg_replace_malloc.c:236) ==32049==    by 0x4143ED: writePropsBuf (in /data/programs/MonetDB/bin/monetdbd) ==32049==    by 0x40BDA8: ??? (in /data/programs/MonetDB/bin/monetdbd) ==32049==    by 0x40C884: controlRunner (in /data/programs/MonetDB/bin/monetdbd) ==32049==    by 0x52519C9: start_thread (pthread_create.c:300) ==32049==    by 0x7E4E6FF: ??? ==32049== ==32049== 1,195 bytes in 8 blocks are definitely lost in loss record 15 of 15 ==32049==    at 0x4C274A8: malloc (vg_replace_malloc.c:236) ==32049==    by 0x4143ED: writePropsBuf (in /data/programs/MonetDB/bin/monetdbd) ==32049==    by 0x40C29A: ??? (in /data/programs/MonetDB/bin/monetdbd) ==32049==    by 0x40C884: controlRunner (in /data/programs/MonetDB/bin/monetdbd) ==32049==    by 0x52519C9: start_thread (pthread_create.c:300) ==32049==    by 0x7E4E6FF: ??? ==32049== ==32049== LEAK SUMMARY: ==32049==    definitely lost: 1,397 bytes in 9 blocks ==32049==    indirectly lost: 0 bytes in 0 blocks ==32049==      possibly lost: 0 bytes in 0 blocks ==32049==    still reachable: 5,498 bytes in 92 blocks ==32049==         suppressed: 0 bytes in 0 blocks ==32049== Reachable blocks (those to which a pointer was found) are not shown. ==32049== To see them, rerun with: --leak-check=full --show-reachable=yes It seems that in module controlrunner.c the claimed memory for the variable pbuf IS NOT free-ed after calling: writePropsBuf(_mero_db_props, &pbuf); writePropsBuf(props, &pbuf); inside function: static void ctl_handle_client(         const char *origin,         int msgsock,         stream *fdin,         stream *fout) We hope this information is useful for monetdb, unfortunately for our project it seems that using the current release is not (yet) suitable to us. regards and keep up the good work ! Reproducible: Always ## Comment 17403 Date: 2012-07-03 13:48:21 +0200 From: info sorry for the messy formatting ;) ## Comment 17404 Date: 2012-07-03 13:49:25 +0200 From: @grobian thank you! this is a blocker for the Jul2012 release ## Comment 17418 Date: 2012-07-06 10:31:04 +0200 From: @grobian Changeset [87e8d77d05df](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=87e8d77d05df) made by Fabian Groffen <fabian@cwi.nl> in the MonetDB repo, refers to this bug. For complete details, see [http//devmonetdborg/hg/MonetDB?cmd=changeset;node=87e8d77d05df](https://dev.monetdb.org/hg/MonetDB?cmd=changeset;node=http//devmonetdborg/hg/MonetDB?cmd=changeset;node=87e8d77d05df) Changeset description: monetdbd: fix misc memory leaks - the result from getDefaultProps() is malloced and needs to be freed - the result from writePropsBuf() is malloced and needs to be freed This keeps the memory usage of monetdbd constant over several monetdb get, set, status and inherit calls. Thanks Patchupedia in Bug #3111. ## Comment 17480 Date: 2012-07-17 13:57:41 +0200 From: @grobian Fix released in Jul2012
memory leak, monetdb set/get command
https://api.github.com/repos/MonetDB/MonetDB/issues/3111/comments
0
2020-11-30T12:11:36Z
2024-06-27T11:56:55Z
https://github.com/MonetDB/MonetDB/issues/3111
753,425,910
3,111