VerifyDB()
can fail to complete due to insufficient dbcache at the level 3 checks. This PR improves the error handling in this case in the following ways:
- The rpc
-verifychain
now returns false if the check can’t be completed due to insufficient cache - During init, we only log a warning if the default values for
-checkblocks
ย and-checklevel
are taken and the check doesn’t complete. However, if the user actively specifies one of these args, we return with an InitError if we can’t complete the check.
This PR also changes -verifychain
RPC to return false
if the verification didn’t finish due to missing block data (pruning) or due to being interrupted by the node being shutdown.
Previously, this PR also included a fix for a possible assert during verification - this was done in #27009 (now merged).