in my rhel5u2 setup, i do it this way:
1. install iscsi-initiator-utils-6.2.0.868-0.7.el5
2. define the targets from initiators:
edit /etc/iscsi/initiatorname.iscsi and set the following:
# this is defined in your iscsi host
InitiatorName=iqn.2008-06.com.example:lun01.node00
InitiatorName=iqn.2008-06.com.example:lun02.node00
3. restart iscsid:
[root@node02 ~]# service iscsid stop
4. scan for the LUNs
[root@node02 ~]# iscsiadm -m discovery -t st -p node00
192.168.222.1:3260,1 iqn.2008-06.com.example:lun01.node00
192.168.222.1:3260,1 iqn.2008-06.com.example:lun02.node00
5. restart iscsi-target
[root@node02 ~]# service iscsi restart
and the disks should be visible:
#dmesg
scsi0 : iSCSI Initiator over TCP/IP
scsi1 : iSCSI Initiator over TCP/IP
Vendor: IET Model: VIRTUAL-DISK Rev: 0
Type: Direct-Access ANSI SCSI revision: 04
Vendor: IET Model: VIRTUAL-DISK Rev: 0
Type: Direct-Access ANSI SCSI revision: 04
scsi 0:0:0:1: Attached scsi generic sg0 type 0
scsi 1:0:0:1: Attached scsi generic sg1 type 0
SCSI device sda: 104857600 512-byte hdwr sectors (53687 MB)
sda: Write Protect is off
sda: Mode Sense: 77 00 00 08
SCSI device sda: drive cache: write through
SCSI device sda: 104857600 512-byte hdwr sectors (53687 MB)
sda: Write Protect is off
sda: Mode Sense: 77 00 00 08
SCSI device sda: drive cache: write through
sda: unknown partition table
sd 0:0:0:1: Attached scsi disk sda
SCSI device sdb: 104857600 512-byte hdwr sectors (53687 MB)
sdb: Write Protect is off
sdb: Mode Sense: 77 00 00 08
|