mirror of
https://github.com/pgsty/minio.git
synced 2026-08-10 16:23:28 +03:00
Heal corrupted formats of disks already containing objects (#2297)
This commit is contained in:
committed by
Harshavardhana
parent
f239fcac67
commit
14cefd352c
@@ -145,6 +145,10 @@ func newXLObjects(disks, ignoredDisks []string) (ObjectLayer, error) {
|
||||
|
||||
// Handles different cases properly.
|
||||
switch reduceFormatErrs(sErrs, len(storageDisks)) {
|
||||
case errCorruptedFormat:
|
||||
if err := healFormatXLCorruptedDisks(storageDisks); err != nil {
|
||||
return nil, fmt.Errorf("Unable to repair corrupted format, %s", err)
|
||||
}
|
||||
case errUnformattedDisk:
|
||||
// All drives online but fresh, initialize format.
|
||||
if err := initFormatXL(storageDisks); err != nil {
|
||||
|
||||
Reference in New Issue
Block a user