basic setup enterprise iscsi target centos

basic setup enterprise iscsi target centos

first of all : yum update -y

reboot

yum install kernel-devel openssl-devel gcc rpm-build

mkdir /usr/src/iscsitarget

mkdir /data/iscsidisks

cd /usr/src/iscsitarget

wget “http://downloads.sourceforge.net/project/iscsitarget/iscsitarget/1.4.19/iscsitarget-1.4.19.tar.gz?use_mirror=kent” or get the latest on sourceforge

tar xfz iscsitarget-1.4.19.tar.gz

cd iscsitarget-1.4.19

make

make install

create disk 100GB ( for example ) : dd if=/dev/zero of=/data/iscsidisks/LUN0 bs=1M count=102400

vi /etc/iet/ietd.conf

add the following to the bottom of this file :

 Target iqn.2009-11.my-ISCSItargetNAME:mydisk
        IncomingUser username 123456789012
        OutgoingUser username 123456789012
        Lun 0 Path=/data/iscsidisks/LUN0,Type=fileio,IOMode=wb
        Alias iSCSI for mydisk
        ImmediateData Yes
        MaxConnections 2
        InitialR2T Yes

save & quit

service iscsi-target start

chkconfig iscsi-target on

Leave a Reply

Your email address will not be published. Required fields are marked *

eighteen + two =

This site uses Akismet to reduce spam. Learn how your comment data is processed.