From 877cc26ee83f18efe69541092940e107ed3c8f98 Mon Sep 17 00:00:00 2001 From: Hong Shuning Date: Tue, 8 Mar 2016 23:32:53 +0800 Subject: [PATCH 1/2] Increase MIN_DISK_SPACE_FOR_BLOCK_FILES to 950MB --- src/main.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/main.h b/src/main.h index ae0b5d229213c..f7a0dd95db0f7 100644 --- a/src/main.h +++ b/src/main.h @@ -153,14 +153,14 @@ extern uint64_t nPruneTarget; static const signed int MIN_BLOCKS_TO_KEEP = 288; // Require that user allocate at least 550MB for block & undo files (blk???.dat and rev???.dat) -// At 1MB per block, 288 blocks = 288MB. -// Add 15% for Undo data = 331MB -// Add 20% for Orphan block rate = 397MB +// At 2MB per block, 288 blocks = 576MB. +// Add 15% for Undo data = 662MB +// Add 20% for Orphan block rate = 794MB // We want the low water mark after pruning to be at least 397 MB and since we prune in // full block file chunks, we need the high water mark which triggers the prune to be -// one 128MB block file + added 15% undo data = 147MB greater for a total of 545MB -// Setting the target to > than 550MB will make it likely we can respect the target. -static const signed int MIN_DISK_SPACE_FOR_BLOCK_FILES = 550 * 1024 * 1024; +// one 128MB block file + added 15% undo data = 147MB greater for a total of 942MB +// Setting the target to > than 950MB will make it likely we can respect the target. +static const uint64_t MIN_DISK_SPACE_FOR_BLOCK_FILES = 950 * 1024 * 1024; /** Register with a network node to receive its signals */ void RegisterNodeSignals(CNodeSignals& nodeSignals); From 1c32eab7d9d5943bef0028f93d1cbbf58fde69ce Mon Sep 17 00:00:00 2001 From: Hong Shuning Date: Wed, 9 Mar 2016 22:54:59 +0800 Subject: [PATCH 2/2] Fix comments --- src/main.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main.h b/src/main.h index f7a0dd95db0f7..0763d6ffe9add 100644 --- a/src/main.h +++ b/src/main.h @@ -152,11 +152,11 @@ extern uint64_t nPruneTarget; /** Block files containing a block-height within MIN_BLOCKS_TO_KEEP of chainActive.Tip() will not be pruned. */ static const signed int MIN_BLOCKS_TO_KEEP = 288; -// Require that user allocate at least 550MB for block & undo files (blk???.dat and rev???.dat) +// Require that user allocate at least 950MB for block & undo files (blk???.dat and rev???.dat) // At 2MB per block, 288 blocks = 576MB. // Add 15% for Undo data = 662MB // Add 20% for Orphan block rate = 794MB -// We want the low water mark after pruning to be at least 397 MB and since we prune in +// We want the low water mark after pruning to be at least 794 MB and since we prune in // full block file chunks, we need the high water mark which triggers the prune to be // one 128MB block file + added 15% undo data = 147MB greater for a total of 942MB // Setting the target to > than 950MB will make it likely we can respect the target.