I have a few notes from an ISCI setup not that long ago that may be helpful which I have included below. I used these notes to mount /home/e-smith/files on a Freenas box and it have no problems with reboots:
yum --enablerepo=epel install iscsi-initiator-utils
cd /etc/rc.d/rc7.d/
ln -s /etc/rc.d/init.d/e-smith-service S38iscsid
ln -s /etc/rc.d/init.d/e-smith-service S39iscsi
ln -s /etc/rc.d/init.d/e-smith-service S40netfs
edit /etc/iscsi/iscsi.conf
# To set a CHAP username and password for initiator
# authentication by the target(s), uncomment the following lines:
node.session.auth.username = your_name
node.session.auth.password = your_pass
# To set a discovery session CHAP username and password for the initiator
# authentication by the target(s), uncomment the following lines:
discovery.sendtargets.auth.username = your_name
discovery.sendtargets.auth.password = your_pass
db configuration set iscsi service status enabled
discover the target:
iscsiadm -m discovery -p 192.168.10.43:3260 -t st
login to the target
iscsiadm -m node -p 192.168.10.43:3260 -T iqn.2015-10.com.domain.ctl:target1 -l
Should see the following:
Logging in to [iface: default, target: iqn.2015-10.com.domain.ctl:target1, portal: 192.168.10.43,3260] (multiple)
Login to [iface: default, target: iqn.2015-10.com.domain.ctl:target1, portal: 192.168.10.43,3260] successful.
ISCSI info only
clear discovered targets if required
iscsiadm -m discovery -p 192.168.9.2:3260 -o delete
logout
iscsiadm -m node -p 192.168.9.2:3260 -T iqn.2011-03.au.com.domain.istgt:target1 -u
Note block device name
#lsscsi
[0:0:0:0] disk ATA WDC WD20EARX-00P 51.0 /dev/sda
[6:0:0:0] disk FreeBSD iSCSI Disk 0123 /dev/sdb
Create Filesystem
mkfs.ext4 /dev/sdb
Grab BlockID to use in fstab
#blkid /dev/sdb
/dev/sdb: UUID="c792f753-0929-44b3-a3f5-35c0540f56e5" TYPE="ext4"
Create mount point
#mkdir /mnt/backup
Edit /etc/fstab and add the following:
UUID=c792f753-0929-44b3-a3f5-35c0540f56e5 /mnt/backup ext4 _netdev 0 0
Mount the NAS Device
#mount /dev/sdb
Run some tests to check performance:
#cd /mnt/backup
#fio --randrepeat=1 --ioengine=libaio --direct=1 --gtod_reduce=1 --name=test --filename=test --bs=4k --iodepth=64 --size=4G --readwrite=randrw --rwmixread=75
test: (g=0): rw=randrw, bs=4K-4K/4K-4K/4K-4K, ioengine=libaio, iodepth=64
fio-2.0.13
Starting 1 process
test: Laying out IO file(s) (1 file(s) / 4096MB)
Jobs: 1 (f=1): [m] [100.0% done] [62052K/19564K/0K /s] [15.6K/4891 /0 iops] [eta 00m:00s]
test: (groupid=0, jobs=1): err= 0: pid=975: Mon Mar 2 21:15:07 2015
read : io=3072.9MB, bw=58778KB/s, iops=14694 , runt= 53533msec
write: io=1023.2MB, bw=19572KB/s, iops=4892 , runt= 53533msec
cpu : usr=4.97%, sys=25.39%, ctx=389286, majf=0, minf=20
IO depths : 1=0.1%, 2=0.1%, 4=0.1%, 8=0.1%, 16=0.1%, 32=0.1%, >=64=100.0%
submit : 0=0.0%, 4=100.0%, 8=0.0%, 16=0.0%, 32=0.0%, 64=0.0%, >=64=0.0%
complete : 0=0.0%, 4=100.0%, 8=0.0%, 16=0.0%, 32=0.0%, 64=0.1%, >=64=0.0%
issued : total=r=786644/w=261932/d=0, short=r=0/w=0/d=0
Run status group 0 (all jobs):
READ: io=3072.9MB, aggrb=58778KB/s, minb=58778KB/s, maxb=58778KB/s, mint=53533msec, maxt=53533msec
WRITE: io=1023.2MB, aggrb=19571KB/s, minb=19571KB/s, maxb=19571KB/s, mint=53533msec, maxt=53533msec
Disk stats (read/write):
sdb: ios=773336/259872, merge=10512/1177, ticks=2450177/843295, in_queue=3293027, util=99.90%
Hopefully you may be able to use some tips from the above.
Best Regards
Lloyd