berkeley db java使用

hmsuccess 2010-03-23 09:09:37
有没有使用过berkeley db java edition的高手,现有一个问题急需解决,特在此寻求帮助。

问题如下:
现需要向数据库中插入大概5000w条记录,数据项的key为String类型,data为自定义的A类型,处理的过程中发现数据库的日志文件(*.jdb)越来越大,直达50G,直接将我的硬盘撑爆,太恐怖了~~~,有没有解决的方法。

在此,先感谢所有提供意见的朋友!

我的je配置如下:

# If true (default is false) NIO is used for all file I/O.
je.log.useNIO=true

# If non-0 (default is 0) break all IO into chunks of this size.
# This setting is only used if je.log.useNIO=true.
# minimum = 0
# maximum = 67108864
je.log.chunkedNIO=8192

# If true (default is false) direct NIO buffers are used.
# This setting is only used if je.log.useNIO=true.
je.log.directNIO=true

# The maximum size of each individual JE log file, in bytes.
# minimum = 1000000
# maximum = 4294967296
# 100M
je.log.fileMax=104857600

# maximum starting size of a JE log buffer
# 32M
je.log.bufferSize=33554432

# The number of JE log buffers
# minimum = 2
je.log.numBuffers=2

# The total memory taken by log buffers, in bytes. If 0, use
# 7% of je.maxMemory
# minimum = 6144
# 32M * 2
je.log.totalBufferBytes=67108864

# By default, JE sizes the cache as a percentage of the maximum
# memory available to the JVM. For example, if the JVM is
# started with -Xmx128M, the cache size will be
# (je.maxMemoryPercent * 128M) / 100
# Setting je.maxMemory to an non-zero value will override
# je.maxMemoryPercent
# minimum = 1
# maximum = 90
je.maxMemoryPercent=60

# If true (the default), use an LRU-only policy to select nodes for
# eviction. If false, select by Btree level first, and then by LRU.
je.evictor.lruOnly=false

# The number of nodes in one evictor scan
# minimum = 1
# maximum = 1000
je.evictor.nodesPerScan=100

# The cleaner will keep the total disk space utilization percentage
# above this value. The default is set to 50 percent.
# minimum = 0
# maximum = 90
je.cleaner.minUtilization=90
...全文
179 5 打赏 收藏 转发到动态 举报
写回复
用AI写文章
5 条回复
切换为时间正序
请发表友善的回复…
发表回复
hmsuccess 2010-03-24
  • 打赏
  • 举报
回复
有人懂吗?》寻求高手
hmsuccess 2010-03-24
  • 打赏
  • 举报
回复
引用 1 楼 gardner2010 的回复:
能不能把DB的LOG关了

请教,如何关闭,谢谢!
[/Quote]
hmsuccess 2010-03-24
  • 打赏
  • 举报
回复
[Quote=引用 1 楼 gardner2010 的回复:]
能不能把DB的LOG关了
[/Quote]
请教,如果关闭,谢谢!
justwalking 2010-03-24
  • 打赏
  • 举报
回复
顶贴,关注,学习。。。。。。。。。。。。。。。。。。。。。。
小贝壳666 2010-03-24
  • 打赏
  • 举报
回复
能不能把DB的LOG关了

62,614

社区成员

发帖
与我相关
我的任务
社区描述
Java 2 Standard Edition
社区管理员
  • Java SE
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧