diff --git a/pkg/volume/fc/fc_util.go b/pkg/volume/fc/fc_util.go index 94f5c7a9452..a8a99a45e90 100644 --- a/pkg/volume/fc/fc_util.go +++ b/pkg/volume/fc/fc_util.go @@ -254,7 +254,15 @@ func (util *fcUtil) AttachDisk(b fcDiskMounter) (string, error) { return "", err } - return devicePath, nil + exists, err := mount.PathExists(devicePath) + if exists && err == nil { + return devicePath, nil + } + if exists == false { + return "", fmt.Errorf("device %s does not exist", devicePath) + } else { + return "", err + } } // DetachDisk removes scsi device file such as /dev/sdX from the node.