mirror of
https://github.com/minio/minio.git
synced 2025-11-20 01:50:24 -05:00
Healing process should not heal root disk (#7089)
This commit is contained in:
committed by
kannappanr
parent
e8c18bc145
commit
82af0be1aa
@@ -1029,6 +1029,18 @@ func (s *xlSets) HealFormat(ctx context.Context, dryRun bool) (res madmin.HealRe
|
||||
}
|
||||
}(storageDisks)
|
||||
|
||||
for i, disk := range storageDisks {
|
||||
info, err := disk.DiskInfo()
|
||||
if err != nil {
|
||||
storageDisks[i] = nil
|
||||
}
|
||||
if info.RootDisk {
|
||||
// We should not heal on root disk. i.e in a situation where the minio-administrator has unmounted a
|
||||
// defective drive we should not heal a path on the root disk.
|
||||
storageDisks[i] = nil
|
||||
}
|
||||
}
|
||||
|
||||
formats, sErrs := loadFormatXLAll(storageDisks)
|
||||
if err = checkFormatXLValues(formats); err != nil {
|
||||
return madmin.HealResultItem{}, err
|
||||
|
||||
Reference in New Issue
Block a user