sortColumn = DRV_SORT_DEFAULT; $sortCriteria->ascending = true; $drives = get_all_drives($user, $sortCriteria); foreach ($drives as $drive) { $i = 0; foreach($driveGuids as $driveGuid) { if(strcmp($drive->guid, $driveGuid) == 0) { if (strcmp($dinterfaces[$i], "SCSI") == 0) { // call the extension to do the actual change if($drive->scsiId != $driveIds[$i]) { error_log("scsiID changed"); set_scsi_id($user, $driveGuid, $driveIds[$i]); } } else { // call the extension to do the actual change if($drive->loopId != $driveIds[$i]) { error_log("non gen5 fc changed"); set_fc_ids($user, $driveGuid, intval($driveIds[$i]), $drive->topology, $drive->speed); } } if ($status->errorCode != 0) { $errorCode = $status->errorCode; } } $i++; } } // this takes care LTO-5 foreach ($drives as $drive) { $i = 0; foreach($driveGuids_5 as $driveGuid_5) { if(strcmp($drive->guid, $driveGuid_5) == 0) { if(($drive->loopId != $driveId1s_5[$i]) || ($drive->loopId2 != $driveId2s_5[$i])) { error_log("gen 5 fc changed"); set_fc_ids($user, $driveGuid_5, $driveId1s_5[$i], $drive->topology, $drive->speed, $driveId2s_5[$i], $drive->topology2, $drive->speed2); } if ($status->errorCode != 0) { $errorCode = $status->errorCode; } } $i++; } } $returnMessage = "Set Drive ID Complete."; } ?> Set Drive Id