mirror of
https://gitlab.com/pulsechaincom/erigon-pulse.git
synced 2024-12-21 19:20:39 +00:00
mdbx: reduce 2 times hard dplimit (#9216)
can do it, because we don't do read-after-write in same rwtx
This commit is contained in:
parent
3bb1917e8a
commit
e806db977f
@ -326,8 +326,8 @@ func (opts MdbxOpts) Open(ctx context.Context) (kv.RwDB, error) {
|
||||
} else {
|
||||
dirtySpace = mmap.TotalMemory() / 42 // it's default of mdbx, but our package also supports cgroups and GOMEMLIMIT
|
||||
// clamp to max size
|
||||
const dirtySpaceMaxChainDB = uint64(2 * datasize.GB)
|
||||
const dirtySpaceMaxDefault = uint64(256 * datasize.MB)
|
||||
const dirtySpaceMaxChainDB = uint64(1 * datasize.GB)
|
||||
const dirtySpaceMaxDefault = uint64(128 * datasize.MB)
|
||||
|
||||
if opts.label == kv.ChainDB && dirtySpace > dirtySpaceMaxChainDB {
|
||||
dirtySpace = dirtySpaceMaxChainDB
|
||||
|
Loading…
Reference in New Issue
Block a user