Modifying a logical unit mapping using the CLI

You can modify a logical unit (LU) mapping using the command-line interface (CLI).

Perform the following steps to modify an LU mapping:

  1. Migrate all of the data from the managed disk (MDisk) by performing the following steps:
    1. If the MDisk is in managed mode or image mode and the virtual disk (VDisk) must be kept online, issue the following CLI command and then proceed to step 2:
       svctask rmmdisk -mdisk MDisk number -force MDisk group number

      Where MDisk number is the number of the MDisk that you want to modify and MDisk group number is the number of the MDisk group for which you want to remove the MDisk.

      Note:
      • The VDisk becomes a striped MDisk not an image-mode VDisk.
      • All data that is stored on this MDisk is migrated to the other MDisks in the MDisk group.
      • This CLI command can fail if there are not enough free extents in the MDisk group.
    2. If the MDisk is in image mode and you do not want to convert the VDisk to a striped VDisk, stop all I/O to the image mode VDisk.
    3. Issue the following CLI command to remove the host mapping and any SCSI reservation that the host has on the VDisk:
      svctask rmvdiskhostmap -host host name VDisk name

      Where host name is the name of the host for which you want to remove the VDisk mapping and VDisk name is the name of the VDisk for which you want to remove mapping.

    4. Issue the following command to delete the VDisk:
      svctask rmvdisk VDisk name

      Where VDisk name is the name of the VDisk that you want to delete.

  2. Remove the LU mapping on the storage system so that the LUN is not visible to the SAN Volume Controller.
  3. Issue the following CLI command to clear all error counters on the MDisk:
    svctask includemdisk MDisk number

    Where MDisk number is the number of the MDisk that you want to modify.

  4. Issue the following CLI command to rescan the fibre-channel network and detect that the LU is no longer there.
    svctask detectmdisk MDisk number

    Where MDisk number is the number of the MDisk that you want to modify.

    The MDisk is removed from the configuration.
  5. Issue the following CLI command to verify that the MDisk is removed:
    svcinfo lsmdisk MDisk number

    Where MDisk number is the number of the MDisk that you want to modify.

    • If the MDisk is still displayed, repeat steps 3 and 4.
  6. Configure the mapping of the LU to the new LUN on the storage system.
  7. Issue the following CLI command:
    svctask detectmdisk 
  8. Issue the following CLI command to check that the MDisk now has the correct LUN:
    svcinfo lsmdisk

The MDisk has the correct LUN.

Library | Support | Terms of use | Feedback
© Copyright IBM Corporation 2003, 2009. All Rights Reserved.