Hi,

> I am using 4 GB cache size

But you specified CACHE_SIZE=8388608 which is 8 GB - see also
http://h2database.com/html/grammar.html#set_cache_size

Most likely you specified a cache size that is too large. Even if you
do have 8 GB RAM, it doesn't mean Java will and can address all the 8
GB as heap. If the cache size is larger than the maximum heap memory,
it will run out of memory. So you should use a smaller cache size, or
you need to use "java -Xmx8g ...". For example, try:

jdbc:h2:tcp://localhost/split:32:~/h2data/sc_file.db;PAGE_SIZE=16384

Regards,
Thomas


On Wed, Apr 27, 2011 at 11:24 AM, AI Rumman <[email protected]> wrote:
> I got the following error very often during data import:
>
> Error: org.h2.jdbc.JdbcSQLException: Out of memory. [90108-154]
>
> My db url:
>
> jdbc:h2:tcp://localhost/split:32:~/h2data/sc_file.db;PAGE_SIZE=16384;CACHE_SIZE=8388608
> and
> I started import with the following:
> SET TRACE_LEVEL_FILE 2;
> SET UNDO_LOG 0;
> SET LOG 0;
> SET LOCK_MODE 0;
>
> inert into testtab
> select * from ....
>
>
> The table has 34 columns.
>
> DB got lock when the import was executing. I can't create any session.
>
> Any idea please.
>
> --
> You received this message because you are subscribed to the Google Groups
> "H2 Database" group.
> To post to this group, send email to [email protected].
> To unsubscribe from this group, send email to
> [email protected].
> For more options, visit this group at
> http://groups.google.com/group/h2-database?hl=en.
>

-- 
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/h2-database?hl=en.

Reply via email to