Badger fails to open due to manifest table mismatch

Moved from GitHub badger/1291

Posted by julieStackRox:

What version of Go are you using (go version)?

1.13

What version of Badger are you using?

1.6

Does this issue reproduce with the latest master?

What are the hardware specifications of the machine (RAM, OS, Disk)?

Not sure

What did you do?

When we try to open a Badger DB we get the error “file does not exist for table 1938” or the error “file does not exist for table 1941.” When we examine the disk the two files do not exist.

What did you expect to see?

No errors. What the Badger believes in the manifest should match tables on disk.

What did you see instead?

Got an error. Not sure how to recover.

jarifibrahim commented :

@julieStackRox Are you sure you’re using badger v1.6 and not v1.6.1? We recently added some fixes to v1.6.1 and my guess is one of those fixes introduced a bug.

julieStackRox commented :

@jarifibrahim Thank you for your response. Yes, we were on 1.6.1. Tried to rollback now.

jarifibrahim commented :

@julieStackRox My guess is PR Rework concurrency semantics of valueLog.maxFid (#1184) (#1187) · dgraph-io/badger@3e25d77 · GitHub introduced this.

Do you have a way to reproduce this issue? I’d like to reproduce this so that I can dig deeper.