Sharing access to disks in read-write mode

Learn how to share access to disks in read-write mode.

Although simultaneous access to a virtual disk by multiple logical partitions is limited to read-only access, V5R2 enhancements make it possible for multiple logical partitions to have the same virtual disk linked to their network storage descriptor (NWSD). However, only one partition can access the disk in read-write mode at any given time. See How to use the shared, read-only storage space for more information.
Use either of the following methods to access disks in read-write mode:

Use the iSeries Navigator

To access a disk drive using iSeries™ Navigator, follow these steps:
  1. Click NetworkWindows AdministrationDisk Drives.
  2. Right-click an available disk drive and select Add Link.
  3. Select the server that you want to link the disk to.
  4. Select one of the available link types and the link sequence position.
  5. Select the Shared - Update access type.
  6. Click OK.

Use the Add Network Server Storage Link command

To link a disk drive using the Add Network Server Storage Link command, follow these instructions:
  1. Type the the Add Network Server Storage Link (ADDNWSSTGL) command. This command links the network storage space to the network server descriptor. You must set the access type to shared update (*SHRUPD).
    Add Network Server Storage Link display
  2. Specify either *YES or *NO in the Dynamic storage link field.
  3. Press the F9 key to display the Access field.
After you link the network storage to the partition, Linux can access the storage by using the mount command. For example, to mount a virtual disk in read-write mode, you could use the following mount command:
mount /dev/hdb1 /mnt/data2  

If no other partition has the disk mounted, the mount is successful. Otherwise, Linux generates the following error:

mount: /dev/hdb5: can't read superblock

In order to grant access to the partition, the first partition (that is, the partition that is currently accessing the resource) must first relinquish access. To accomplish this result, use the Linux umount command as follows:

umount /dev/hdb1

After the first Linux partition relinquishes the resource, the second Linux partition can mount and access it.