Skip to content

Commit

Permalink
Add multipath support to SF
Browse files Browse the repository at this point in the history
The original SolidFire plugin didn't require/use multipath.  Other
products in the NDVP however require it and we've had a number of
cases where customers have setup multipath with then in turn breaks
the ability to use SF unless the SF device is blacklisted in the
multipath.conf file.

Rather than have two configs, just add multipath support to SF.

Closes Github Issue: NetApp#49
  • Loading branch information
j-griffith committed Sep 6, 2017
1 parent 29aceaf commit 0d9f7a9
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions storage_drivers/solidfire_san.go
Original file line number Diff line number Diff line change
Expand Up @@ -431,6 +431,18 @@ func (d *SolidfireSANStorageDriver) Attach(name, mountpoint string, opts map[str
return errors.New("iSCSI attach error")
}
log.Debugf("Attached volume at (path, devfile): %s, %s", path, device)

// NOTE(jdg): Check for device including multipath/DM device)
info, err := utils.GetDeviceInfoForLuns()
for _, e := range info {
if e.Device != device {
continue
}
if e.MultipathDevice != "" {
device = e.MultipathDevice
}
}

if utils.GetFSType(device) == "" {
//TODO(jdg): Enable selection of *other* fs types
err := utils.FormatVolume(device, "ext4")
Expand Down

0 comments on commit 0d9f7a9

Please sign in to comment.