mirror of
https://github.com/minio/minio.git
synced 2025-11-10 14:09:48 -05:00
rootDisk on containers can have different device Id (#10259)
use `/etc/hosts` instead of `/` to check for common device id, if the device is same for `/etc/hosts` and the --bind mount to detect root disks. Bonus enhance healthcheck logging by adding maintenance tags, for all messages.
This commit is contained in:
@@ -31,7 +31,7 @@ func IsRootDisk(diskPath string) (bool, error) {
|
||||
if err != nil {
|
||||
return false, err
|
||||
}
|
||||
rootInfo, err := os.Stat("/")
|
||||
rootInfo, err := os.Stat("/etc/hosts")
|
||||
if err != nil {
|
||||
return false, err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user