[MonetDB-users] server does not start anymore
Hello! For some testing purposes, I created a file with 63.158.399 rows and tried to load it into a table with following structure: create table logtest ( id bigint, dim_year smallint, dim_month smallint, dim_day smallint, dim_hour smallint, dim_min smallint, dim_sec smallint ); I loaded the data in pieces of 20.000.000 rows with the 'copy into' command. At the last 3158399 there was an error, the connection to the server terminated, the server crashed. I restarted the server and the error message ERROR: HEAPextend: failed to extend to 480000000 for 01\14\11401tail was displayed. I tried to restart again, but its not possible anymore, the server immediatly returns and there is no error message... C:\MonetDB\MonetDB5>MSQLserver.bat # MonetDB server v5.14.2, based on kernel v1.32.2 # Serving database 'demo', using 1 thread # Compiled for i686-pc-win32/32bit with 32bit OIDs dynamically linked # Copyright (c) 1993-July 2008 CWI. # Copyright (c) August 2008-2009 MonetDB B.V., all rights reserved # Visit http://monetdb.cwi.nl/ for further information #warning: please don't forget to set your vault key! #(see C:\MonetDB\MonetDB5\etc\monetdb5.conf) # Listening for connection requests on mapi:monetdb://127.0.0.1:50000/ # MonetDB/SQL module v2.32.2 loaded I know I can reinstall the server, but I would like to know the problem. Are there too much rows for the logtest table? There are about 10 other tables in the database, with 10 - 100 rows. As you can see from above, I'm using windows vista, 32 bit... The current size of the dbfarm folder is 1,52 GB, and the size of the file I tried to load is 1,72 GB. Thank you, Wilfried
Hi Wilfried, first of all, there should be no need to re-install the MonetDB. Just starting the server with a different than the default "demo" database, e.g., C:\MonetDB\MonetDB5>MSQLserver.bat --dbname=MyDB shoudl get the sevrer working, again --- on a virgin empty database, though. Alternatively, you could remove your dbfarm --- with obviously the same effect. My assumption is, that the server now fails to start on the default "demo" database, as it fails to replay the write ahead log that remained after the first crash duing the load. Obviously, this should not happen, but I'm afraid, we'd need to have (access to) your data (i.e., your dbfarm\demo as it is now, and your (or an identical) machine to analyse the situation in detail... Talking about your machine, how much memory does your 32-bit Windows machine have? Your tuples are 20 bytes (8+6*2) wide; with all 63.158.399 rows, your table requires (at least) 1 GB of memory (or address space, to be precise). On 32-bit systems, in partivular Windows with its sensitivity to address space fragmentation, it could well be that the initial error during bulk load (do you still have that error message somewhere?) occured as MonetDB could not extend the storage for additional data due to memory fragmentation, i.e., no consequtive range of the required size was available any more. At least the error with the first restart after the initial error (when Mserver (tried to) replay the WAL) seems to indicate this. Instead of loading your data in chunks of 20.000.000 rows, could you try to either load it in one chuck (indicating with the COPY INTO command that you want to load 63.158.399 rows, or do it in chuck as before (assuming that each chuck comes from a seperate file), but inidicate with the first chunk's COPY INTO that you want to load 63.158.399 rows. This should keep MonetDB from the need to extend the storage once more data comes, as it allocated sufficient storage initially. This in turn should --- in particular on 32-bit Windows systems --- reduce memory fragmentation and subsequent allocation problems. Please report your experiemces, and don't hesitate to contact us again, in case you have more questions. Kind regards, Stefan On Fri, Oct 23, 2009 at 04:54:11PM +0200, wilfried@hafner.ws wrote:
Hello!
For some testing purposes, I created a file with 63.158.399 rows and tried to load it into a table with following structure:
create table logtest ( id bigint, dim_year smallint, dim_month smallint, dim_day smallint, dim_hour smallint, dim_min smallint, dim_sec smallint );
I loaded the data in pieces of 20.000.000 rows with the 'copy into' command. At the last 3158399 there was an error, the connection to the server terminated, the server crashed.
I restarted the server and the error message
ERROR: HEAPextend: failed to extend to 480000000 for 01\14\11401tail
was displayed. I tried to restart again, but its not possible anymore, the server immediatly returns and there is no error message...
C:\MonetDB\MonetDB5>MSQLserver.bat # MonetDB server v5.14.2, based on kernel v1.32.2 # Serving database 'demo', using 1 thread # Compiled for i686-pc-win32/32bit with 32bit OIDs dynamically linked # Copyright (c) 1993-July 2008 CWI. # Copyright (c) August 2008-2009 MonetDB B.V., all rights reserved # Visit http://monetdb.cwi.nl/ for further information #warning: please don't forget to set your vault key! #(see C:\MonetDB\MonetDB5\etc\monetdb5.conf) # Listening for connection requests on mapi:monetdb://127.0.0.1:50000/ # MonetDB/SQL module v2.32.2 loaded
I know I can reinstall the server, but I would like to know the problem. Are there too much rows for the logtest table? There are about 10 other tables in the database, with 10 - 100 rows. As you can see from above, I'm using windows vista, 32 bit...
The current size of the dbfarm folder is 1,52 GB, and the size of the file I tried to load is 1,72 GB.
Thank you, Wilfried
------------------------------------------------------------------------------ Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
-- | Dr. Stefan Manegold | mailto:Stefan.Manegold@cwi.nl | | CWI, P.O.Box 94079 | http://www.cwi.nl/~manegold/ | | 1090 GB Amsterdam | Tel.: +31 (20) 592-4212 | | The Netherlands | Fax : +31 (20) 592-4312 |
Hello Stefan, thank you for your response!
Hi Wilfried,
first of all, there should be no need to re-install the MonetDB.
Just starting the server with a different than the default "demo" database, e.g., C:\MonetDB\MonetDB5>MSQLserver.bat --dbname=MyDB shoudl get the sevrer working, again --- on a virgin empty database, though.
Alternatively, you could remove your dbfarm --- with obviously the same effect.
My assumption is, that the server now fails to start on the default "demo" database, as it fails to replay the write ahead log that remained after the first crash duing the load. Obviously, this should not happen, but I'm afraid, we'd need to have (access to) your data (i.e., your dbfarm\demo as it is now, and your (or an identical) machine to analyse the situation in detail...
Talking about your machine, how much memory does your 32-bit Windows machine have?
The server is running on my notebook, 2GB RAM, Intel Core 2 Duo 2.00 GHz and ~30GB of free diskspace.
Your tuples are 20 bytes (8+6*2) wide; with all 63.158.399 rows, your table requires (at least) 1 GB of memory (or address space, to be precise). On 32-bit systems, in partivular Windows with its sensitivity to address space fragmentation, it could well be that the initial error during bulk load (do you still have that error message somewhere?) occured as MonetDB could not extend the storage for additional data due to memory fragmentation, i.e., no consequtive range of the required size was available any more. At least the error with the first restart after the initial error (when Mserver (tried to) replay the WAL) seems to indicate this.
Instead of loading your data in chunks of 20.000.000 rows, could you try to either load it in one chuck (indicating with the COPY INTO command that you want to load 63.158.399 rows, or do it in chuck as before (assuming that each chuck comes from a seperate file), but inidicate with the first chunk's COPY INTO that you want to load 63.158.399 rows. This should keep MonetDB from the need to extend the storage once more data comes, as it allocated sufficient storage initially. This in turn should --- in particular on 32-bit Windows systems --- reduce memory fragmentation and subsequent allocation problems.
When I try to load the data in one chunk, I get the following error message: 0 tuples MALException:!ERROR: HEAPalloc: Insufficient space for HEAP of 521142272 bytes. ERROR: HEAPalloc: Insufficient space for HEAP of 521142272 bytes. ERROR: HEAPalloc: Insufficient space for HEAP of 521142272 bytes. ERROR: HEAPalloc: Insufficient space for HEAP of 521142272 bytes. ERROR: HEAPalloc: Insufficient space for HEAP of 521142272 bytes. Timer 405470.179 msec 0 rows The server does not crash... Now I did the next test with a new database and created a file with 21.500.000 rows. It was possible to load the data two times, so there are 43.000.000 tuples in the table. At the first attempt, the third load worked too but not a select statement: sql>copy 21500000 records into em_test more>from 'F:\datamin.csv' more> USING DELIMITERS ';'; 21500000 affected rows Timer 163243.755 msec 1 rows sql>select count(*) from em_test; MALException:!ERROR: HEAPextend: failed to extend to 516000000 for 07\764tail Timer 3.229 msec 1 rows sql>select count(*) from em_test; +----------+ | L7 | +==========+ | 43000000 | +----------+ 1 tuple Timer 27.998 msec 1 rows so I tried to load the data again: sql>copy 21500000 records into em_test more>from 'F:\datamin.csv' more> USING DELIMITERS ';'; MAPI = monetdb@localhost:50000 ACTION= read_line QUERY = copy 21500000 records into em_test ERROR = !Connection terminated Timer 139604.192 msec 1 rows Drücken Sie eine beliebige Taste . . . The server is not running anymore, no additional output. Now I started the server again and got the following output: # MonetDB server v5.14.2, based on kernel v1.32.2 # Serving database 'MyDB2', using 1 thread # Compiled for i686-pc-win32/32bit with 32bit OIDs dynamically linked # Copyright (c) 1993-July 2008 CWI. # Copyright (c) August 2008-2009 MonetDB B.V., all rights reserved # Visit http://monetdb.cwi.nl/ for further information #warning: please don't forget to set your vault key! #(see C:\MonetDB\MonetDB5\etc\monetdb5.conf) # Listening for connection requests on mapi:monetdb://127.0.0.1:50000/ # MonetDB/SQL module v2.32.2 loaded #GDKmmap(516423680) fails, try to free up space [memory in use=435475296,virtual memory in use=1094057984] #GDKmmap(516423680) result [mem=435475152,vm=575012864] !mvc_init: unable to create system tables !SQLException:SQLinit:Catalogue initialization failed !ERROR: HEAPextend: failed to extend to 516000000 for 07\764tail #function user.main():void; # sql.prelude(); #end main;
the reconnect failed: F:\monetdb\bin>mclient.bat -lsql -dMyDB2 -umonetdb --time password:monetdb MALException:setScenario:Scenario not initialized 'sql' now I tried to restart the server, but it was not possible anymore with the given database. Maybe there is some useful information for you? Kind Regards, Wilfried
Please report your experiemces, and don't hesitate to contact us again, in case you have more questions.
Kind regards, Stefan
On Fri, Oct 23, 2009 at 04:54:11PM +0200, wilfried@hafner.ws wrote:
Hello!
For some testing purposes, I created a file with 63.158.399 rows and tried to load it into a table with following structure:
create table logtest ( id bigint, dim_year smallint, dim_month smallint, dim_day smallint, dim_hour smallint, dim_min smallint, dim_sec smallint );
I loaded the data in pieces of 20.000.000 rows with the 'copy into' command. At the last 3158399 there was an error, the connection to the server terminated, the server crashed.
I restarted the server and the error message
ERROR: HEAPextend: failed to extend to 480000000 for 01\14\11401tail
was displayed. I tried to restart again, but its not possible anymore, the server immediatly returns and there is no error message...
C:\MonetDB\MonetDB5>MSQLserver.bat # MonetDB server v5.14.2, based on kernel v1.32.2 # Serving database 'demo', using 1 thread # Compiled for i686-pc-win32/32bit with 32bit OIDs dynamically linked # Copyright (c) 1993-July 2008 CWI. # Copyright (c) August 2008-2009 MonetDB B.V., all rights reserved # Visit http://monetdb.cwi.nl/ for further information #warning: please don't forget to set your vault key! #(see C:\MonetDB\MonetDB5\etc\monetdb5.conf) # Listening for connection requests on mapi:monetdb://127.0.0.1:50000/ # MonetDB/SQL module v2.32.2 loaded
I know I can reinstall the server, but I would like to know the problem. Are there too much rows for the logtest table? There are about 10 other tables in the database, with 10 - 100 rows. As you can see from above, I'm using windows vista, 32 bit...
The current size of the dbfarm folder is 1,52 GB, and the size of the file I tried to load is 1,72 GB.
Thank you, Wilfried
------------------------------------------------------------------------------ Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
-- | Dr. Stefan Manegold | mailto:Stefan.Manegold@cwi.nl | | CWI, P.O.Box 94079 | http://www.cwi.nl/~manegold/ | | 1090 GB Amsterdam | Tel.: +31 (20) 592-4212 | | The Netherlands | Fax : +31 (20) 592-4312 |
------------------------------------------------------------------------------ Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
Hi Wilfried, thank you very much for your detailed report. All the HEAPalloc & HEAP extend error messages you get indicate that MonetDB is running out of address space --- whether this is "unavoidable", i.e., whether MonetDB tries to allocate more memory/address space than strictly necessary is not clear, yet. We recently fixed a related problem in CVS. The fix wil be available in the coming Aug2009-SP2 bugfix release, which we hope to release next week. There is a slight change (no guarantee, though) that this improves your situation. Alternatively, would you be able to install a 64-bit Windows on your 64-bit Core 2 Duo notebook? Provided we find time in our agendas to analyse the problem in more detail, would you be able to provide us with your data? Regards, Stefan On Sat, Oct 24, 2009 at 01:16:52AM +0200, wilfried@hafner.ws wrote:
Hello Stefan,
thank you for your response!
Hi Wilfried,
first of all, there should be no need to re-install the MonetDB.
Just starting the server with a different than the default "demo" database, e.g., C:\MonetDB\MonetDB5>MSQLserver.bat --dbname=MyDB shoudl get the sevrer working, again --- on a virgin empty database, though.
Alternatively, you could remove your dbfarm --- with obviously the same effect.
My assumption is, that the server now fails to start on the default "demo" database, as it fails to replay the write ahead log that remained after the first crash duing the load. Obviously, this should not happen, but I'm afraid, we'd need to have (access to) your data (i.e., your dbfarm\demo as it is now, and your (or an identical) machine to analyse the situation in detail...
Talking about your machine, how much memory does your 32-bit Windows machine have?
The server is running on my notebook, 2GB RAM, Intel Core 2 Duo 2.00 GHz and ~30GB of free diskspace.
Your tuples are 20 bytes (8+6*2) wide; with all 63.158.399 rows, your table requires (at least) 1 GB of memory (or address space, to be precise). On 32-bit systems, in partivular Windows with its sensitivity to address space fragmentation, it could well be that the initial error during bulk load (do you still have that error message somewhere?) occured as MonetDB could not extend the storage for additional data due to memory fragmentation, i.e., no consequtive range of the required size was available any more. At least the error with the first restart after the initial error (when Mserver (tried to) replay the WAL) seems to indicate this.
Instead of loading your data in chunks of 20.000.000 rows, could you try to either load it in one chuck (indicating with the COPY INTO command that you want to load 63.158.399 rows, or do it in chuck as before (assuming that each chuck comes from a seperate file), but inidicate with the first chunk's COPY INTO that you want to load 63.158.399 rows. This should keep MonetDB from the need to extend the storage once more data comes, as it allocated sufficient storage initially. This in turn should --- in particular on 32-bit Windows systems --- reduce memory fragmentation and subsequent allocation problems.
When I try to load the data in one chunk, I get the following error message:
0 tuples MALException:!ERROR: HEAPalloc: Insufficient space for HEAP of 521142272 bytes. ERROR: HEAPalloc: Insufficient space for HEAP of 521142272 bytes. ERROR: HEAPalloc: Insufficient space for HEAP of 521142272 bytes. ERROR: HEAPalloc: Insufficient space for HEAP of 521142272 bytes. ERROR: HEAPalloc: Insufficient space for HEAP of 521142272 bytes. Timer 405470.179 msec 0 rows
The server does not crash...
Now I did the next test with a new database and created a file with 21.500.000 rows. It was possible to load the data two times, so there are 43.000.000 tuples in the table. At the first attempt, the third load worked too but not a select statement:
sql>copy 21500000 records into em_test more>from 'F:\datamin.csv' more> USING DELIMITERS ';'; 21500000 affected rows Timer 163243.755 msec 1 rows sql>select count(*) from em_test; MALException:!ERROR: HEAPextend: failed to extend to 516000000 for 07\764tail Timer 3.229 msec 1 rows sql>select count(*) from em_test; +----------+ | L7 | +==========+ | 43000000 | +----------+ 1 tuple Timer 27.998 msec 1 rows
so I tried to load the data again:
sql>copy 21500000 records into em_test more>from 'F:\datamin.csv' more> USING DELIMITERS ';'; MAPI = monetdb@localhost:50000 ACTION= read_line QUERY = copy 21500000 records into em_test ERROR = !Connection terminated Timer 139604.192 msec 1 rows Drücken Sie eine beliebige Taste . . .
The server is not running anymore, no additional output. Now I started the server again and got the following output:
# MonetDB server v5.14.2, based on kernel v1.32.2 # Serving database 'MyDB2', using 1 thread # Compiled for i686-pc-win32/32bit with 32bit OIDs dynamically linked # Copyright (c) 1993-July 2008 CWI. # Copyright (c) August 2008-2009 MonetDB B.V., all rights reserved # Visit http://monetdb.cwi.nl/ for further information #warning: please don't forget to set your vault key! #(see C:\MonetDB\MonetDB5\etc\monetdb5.conf) # Listening for connection requests on mapi:monetdb://127.0.0.1:50000/ # MonetDB/SQL module v2.32.2 loaded #GDKmmap(516423680) fails, try to free up space [memory in use=435475296,virtual memory in use=1094057984] #GDKmmap(516423680) result [mem=435475152,vm=575012864] !mvc_init: unable to create system tables !SQLException:SQLinit:Catalogue initialization failed !ERROR: HEAPextend: failed to extend to 516000000 for 07\764tail #function user.main():void; # sql.prelude(); #end main;
the reconnect failed:
F:\monetdb\bin>mclient.bat -lsql -dMyDB2 -umonetdb --time password:monetdb MALException:setScenario:Scenario not initialized 'sql'
now I tried to restart the server, but it was not possible anymore with the given database.
Maybe there is some useful information for you?
Kind Regards, Wilfried
Please report your experiemces, and don't hesitate to contact us again, in case you have more questions.
Kind regards, Stefan
On Fri, Oct 23, 2009 at 04:54:11PM +0200, wilfried@hafner.ws wrote:
Hello!
For some testing purposes, I created a file with 63.158.399 rows and tried to load it into a table with following structure:
create table logtest ( id bigint, dim_year smallint, dim_month smallint, dim_day smallint, dim_hour smallint, dim_min smallint, dim_sec smallint );
I loaded the data in pieces of 20.000.000 rows with the 'copy into' command. At the last 3158399 there was an error, the connection to the server terminated, the server crashed.
I restarted the server and the error message
ERROR: HEAPextend: failed to extend to 480000000 for 01\14\11401tail
was displayed. I tried to restart again, but its not possible anymore, the server immediatly returns and there is no error message...
C:\MonetDB\MonetDB5>MSQLserver.bat # MonetDB server v5.14.2, based on kernel v1.32.2 # Serving database 'demo', using 1 thread # Compiled for i686-pc-win32/32bit with 32bit OIDs dynamically linked # Copyright (c) 1993-July 2008 CWI. # Copyright (c) August 2008-2009 MonetDB B.V., all rights reserved # Visit http://monetdb.cwi.nl/ for further information #warning: please don't forget to set your vault key! #(see C:\MonetDB\MonetDB5\etc\monetdb5.conf) # Listening for connection requests on mapi:monetdb://127.0.0.1:50000/ # MonetDB/SQL module v2.32.2 loaded
I know I can reinstall the server, but I would like to know the problem. Are there too much rows for the logtest table? There are about 10 other tables in the database, with 10 - 100 rows. As you can see from above, I'm using windows vista, 32 bit...
The current size of the dbfarm folder is 1,52 GB, and the size of the file I tried to load is 1,72 GB.
Thank you, Wilfried
------------------------------------------------------------------------------ Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
-- | Dr. Stefan Manegold | mailto:Stefan.Manegold@cwi.nl | | CWI, P.O.Box 94079 | http://www.cwi.nl/~manegold/ | | 1090 GB Amsterdam | Tel.: +31 (20) 592-4212 | | The Netherlands | Fax : +31 (20) 592-4312 |
------------------------------------------------------------------------------ Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
------------------------------------------------------------------------------ Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
-- | Dr. Stefan Manegold | mailto:Stefan.Manegold@cwi.nl | | CWI, P.O.Box 94079 | http://www.cwi.nl/~manegold/ | | 1090 GB Amsterdam | Tel.: +31 (20) 592-4212 | | The Netherlands | Fax : +31 (20) 592-4312 |
Hi Stefan,
I should get a new server system with 4GB RAM next week, currently I
don't know if there is a 64-bit or a 32-bit OS, if there is a 32-bit
installation I will change it to 64... I will do the same tests on it,
and I will try the same on another notebook too.
I can give you the data I used, should I upload it somewhere and post
the link?
Thank you for your explanations!
Wilfried
Zitat von Stefan Manegold
Hi Wilfried,
thank you very much for your detailed report.
All the HEAPalloc & HEAP extend error messages you get indicate that MonetDB is running out of address space --- whether this is "unavoidable", i.e., whether MonetDB tries to allocate more memory/address space than strictly necessary is not clear, yet. We recently fixed a related problem in CVS. The fix wil be available in the coming Aug2009-SP2 bugfix release, which we hope to release next week. There is a slight change (no guarantee, though) that this improves your situation.
Alternatively, would you be able to install a 64-bit Windows on your 64-bit Core 2 Duo notebook?
Provided we find time in our agendas to analyse the problem in more detail, would you be able to provide us with your data?
Regards, Stefan
On Sat, Oct 24, 2009 at 01:16:52AM +0200, wilfried@hafner.ws wrote:
Hello Stefan,
thank you for your response!
Hi Wilfried,
first of all, there should be no need to re-install the MonetDB.
Just starting the server with a different than the default "demo" database, e.g., C:\MonetDB\MonetDB5>MSQLserver.bat --dbname=MyDB shoudl get the sevrer working, again --- on a virgin empty database, though.
Alternatively, you could remove your dbfarm --- with obviously the same effect.
My assumption is, that the server now fails to start on the default "demo" database, as it fails to replay the write ahead log that remained after the first crash duing the load. Obviously, this should not happen, but I'm afraid, we'd need to have (access to) your data (i.e., your dbfarm\demo as it is now, and your (or an identical) machine to analyse the situation in detail...
Talking about your machine, how much memory does your 32-bit Windows machine have?
The server is running on my notebook, 2GB RAM, Intel Core 2 Duo 2.00 GHz and ~30GB of free diskspace.
Your tuples are 20 bytes (8+6*2) wide; with all 63.158.399 rows, your table requires (at least) 1 GB of memory (or address space, to be precise). On 32-bit systems, in partivular Windows with its sensitivity to address space fragmentation, it could well be that the initial error during bulk load (do you still have that error message somewhere?) occured as MonetDB could not extend the storage for additional data due to memory fragmentation, i.e., no consequtive range of the required size was available any more. At least the error with the first restart after the initial error (when Mserver (tried to) replay the WAL) seems to indicate this.
Instead of loading your data in chunks of 20.000.000 rows, could you try to either load it in one chuck (indicating with the COPY INTO command that you want to load 63.158.399 rows, or do it in chuck as before (assuming that each chuck comes from a seperate file), but inidicate with the first chunk's COPY INTO that you want to load 63.158.399 rows. This should keep MonetDB from the need to extend the storage once more data comes, as it allocated sufficient storage initially. This in turn should --- in particular on 32-bit Windows systems --- reduce memory fragmentation and subsequent allocation problems.
When I try to load the data in one chunk, I get the following error message:
0 tuples MALException:!ERROR: HEAPalloc: Insufficient space for HEAP of 521142272 bytes. ERROR: HEAPalloc: Insufficient space for HEAP of 521142272 bytes. ERROR: HEAPalloc: Insufficient space for HEAP of 521142272 bytes. ERROR: HEAPalloc: Insufficient space for HEAP of 521142272 bytes. ERROR: HEAPalloc: Insufficient space for HEAP of 521142272 bytes. Timer 405470.179 msec 0 rows
The server does not crash...
Now I did the next test with a new database and created a file with 21.500.000 rows. It was possible to load the data two times, so there are 43.000.000 tuples in the table. At the first attempt, the third load worked too but not a select statement:
sql>copy 21500000 records into em_test more>from 'F:\datamin.csv' more> USING DELIMITERS ';'; 21500000 affected rows Timer 163243.755 msec 1 rows sql>select count(*) from em_test; MALException:!ERROR: HEAPextend: failed to extend to 516000000 for 07\764tail Timer 3.229 msec 1 rows sql>select count(*) from em_test; +----------+ | L7 | +==========+ | 43000000 | +----------+ 1 tuple Timer 27.998 msec 1 rows
so I tried to load the data again:
sql>copy 21500000 records into em_test more>from 'F:\datamin.csv' more> USING DELIMITERS ';'; MAPI = monetdb@localhost:50000 ACTION= read_line QUERY = copy 21500000 records into em_test ERROR = !Connection terminated Timer 139604.192 msec 1 rows Drücken Sie eine beliebige Taste . . .
The server is not running anymore, no additional output. Now I started the server again and got the following output:
# MonetDB server v5.14.2, based on kernel v1.32.2 # Serving database 'MyDB2', using 1 thread # Compiled for i686-pc-win32/32bit with 32bit OIDs dynamically linked # Copyright (c) 1993-July 2008 CWI. # Copyright (c) August 2008-2009 MonetDB B.V., all rights reserved # Visit http://monetdb.cwi.nl/ for further information #warning: please don't forget to set your vault key! #(see C:\MonetDB\MonetDB5\etc\monetdb5.conf) # Listening for connection requests on mapi:monetdb://127.0.0.1:50000/ # MonetDB/SQL module v2.32.2 loaded #GDKmmap(516423680) fails, try to free up space [memory in use=435475296,virtual memory in use=1094057984] #GDKmmap(516423680) result [mem=435475152,vm=575012864] !mvc_init: unable to create system tables !SQLException:SQLinit:Catalogue initialization failed !ERROR: HEAPextend: failed to extend to 516000000 for 07\764tail #function user.main():void; # sql.prelude(); #end main;
the reconnect failed:
F:\monetdb\bin>mclient.bat -lsql -dMyDB2 -umonetdb --time password:monetdb MALException:setScenario:Scenario not initialized 'sql'
now I tried to restart the server, but it was not possible anymore with the given database.
Maybe there is some useful information for you?
Kind Regards, Wilfried
Please report your experiemces, and don't hesitate to contact us again, in case you have more questions.
Kind regards, Stefan
On Fri, Oct 23, 2009 at 04:54:11PM +0200, wilfried@hafner.ws wrote:
Hello!
For some testing purposes, I created a file with 63.158.399 rows and tried to load it into a table with following structure:
create table logtest ( id bigint, dim_year smallint, dim_month smallint, dim_day smallint, dim_hour smallint, dim_min smallint, dim_sec smallint );
I loaded the data in pieces of 20.000.000 rows with the 'copy into' command. At the last 3158399 there was an error, the connection to the server terminated, the server crashed.
I restarted the server and the error message
ERROR: HEAPextend: failed to extend to 480000000 for 01\14\11401tail
was displayed. I tried to restart again, but its not possible anymore, the server immediatly returns and there is no error message...
C:\MonetDB\MonetDB5>MSQLserver.bat # MonetDB server v5.14.2, based on kernel v1.32.2 # Serving database 'demo', using 1 thread # Compiled for i686-pc-win32/32bit with 32bit OIDs dynamically linked # Copyright (c) 1993-July 2008 CWI. # Copyright (c) August 2008-2009 MonetDB B.V., all rights reserved # Visit http://monetdb.cwi.nl/ for further information #warning: please don't forget to set your vault key! #(see C:\MonetDB\MonetDB5\etc\monetdb5.conf) # Listening for connection requests on mapi:monetdb://127.0.0.1:50000/ # MonetDB/SQL module v2.32.2 loaded
I know I can reinstall the server, but I would like to know the problem. Are there too much rows for the logtest table? There are about 10 other tables in the database, with 10 - 100 rows. As you can see from above, I'm using windows vista, 32 bit...
The current size of the dbfarm folder is 1,52 GB, and the size of the file I tried to load is 1,72 GB.
Thank you, Wilfried
------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
-- | Dr. Stefan Manegold | mailto:Stefan.Manegold@cwi.nl | | CWI, P.O.Box 94079 | http://www.cwi.nl/~manegold/ | | 1090 GB Amsterdam | Tel.: +31 (20) 592-4212 | | The Netherlands | Fax : +31 (20) 592-4312 |
------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
------------------------------------------------------------------------------ Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
-- | Dr. Stefan Manegold | mailto:Stefan.Manegold@cwi.nl | | CWI, P.O.Box 94079 | http://www.cwi.nl/~manegold/ | | 1090 GB Amsterdam | Tel.: +31 (20) 592-4212 | | The Netherlands | Fax : +31 (20) 592-4312 |
------------------------------------------------------------------------------ Come build with us! The BlackBerry(R) Developer Conference in SF, CA is the only developer event you need to attend this year. Jumpstart your developing skills, take BlackBerry mobile applications to market and stay ahead of the curve. Join us from November 9 - 12, 2009. Register now! http://p.sf.net/sfu/devconference _______________________________________________ MonetDB-users mailing list MonetDB-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/monetdb-users
participants (2)
-
Stefan Manegold
-
wilfried@hafner.ws