Check sysfs Type instead of Device

Some distribution, or installation use "none" device to mount sysfs (eg. Scaleway VPS). We should check the mount type instead of device.

Fix #37183
This commit is contained in:
Patrice Ferlet 2016-11-21 14:56:10 +01:00
parent 21c3b3028f
commit 439a03136f

View File

@ -98,7 +98,7 @@ func isSysFSWritable() (bool, error) {
for _, mountPoint := range mountPoints {
const sysfsDevice = "sysfs"
if mountPoint.Device != sysfsDevice {
if mountPoint.Type != sysfsDevice {
continue
}
// Check whether sysfs is 'rw'