mirror of
https://github.com/prometheus/prometheus
synced 2024-12-25 07:52:28 +00:00
Merge pull request #1306 from prometheus/beorn7/storage
Tolerate the lost+found directory in the data directory
This commit is contained in:
commit
7a012ea611
@ -162,7 +162,7 @@ func newPersistence(
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if len(fis) > 0 {
|
||||
if len(fis) > 0 && !(len(fis) == 1 && fis[0].Name() == "lost+found" && fis[0].IsDir()) {
|
||||
return nil, fmt.Errorf("could not detect storage version on disk, assuming version 0, need version %d - please wipe storage or run a version of Prometheus compatible with storage version 0", Version)
|
||||
}
|
||||
// Finally we can write our own version into a new version file.
|
||||
|
Loading…
Reference in New Issue
Block a user