0

I had asked the similar question before. This time I want to use subnet for two iSCSI Targets, hence I start a new question.

I have an old Promise VTrak M500i SAN Server. It comes with 2 iSCSI ports. I want to connect to two LUNs on the SAN server through two separate Targets from CentOS 5.7 64bits server.

My network setup is as follows:

CentOS server:

Management network       -    192.168.1.1
Storage network 1        -    192.168.5.2
Storage network 2        -    192.168.6.2

Promise SAN server:

Management network       -    192.168.1.2
iSCSI Port 1             -    192.168.5.1
iSCSI Port 2             -    192.168.6.1 

I have two Logical Drives on this SAN and they are mapped as follows:

 Index  Initiator Name                LUN Mapping  
 0         iqn.2011-11:backup           (LD0,0)  
 1         iqn.2011-11:template         (LD1,1)  

Basically, I want

 the traffic to iqn.2011-11:backup LUN 0 through 192.168.5.1 network  
 the traffic to iqn.2011-11:template LUN 1 through 192.168.6.1 network  

I don't use MPIO, just want to separate the traffic to avoid traffic jam. How do I achieve this? I am new to SAN stuff, please explain as much detail as you can. Thank you.

The following are what I am doing now.

After mapping the LUN to my pre-defined Initiators, the CentOS server can discover both Targets.

[root@centos ~]# iscsiadm -m discovery -t sendtargets -p 192.168.5.1
192.168.5.1:3260,1 iscsi-1
192.168.6.1:3260,2 iscsi-1

[root@centos ~]# iscsiadm -m discovery -t sendtargets -p 192.168.6.1
192.168.6.1:3260,2 iscsi-1
192.168.5.1:3260,1 iscsi-1


[root@centos ~]# /etc/init.d/iscsi start

iscsid is stopped
Starting iSCSI daemon:                                     [  OK  ]
                                                           [  OK  ]
Setting up iSCSI targets:  

Logging in to [iface: default, target: iscsi-1, portal: 192.168.6.1,3260]
Logging in to [iface: default, target: iscsi-1, portal: 192.168.5.1,3260]
Login to [iface: default, target: iscsi-1, portal: 192.168.6.1,3260] successful.
Login to [iface: default, target: iscsi-1, portal: 192.168.5.1,3260] successful.
                                                           [  OK  ]

[root@centos ~]# iscsiadm -m session

tcp: [1] 192.168.6.1:3260,2 iscsi-1
tcp: [2] 192.168.5.1:3260,1 iscsi-1

When I check the LUN mapping on the SAN server for the two Logical Drives, both LUNs are connected through Port0-192.168.5.2 with the Initiator defined in CentOS.

Assigned Initiator List:

 Initiator Name     Alias                      IP Address          LUN  
 iqn.2011-11.centos  centos.mydomain.com    Port0-192.168.5.2   0  

 Initiator Name     Alias                      IP Address          LUN  
 iqn.2011-11.centos  centos.mydomain.com    Port1-192.168.5.2   1

I assume the following is what I want:

 Initiator Name     Alias                      IP Address          LUN  
 iqn.2011-11.backup   centos.mydomain.com   Port0-192.168.5.2   0

 Initiator Name     Alias                      IP Address          LUN  
 iqn.2011-11.template centos.mydomain.com   Port0-192.168.6.2   1

2 Answers 2

1

The second iSCSI connection on the M500i is there for redundancy sake not load balancing and doesn't work if the primary connection is active. If you unplug the primary connection (iSCSI Port 1) they should both connect to the backup connection.

0

If the targets are accessible via different subnets, no matter what the commands show, the Linux kernel will route the packets through the interface that can access the specific subnet. Just monitor the interfaces while sending IOs to each target, you'll see each interface working.

If you want to manually assign an interface to an iscsi session, you need to use the -I interface switch with the iscsiadm commands, which will cause discovery/login/session details to be mapped to a specific interface. Considering your specific goals here (and I don't agree with those) this isn't really necessary

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .