I'm running a Geth mainnet node. As the size of chaindata is rapidly rising, I moved ancient to an auxiliary HDD plugged in to the same system. Some time afterwards (not sure when, maybe days?) I found my node was dead, and giving me the error:

Fatal: Error starting protocol stack: gap in the chain between ancients and leveldb

Looking at the Geth blog announcement of Freezer and the ancient store, it looks like if ancient is corrupted, everything is toast. Is there any way to salvage anything before having to wipe everything and start from scratch? In a similar question I see that's what the OP did, but I'd like to see if there's any possible salvage or troubleshooting to be done.

It would seem to me from the blog post that I should be able to at least try to delete the chaindata but not ancient. That way, if the issue is in chaindata, ancient should rebuild at least some of the history, and spare me that much resync. As per the Geth blog:

If, however, the state database is the one delete, Geth will reconstruct all its indices based on the frozen data; and then do a fast sync on top to back-fill the missing state.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.