1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

Merge pull request #17757 from rhvgoyal/log-blkid-failure

devmapper: Provide more error information if blkid fails
This commit is contained in:
Vincent Batts 2015-11-07 09:16:14 -05:00
commit 10df5647bd

View file

@ -826,8 +826,7 @@ func (devices *DeviceSet) loadMetadata(hash string) *devInfo {
func getDeviceUUID(device string) (string, error) {
out, err := exec.Command("blkid", "-s", "UUID", "-o", "value", device).Output()
if err != nil {
logrus.Debugf("Failed to find uuid for device %s:%v", device, err)
return "", err
return "", fmt.Errorf("Failed to find uuid for device %s:%v", device, err)
}
uuid := strings.TrimSuffix(string(out), "\n")