Created
November 12, 2013 17:10
-
-
Save apahim/7434734 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[root@rhevm30 ~]# cd /var/lib/iscsi | |
[root@rhevm30 iscsi]# iscsiadm -m iface -I eth1 --op=new | |
New interface eth1 added | |
[root@rhevm30 iscsi]# iscsiadm -m iface -I eth2 --op=new | |
New interface eth2 added | |
[root@rhevm30 iscsi]# tree | |
. | |
`-- ifaces | |
|-- eth1 <--------------- Local interfaces to provide multipath | |
`-- eth2 <--------------- | |
1 directory, 2 files | |
[root@rhevm30 iscsi]# iscsiadm -m discovery -t sendtargets -p 192.168.25.118 -I eth1 -I eth2 <--------------- Discovery using both interfaces | |
Starting iscsid: [ OK ] | |
192.168.25.118:3260,1 iqn.2012-07.com.lenovoemc:storage.ix2-73.engine | |
192.168.25.118:3260,1 iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev33 | |
192.168.25.118:3260,1 iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev30 <--------------- Through eth1 | |
192.168.25.118:3260,1 iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev302 | |
192.168.25.118:3260,1 iqn.2012-07.com.lenovoemc:storage.ix2-73.engine | |
192.168.25.118:3260,1 iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev33 | |
192.168.25.118:3260,1 iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev30 <--------------- Through eth2 | |
192.168.25.118:3260,1 iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev302 | |
[root@rhevm30 iscsi]# tree | |
. | |
|-- ifaces | |
| |-- eth1 | |
| `-- eth2 | |
|-- nodes | |
| |-- iqn.2012-07.com.lenovoemc:storage.ix2-73.engine | |
| | `-- 192.168.25.118,3260,1 | |
| | |-- eth1 | |
| | `-- eth2 | |
| |-- iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev30 | |
| | `-- 192.168.25.118,3260,1 | |
| | |-- eth1 <--------------- Node per interface | |
| | `-- eth2 <--------------- | |
| |-- iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev302 | |
| | `-- 192.168.25.118,3260,1 | |
| | |-- eth1 | |
| | `-- eth2 | |
| `-- iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev33 | |
| `-- 192.168.25.118,3260,1 | |
| |-- eth1 | |
| `-- eth2 | |
`-- send_targets | |
`-- 192.168.25.118,3260 | |
|-- iqn.2012-07.com.lenovoemc:storage.ix2-73.engine,192.168.25.118,3260,1,eth1 -> /var/lib/iscsi/nodes/iqn.2012-07.com.lenovoemc:storage.ix2-73.engine/192.168.25.118,3260,1 | |
|-- iqn.2012-07.com.lenovoemc:storage.ix2-73.engine,192.168.25.118,3260,1,eth2 -> /var/lib/iscsi/nodes/iqn.2012-07.com.lenovoemc:storage.ix2-73.engine/192.168.25.118,3260,1 | |
|-- iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev30,192.168.25.118,3260,1,eth1 -> /var/lib/iscsi/nodes/iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev30/192.168.25.118,3260,1 | |
|-- iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev30,192.168.25.118,3260,1,eth2 -> /var/lib/iscsi/nodes/iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev30/192.168.25.118,3260,1 | |
|-- iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev302,192.168.25.118,3260,1,eth1 -> /var/lib/iscsi/nodes/iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev302/192.168.25.118,3260,1 | |
|-- iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev302,192.168.25.118,3260,1,eth2 -> /var/lib/iscsi/nodes/iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev302/192.168.25.118,3260,1 | |
|-- iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev33,192.168.25.118,3260,1,eth1 -> /var/lib/iscsi/nodes/iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev33/192.168.25.118,3260,1 | |
|-- iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev33,192.168.25.118,3260,1,eth2 -> /var/lib/iscsi/nodes/iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev33/192.168.25.118,3260,1 | |
`-- st_config | |
20 directories, 11 files | |
[root@rhevm30 iscsi]# multipath -ll <--------------- Nothing yet | |
[root@rhevm30 iscsi]# iscsiadm -m node -T iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev30 -l <--------------- Login to the target | |
Logging in to [iface: eth2, target: iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev30, portal: 192.168.25.118,3260] (multiple) <--------------- Two paths | |
Logging in to [iface: eth1, target: iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev30, portal: 192.168.25.118,3260] (multiple) <--------------- | |
Login to [iface: eth2, target: iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev30, portal: 192.168.25.118,3260] successful. | |
Login to [iface: eth1, target: iqn.2012-07.com.lenovoemc:storage.ix2-73.rhev30, portal: 192.168.25.118,3260] successful. | |
[root@rhevm30 iscsi]# multipath -ll <--------------- Now both paths are available and multipath can make its magic. | |
35005907f318ca6ca dm-2 LENOVO,LIFELINE-DISK | |
size=50G features='0' hwhandler='0' wp=rw | |
|-+- policy='round-robin 0' prio=1 status=active | |
| `- 4:0:0:0 sdb 8:16 active ready running | |
`-+- policy='round-robin 0' prio=1 status=enabled | |
`- 3:0:0:0 sda 8:0 active ready running |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment