Removing iSCSI Target Access to a Virtual Disk

Updated: September 29, 2010

Applies To: Microsoft iSCSI Software Target

If an iSCSI virtual disk is assigned to an iSCSI target, but the iSCSI target no longer requires access to the virtual disk, you can remove access in the following ways:

  • Remove the iSCSI target from the virtual disk.

  • Remove the virtual disk from the iSCSI target.

The virtual disk is dynamically removed from the iSCSI target without requiring a shutdown of the target. After the virtual disk is removed from the iSCSI target, Microsoft iSCSI Software Target dynamically notifies the iSCSI initiator. If the iSCSI initiator supports dynamic discovery, the virtual disk is removed from the Disk Management console of the iSCSI initiator. If the iSCSI initiator does not support dynamic discovery, you must scan the iSCSI initiator from the Disk Management console.

CautionCaution
Removing access to a virtual disk that is in use can cause data corruption. Before removing iSCSI initiator access to a virtual disk, ensure that no iSCSI initiator or application is using the virtual disk and that all data is appropriately saved.

noteNote
Removing virtual disk access does not delete the virtual disk from the Microsoft iSCSI Software Target console or from the computer. After removing virtual disk access, the virtual disk is still available in Devices and can be assigned to another iSCSI target. If the virtual disk is no longer needed, it can be deleted. For more information about deleting a virtual disk, see Deleting a Virtual Disk. You can also disable a virtual disk temporarily. For more information about disabling and enabling a virtual disk, see Taking a Virtual Disk Offline Temporarily.

Membership in the local Administrators group, or equivalent, is the minimum required to complete this procedure. Review the details in "Additional considerations" in this topic.

To remove an iSCSI target from a virtual disk

  1. In Microsoft iSCSI Software Target, in the console tree, click Devices.

  2. In the results pane, right-click the virtual disk that you want to remove, and then click Assign/Remove Target.

  3. When you are prompted to confirm the removal, click Yes.

To remove a virtual disk from an iSCSI target

  1. In Microsoft iSCSI Software Target, in the console tree, click iSCSI Targets.

  2. In the results pane, double-click the iSCSI target.

  3. In the results pane, right-click the virtual disk, and then click Remove Virtual Disk from iSCSI Target.

  4. When you are prompted to confirm the removal, click Yes.

Registry information

Reservation configuration data may persist in the registry of the Microsoft iSCSI Software Target computer when the initiator’s cluster membership status changes. This situation can occur if the virtual disk is assigned to an initiator that is part of a cluster, and you remove the initiator from the cluster or reassign the virtual disk to an initiator that is not in a cluster. If you are moving the virtual disk assignment in this scenario, you should remove the registry data for the previous configuration.

The registry information for a standalone storage appliance is located at the following subkey:

HKLM\Software\Microsoft\iSCSI Target\PRInfo

The registry information for a cluster storage appliance is located at the following subkey:

HKLM\Cluster\iSCSI Target\PRInfo

The values under this key correspond to the Microsoft iSCSI Software Target disk number. To safely remove the persistent reservation for the virtual disk assignment that you are changing, remove only the value for that disk number.

Additional considerations

  • You must be a member of the local Administrators group to perform these tasks.

  • To open iSCSI Software Target, click Start, point to Administrative Tools, and then click Microsoft iSCSI Software Target. (Another way to open iSCSI Software Target is to click Start, click Run, and then type iscsitarget.msc.)

Additional references

Show: