mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-19 18:32:23 +00:00
.ldb filesize 2MB=>128MB
Changes the level0 .ldb file size from the default of 2MB to 128MB. This reduces the number of files in the db directory substantially, helping to reduce the amount of filesystem overhead required to manipulate the db.
This commit is contained in:
parent
a7501d0c41
commit
b73d66f2a1
1 changed files with 1 additions and 0 deletions
|
|
@ -78,6 +78,7 @@ func NewLDBDatabase(file string, cache int, handles int) (*LDBDatabase, error) {
|
|||
BlockCacheCapacity: cache / 2 * opt.MiB,
|
||||
WriteBuffer: cache / 4 * opt.MiB, // Two of these are used internally
|
||||
Filter: filter.NewBloomFilter(10),
|
||||
CompactionTableSize: 128 * opt.MiB,
|
||||
})
|
||||
if _, corrupted := err.(*errors.ErrCorrupted); corrupted {
|
||||
db, err = leveldb.RecoverFile(file, nil)
|
||||
|
|
|
|||
Loading…
Reference in a new issue