English 中文(简体)
克莱伯顿-科尔索尔-JAVA
原标题:In-memory log buffer size in BerkeleyDB-Core-JAVA

I m using in-memory log buffer in Berkeley BerkeleyDB-Core-JAVA edition. I have CDRFile of 9 lack records. When I am writing CDRFile in database in durable database environment(i.e log files are created) then total 1.08gb of log files are created and when I am setting this two parameters of in memory log buffer:

envconfig.setLogInMemory(true);
envconfig.setLogBufferSize(1181116006); // 1.10 gb

i m 出现错误,如:

-------------------------error----------------
PANIC: Not enough space
PANIC: DB_RUNRECOVERY: Fatal error, run database recovery
unable to join the environment
DataBase Exceptioncom.sleepycat.db.RunRecoveryException: DB_RUNRECOVERY: Fatal error,
run database recovery: PANIC: DB_RUNRECOVERY: Fatal error, run database recovery
unable to join the environment: DB_RUNRECOVERY: Fatal error, run database recovery
Writing DataBase Exception--->java.lang.NullPointerException
 ------------------------------error----------------------

因此,我认为,如果在磁盘上设定1个目录,那么我还必须将1gb的空间放在缓冲记忆中,用于记录档案。

问题回答

这类问题通常可在伯克利分行forum for BDB JE on OTN。

Based on your error message, it looks like you re using Berkeley DB (core) via the Java API. My guess is that you re running out of log buffer space. In Berkeley DB the default size for an in-memory log buffer is 1MB. You can either extend the log buffer to be larger by calling DB_ENV->set_lg_bsize() in C or setlogBufferSize in Java. Otherwise, you can break up the transaction into smaller chunks so that you don t exceed the size of the log buffer in a single transaction.

Do you experience this problem when you don t create the log file in-memory, if you use a smaller transaction or if you allocated a larger in-memory log buffer?

我希望这一帮助。

关于

纽约总部





相关问题
Spring Properties File

Hi have this j2ee web application developed using spring framework. I have a problem with rendering mnessages in nihongo characters from the properties file. I tried converting the file to ascii using ...

Logging a global ID in multiple components

I have a system which contains multiple applications connected together using JMS and Spring Integration. Messages get sent along a chain of applications. [App A] -> [App B] -> [App C] We set a ...

Java Library Size

If I m given two Java Libraries in Jar format, 1 having no bells and whistles, and the other having lots of them that will mostly go unused.... my question is: How will the larger, mostly unused ...

How to get the Array Class for a given Class in Java?

I have a Class variable that holds a certain type and I need to get a variable that holds the corresponding array class. The best I could come up with is this: Class arrayOfFooClass = java.lang....

SQLite , Derby vs file system

I m working on a Java desktop application that reads and writes from/to different files. I think a better solution would be to replace the file system by a SQLite database. How hard is it to migrate ...

热门标签