Search in sources :

Example 1 with VolumeSpec

use of com.emc.sa.service.aix.UnmountBlockVolumeHelper.VolumeSpec in project coprhd-controller by CoprHD.

the class FindMountPointsForVolumes method executeTask.

@Override
public Void executeTask() throws Exception {
    ListMountPointsCommand command = new ListMountPointsCommand();
    Map<String, MountPoint> results = executeCommand(command, SHORT_TIMEOUT);
    for (VolumeSpec volume : volumes) {
        volume.mountPoint = AixUtils.getMountPoint(hostId, results, volume.viprVolume);
    }
    return null;
}
Also used : ListMountPointsCommand(com.emc.aix.command.ListMountPointsCommand) MountPoint(com.emc.aix.model.MountPoint) VolumeSpec(com.emc.sa.service.aix.UnmountBlockVolumeHelper.VolumeSpec)

Example 2 with VolumeSpec

use of com.emc.sa.service.aix.UnmountBlockVolumeHelper.VolumeSpec in project coprhd-controller by CoprHD.

the class FindMultiPathEntriesForMountPoint method executeTask.

@Override
public Void executeTask() throws Exception {
    List<MultiPathDevice> multiPathDevices = executeCommand(new MultiPathInquiry());
    for (VolumeSpec volume : volumes) {
        volume.multipathEntries = Lists.newArrayList();
        String device = volume.mountPoint.getDevice();
        for (MultiPathDevice multiPathDevice : multiPathDevices) {
            if (StringUtils.equals(device, multiPathDevice.getDevice())) {
                volume.multipathEntries.add(multiPathDevice);
                break;
            }
        }
        if (volume.multipathEntries.size() == 0) {
            warn("No MultiPath devices for %s", volume.mountPoint.getPath());
        }
    }
    return null;
}
Also used : VolumeSpec(com.emc.sa.service.aix.UnmountBlockVolumeHelper.VolumeSpec) MultiPathDevice(com.emc.aix.model.MultiPathDevice) MultiPathInquiry(com.emc.aix.command.MultiPathInquiry)

Example 3 with VolumeSpec

use of com.emc.sa.service.aix.UnmountBlockVolumeHelper.VolumeSpec in project coprhd-controller by CoprHD.

the class FindPowerPathEntriesForMountPoint method executeTask.

@Override
public Void executeTask() throws Exception {
    List<PowerPathDevice> powerPathDevices = executeCommand(new PowerPathInquiry());
    for (VolumeSpec volume : volumes) {
        volume.powerpathDevices = Lists.newArrayList();
        String device = volume.mountPoint.getDevice();
        for (PowerPathDevice powerpathDevice : powerPathDevices) {
            if (StringUtils.equals(device, powerpathDevice.getDevice())) {
                volume.powerpathDevices.add(powerpathDevice);
                break;
            }
        }
        if (volume.powerpathDevices.size() == 0) {
            warn("No PowerPath devices for %s", volume.mountPoint.getPath());
        }
    }
    return null;
}
Also used : VolumeSpec(com.emc.sa.service.aix.UnmountBlockVolumeHelper.VolumeSpec) PowerPathDevice(com.iwave.ext.linux.model.PowerPathDevice) PowerPathInquiry(com.emc.aix.command.PowerPathInquiry)

Aggregations

VolumeSpec (com.emc.sa.service.aix.UnmountBlockVolumeHelper.VolumeSpec)3 ListMountPointsCommand (com.emc.aix.command.ListMountPointsCommand)1 MultiPathInquiry (com.emc.aix.command.MultiPathInquiry)1 PowerPathInquiry (com.emc.aix.command.PowerPathInquiry)1 MountPoint (com.emc.aix.model.MountPoint)1 MultiPathDevice (com.emc.aix.model.MultiPathDevice)1 PowerPathDevice (com.iwave.ext.linux.model.PowerPathDevice)1