Disk space never freed: a logical ref is keeped on a deleted BATs #3802
Last updated: 2015-11-03 10:18:42 +0100
Date: 2015-09-01 13:52:20 +0200
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:41.0) Gecko/20100101 Firefox/41.0 Iceweasel/41.0
When a table is created and filled in the same commit, a logical ref will continue to point to the bats after the table has been dropped, preventing the bat to be unlink.
Steps to Reproduce:
1.Create a csv with enough lines to trigger a flush.
2.Create tables with this script:
-- First table, with commit create and copy inside the same commit
CREATE TABLE "test" ("test" CHARACTER LARGE OBJECT);
COPY INTO "test" FROM '/tmp/test.csv';
-- Second table, with commit after create
CREATE TABLE "test2" ("test" CHARACTER LARGE OBJECT);
COPY INTO "test2" FROM '/tmp/test.csv';
SELECT location FROM storage where table like 'test%';
DROP TABLE "test";
DROP TABLE "test2";
-- Third table, just for flushing
CREATE TABLE "test3" ("test" CHARACTER LARGE OBJECT);
COPY INTO "test3" FROM '/tmp/test.csv';
After waiting 30 secondes for the flush to occur, the bats from test1 table are still present.
I have the following location from storage:
A ls bat/ give me this:
01 02 03 04 05 06 07 10 11 12 13 14 15 16 17 20 23 2.tail 2.theap 3.tail 3.theap 4.tail 4.theap 5.tail 6.tail BACKUP LEFTOVERS
Looking the bbp stats with "mdb.start(); bbp.get();", I have
 tmp_2 count=1000000 lrefs=1 refs=0 loaded tmp
The bat of the dropped table should be unlinked.
Date: 2015-10-14 18:46:01 +0200
For complete details, see http//devmonetdborg/hg/MonetDB?cmd=changeset;node=773e781c6a1b
Date: 2015-10-23 23:08:10 +0200
Reopen this bug, as it seems that the problem still exists with long running tests.
Date: 2015-10-23 23:26:00 +0200
Just add a cross-reference: see also this bug report: https://www.monetdb.org/bugzilla/show_bug.cgi?id=3835
Date: 2015-10-25 09:37:19 +0100
the scenario described in this bug report is fixed. Please report new leaks, with a new bug report, including a scenario which could be used to reproduce the leak consistently.
Date: 2015-11-03 10:18:42 +0100
Jul2015 SP1 has been released.
The text was updated successfully, but these errors were encountered: