Details
-
Bug
-
Resolution: User Error
-
Critical
-
master, 5.0.0, 5.0.1, 5.1.0, 5.1.1, 5.1.2, 5.1.3, 5.5.0, 5.5.1, 5.5.2, 5.5.3, 5.5.4, 5.5.5, 6.0.0, 6.0.1, 6.0.2, 6.5.0
-
None
-
Untriaged
-
Unknown
Description
KV-engine bucket creation first attempts to find any vbucket data files by calling cb::io::findFilesContaining, the list of file names (i.e. 1.couch.2, 2.couch.2 etc...) is used to:
- populate the file revision map
- populate the vbuckets that warmup will bring into cache
If the opendir call failed there is no logging or detection of the error and KV continues as if the data directory is empty. If the opendir error was temporary, e.g. the system was currently out of file-descriptors (ENFILE) or the system was delayed in mounting the data directory (EXISTS), that means KV will continue thinking no vbuckets exist and may later end up clashing with an existing file (as seen in the linked CBSE) triggering inconsistency errors which require removal of the affected node.
We should treat all opendir failures as a crtitcal failure as we should always have an accessible data directory (it is ok for the directory to be empty) and the bucket creation should fail.
Attachments
For Gerrit Dashboard: MB-35390 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
112853,2 | MB-35390: Make opendir failures 'fatal' | master | platform | Status: ABANDONED | 0 | -1 |