I have two iSCSI target servers. The iSCSI Initiator is an Ubuntu host (Ubuntu 14.04). I am using Ubuntu's open-iscsi to mount the iSCSI targets from both iSCSI targets servers to my Initiator.
The problem is that the symlinks in /dev/disk/by-id are "overwritten".
When I do the iscsiadm discovery and the iscsiadm -m node -l command to the first iSCSI target server, the targets are mounted and there are symlinks under /dev/disk/by-id.
For example, doing an ls -l /dev/disk/by-id after logging in to the first iSCSI target server might show the following:
scsi-3600000e00010001 -> ../../sdc
scsi-3600000e00010002 -> ../../sdd
scsi-3600000e00010003 -> ../../sde
wwn-0x60000e00010001 -> ../../sdc
wwn-0x60000e00010002 -> ../../sdd
wwn-0x60000e00010003 -> ../../sde
After doing a discovery and a login to the 2nd iSCSI target server (without logging out of the iSCSI target server), doing an ls -l /dev/disk/by-id shows something like this:
scsi-3600000e00010001 -> ../../sdaa
scsi-3600000e00010002 -> ../../sdab
scsi-3600000e00010003 -> ../../sdac
wwn-0x60000e00010001 -> ../../sdaa
wwn-0x60000e00010002 -> ../../sdab
wwn-0x60000e00010003 -> ../../sdac
1) I checked that all the iSCSI targets are mounted on the Ubuntu initiator by issuing an fdisk -l command. The iSCSI targets are all mounted.
2) But the symlinks point to targets from the 2nd server now. It looks like the symlinks to the targets from the 1st server were overwritten by symlinks to the 2nd server.
Is it possible to have all the iSCSI targets, from both iSCSI target servers, have separate symlinks and be listed under /dev/disk/by-id?
I am not an iSCSI expert so I thought I'd ask. I Googled this problem and searched for relevant tags here but I didn't see any answers. Maybe I am not configuring something correctly?
A workaround would be for me to write a script that ccreates individual, unique symlinks for all the iSCSI targets but I'd first like to see if I am misconfiguring something.