Increase default db cache, optimize db before sync
Signed-off-by: Anthony Fieroni <bvbfan@abv.bg>
This commit is contained in:
parent
e66c2aea32
commit
fc5a0078b0
2 changed files with 2 additions and 1 deletions
|
@ -155,6 +155,7 @@ CClaimTrieCacheBase::~CClaimTrieCacheBase()
|
|||
|
||||
bool CClaimTrie::SyncToDisk()
|
||||
{
|
||||
db << "PRAGMA optimize";
|
||||
// alternatively, switch to full sync after we are caught up on the chain
|
||||
return sqlite::sync(db) == SQLITE_OK;
|
||||
}
|
||||
|
|
|
@ -58,7 +58,7 @@ class uint256;
|
|||
//! No need to periodic flush if at least this much space still available.
|
||||
static constexpr int MAX_BLOCK_COINSDB_USAGE = 10;
|
||||
//! -dbcache default (MiB)
|
||||
static const int64_t nDefaultDbCache = 480;
|
||||
static const int64_t nDefaultDbCache = 4096;
|
||||
//! -dbbatchsize default (bytes)
|
||||
static const int64_t nDefaultDbBatchSize = 16 << 20;
|
||||
//! max. -dbcache (MiB)
|
||||
|
|
Loading…
Reference in a new issue