Manually removing existing keys from SCSI-3 disks

Review the following procedure to remove specific registration and reservation keys created by another node from a disk.

Note:

If you want to clear all the pre-existing keys, use the vxfenclearpre utility.

To remove the registration and reservation keys from disk

  1. Create a file to contain the access names of the disks:
    # vi /tmp/disklist

    For example:

    /dev/rdsk/c1t0d11s2
  2. Read the existing keys:
    # vxfenadm -s all -f /tmp/disklist

    The output from this command displays the key:

    Device Name: /dev/rdsk/c1t0d11s2
    Total Number Of Keys: 1
    key[0]:
    [Numeric Format]: 86,70,66,69,65,68,48,50
    [Character Format]: VFBEAD02
    [Node Format]: Cluster ID: 48813 Node ID: 2
      Node Name: unknown
  3. If you know on which node the key (say A1) was created, log in to that node and enter the following command:
    # vxfenadm -x -kA1 -f /tmp/disklist

    The key A1 is removed.

  4. If you do not know on which node the key was created, follow 5 through 7 to remove the key.
  5. Register a second key "A2" temporarily with the disk:
    # vxfenadm -m -k A2 -f /tmp/disklist
    Registration completed for disk path /dev/rdsk/c1t0d11s2
  6. Remove the first key from the disk by preempting it with the second key:
    # vxfenadm -p -kA2 -f /tmp/disklist -vA1
    key: A2------ prempted the key: A1------ on disk
    /dev/rdsk/c1t0d11s2
  7. Remove the temporary key registered in 5.
    # vxfenadm -x -kA2 -f /tmp/disklist
    Deleted the key : [A2------] from device /dev/rdsk/c1t0d11s2

    No registration keys exist for the disk.