Hi all, I'm in the last mile before crossing the beta->release line, so I'd like to get some input, and update the list of targets it supports. you can obtain the driver from: ftp://ftp.cs.huji.ac.il/users/danny/freebsd/iscsi-2.0.92.tar.gz Cheers, danny
Quoting Danny Braniss <danny@cs.huji.ac.il>:> I'm in the last mile before crossing the beta->release line, > so I'd like to get some input, and update the list of targets it supports. > you can obtain the driver from: > ftp://ftp.cs.huji.ac.il/users/danny/freebsd/iscsi-2.0.92.tar.gzLooks great! I've done some basic testing against our cluster of three LeftHand Networks NSM 160's running SAN/iQ 6.6SP1. My machine is running -CURRENT as of a couple days ago (with gcc 4.2 and symbol versioning). I've tested previous snapshots of the driver against the same SAN on this and another machine running -STABLE with good results. Is there anything specific you'd like tested? What connection interruption scenarios does the driver try to recover from? I'm running some backups to an iSCSI mount now. When that finishes (and my machine is otherwise unoccupied) I'll play around with temporarily yanking the ethernet cable and other fun tricks. Thanks for the Makefiles. Your blurb text incorrectly directs the reader to run make in sys/dev/iscsi_initiator (which doesn't exist, and there's no Makefile in sys/dev/iscsi). Obviously you meant sys/modules/iscsi_initiator. Also, a line about running make in iscontrol/ would be helpful, as would an install target in that Makefile. Do you have any suggestions on startup integration (rc script, fstab magic, etc)? I know you said once before that that was hopefully coming soon.. Thanks again. I'll post again if I manage to break something. JN
> Quoting Danny Braniss <danny@cs.huji.ac.il>: > > I'm in the last mile before crossing the beta->release line, > > so I'd like to get some input, and update the list of targets it supports. > > you can obtain the driver from: > > ftp://ftp.cs.huji.ac.il/users/danny/freebsd/iscsi-2.0.92.tar.gz > > Looks great! I've done some basic testing against our cluster of three > LeftHand Networks NSM 160's running SAN/iQ 6.6SP1. My machine is > running -CURRENT as of a couple days ago (with gcc 4.2 and symbol > versioning). I've tested previous snapshots of the driver against the > same SAN on this and another machine running -STABLE with good results. >so i'm updating my Targets file.> Is there anything specific you'd like tested? What connection > interruption scenarios does the driver try to recover from? I'm running > some backups to an iSCSI mount now. When that finishes (and my machine > is otherwise unoccupied) I'll play around with temporarily yanking the > ethernet cable and other fun tricks. >it 'should' recover from network disconects, like pulling out cable, or rebooting the target, but I think that this will only work if there is no major activity - I better test this one again. it should also flush buffers when you shut down the host, this was a major pain with the old versions.> Thanks for the Makefiles. Your blurb text incorrectly directs the > reader to run make in sys/dev/iscsi_initiator (which doesn't exist, and > there's no Makefile in sys/dev/iscsi). Obviously you meant > sys/modules/iscsi_initiator. Also, a line about running make in > iscontrol/ would be helpful, as would an install target in that > Makefile.ok, fixed the 'typos', I also forgot the sample rc.d/iscsi,> > Do you have any suggestions on startup integration (rc script, fstab > magic, etc)? I know you said once before that that was hopefully coming > soon.. >this is an attempt: #!/bin/sh # PROVIDE: iscsi # REQUIRE: NETWORKING # BEFORE: DAEMON # KEYWORD: nojail shutdown # # Add the following lines to /etc/rc.conf to enable iscsi: # # iscsi_enable="YES" # iscsi_fstab="/etc/fstab.iscsi" . /etc/rc.subr name=iscsi rcvar=`set_rcvar` command=/usr/local/sbin/iscontrol iscsi_enable=${iscsi_enable:-"NO"} iscsi_fstab=${iscsi_fstab:-"/etc/fstab.iscsi"} iscsi_exports=${iscsi_exports:-"/etc/exports.iscsi"} start_cmd="iscsi_start" faststop_cmp="iscsi_stop" stop_cmd="iscsi_stop" iscsi_wait() { dev=$1 trap "echo 'wait loop cancelled'; exit 1" 2 count=0 while true; do if [ -c $dev ]; then break; fi if [ $count -eq 0 ]; then echo -n Waiting for ${dev}': ' fi count=$((${count} + 1)) if [ $count -eq 6 ]; then echo ' Failed' return 0 break fi echo -n '.' sleep 5; done echo '.' return 1 } iscsi_start() { # # load needed modules for m in iscsi_initiator geom_label; do kldstat -qm $m || kldload $m done sysctl debug.iscsi=2 # # start iscontrol for each target if [ -n "${iscsi_targets}" ]; then for target in ${iscsi_targets}; do ${command} ${rc_flags} -n ${target} done fi if [ -f "${iscsi_fstab}" ]; then while read spec file type opt t1 t2 do case ${spec} in \#*|'') ;; *) if iscsi_wait ${spec}; then break; fi echo type=$type spec=$spec file=$file fsck -p ${spec} && mount ${spec} ${file} ;; esac done < ${iscsi_fstab} fi if [ -f "${iscsi_exports}" ]; then cat ${iscsi_exports} >> /etc/exports #/etc/rc.d/mountd reload does not work, why? kill -1 `cat /var/run/mountd.pid` fi } iscsi_stop() { echo 'iscsi stopping' while read spec file type opt t1 t2 do case ${spec} in \#*|'') ;; *) echo iscsi: umount $spec umount -fv $spec # and remove from the exports ... ;; esac done < ${iscsi_fstab} } load_rc_config $name run_rc_command "$1" ------ problems with the above script: - no background fsck - restart will mess the exports file - the wait loop should be replaced by something more deterministic.> Thanks again. I'll post again if I manage to break something. >Ok, but can't say I look forward to hear from you :-) danny
Quoting Ivan Voras <ivoras@fer.hr>:> Danny Braniss wrote: >> I'm in the last mile before crossing the beta->release line, >> so I'd like to get some input, and update the list of targets it supports. >> you can obtain the driver from: >> ftp://ftp.cs.huji.ac.il/users/danny/freebsd/iscsi-2.0.92.tar.gz > > I think I can test in on our SAN but the only machine attached to it > runs 6-STABLE. Will your iSCSI intiator work in -STABLE?This is actually the first snapshot of the initiator that I've tried that works on -CURRENT. Previous ones have always worked on -STABLE and I don't see any reason that this one wouldn't.> Also, do you plan to finish it in time to get it included in 7.0?I can't comment on that, but I agree it would be nice.. JN
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Danny Braniss wrote:> > Hi all, > > I'm in the last mile before crossing the beta->release line, > > so I'd like to get some input, and update the list of targets itsupports.> > you can obtain the driver from: > > ftp://ftp.cs.huji.ac.il/users/danny/freebsd/iscsi-2.0.92.tar.gzJust tried it out. Set up a vmware FreeBSD 6.2 install on my windows box. Installed the kernel module and initiator program and targeted it at an OpenSolaris machine running ZFS and exporting a 1GB volume over iSCSI on our network. Did a newfs on the imported iSCSI /dev/da0 and mounted it OK. Copied files over to it OK. Ran bonnie++ over it as an experiment. Had the following kernel message pop-up twice, however: lnc0: Missed packet -- no receive buffer Not sure what the cause was. Perhaps I was just thrashing out my virtual NIC... -----BEGIN PGP SIGNATURE----- iD8DBQFGZ8lGcuckYiL1ACcRAgOcAKCIjdUMGZe+e+eqq6wI5zu20kx5EgCeNO6F MUKU9HSk5IQUFVehTKs9vt4=gKDc -----END PGP SIGNATURE-----
Nathan Butcher wrote:> Danny Braniss wrote:<snip>> lnc0: Missed packet -- no receive buffer > > Not sure what the cause was. Perhaps I was just thrashing out my virtual > NIC...Yeah, thats an issue with the default vmware emulated nic... Ta, Joe
> This is an OpenPGP/MIME signed message (RFC 2440 and 3156) > --------------enig2465C3FB4D976B8B44FBA3F0 > Content-Type: text/plain; charset=UTF-8 > Content-Transfer-Encoding: quoted-printable > > Danny Braniss wrote: > > Hi all, > > I'm in the last mile before crossing the beta->release line, > > so I'd like to get some input, and update the list of targets it suppor> ts. > > you can obtain the driver from: > > Have you tested it with net/iscsi-target from ports? I get the following > messages and errors when I try it: > > Jun 7 22:53:08 finstall kernel: ic_action: called > Jun 7 22:53:08 finstall kernel: ic_action: func_code=3D0x901 flags=3D0xc> 0 > status=3D0x0 target=3D0 lun=3D0 retry_count=3D1 timeout=3D300000 > Jun 7 22:53:08 finstall kernel: ic_action: XPT_SCSI_IO cmd=3D0x35 > Jun 7 22:53:08 finstall kernel: scsi_encap: called > Jun 7 22:53:08 finstall kernel: scsi_encap: ccb->sp=3D0xc2e97c00 > Jun 7 22:53:08 finstall kernel: dwl: called > Jun 7 22:53:08 finstall kernel: isc_qout: called > Jun 7 22:53:08 finstall kernel: 0] isc_qout: enqued: pq=3D0xc37ff0bc > Jun 7 22:53:08 finstall kernel: proc_out: called > Jun 7 22:53:08 finstall kernel: 0] proc_out: opcode=3D0x1 sn(cmd=3D0x27 > expCmd=3D0x26 maxCmd=3D0x26 expStat=3D0x0 itt=3D0x27) > Jun 7 22:53:08 finstall kernel: isc_sendPDU: called > Jun 7 22:53:08 finstall kernel: 0] ism_proc: odone=3D1 > Jun 7 22:53:08 finstall kernel: proc_out: called > Jun 7 22:53:08 finstall kernel: 0] ism_proc: odone=3D0 > Jun 7 22:53:08 finstall kernel: so_input: called > Jun 7 22:53:08 finstall kernel: so_getbhs: called > Jun 7 22:53:08 finstall kernel: proc_out: called > Jun 7 22:53:08 finstall kernel: 0] ism_proc: odone=3D0 > Jun 7 22:53:08 finstall kernel: so_recv: called > Jun 7 22:53:08 finstall kernel: 0] so_recv: len=3D48] opcode=3D0x21 > ahs_len=3D0x0 ds_len=3D0x0 > Jun 7 22:53:08 finstall kernel: ism_recv: called > Jun 7 22:53:08 finstall kernel: 0] ism_recv: opcode=3D0x21 itt=3D0x27 > stat#0x1 maxcmd=3D0x27 > Jun 7 22:53:08 finstall kernel: _scsi_rsp: called > Jun 7 22:53:08 finstall kernel: _scsi_rsp: itt=3D27 pq=3D0xc37ff5e0 > opq=3D0xc37ff0bc > Jun 7 22:53:08 finstall kernel: iscsi_done: called > Jun 7 22:53:08 finstall kernel: _scsi_done: called > Jun 7 22:53:08 finstall kernel: _scsi_done: ccb_h->status=3D1 > Jun 7 22:53:08 finstall kernel: so_input: called > Jun 7 22:53:08 finstall kernel: so_getbhs: called > Jun 7 22:53:08 finstall kernel: proc_out: called > Jun 7 22:53:08 finstall kernel: 0] ism_proc: odone=3D0 > Jun 7 22:53:08 finstall iscontrol[2084]: cam_open_btl: no passthrough > device found at 1:0:1 > Jun 7 22:53:08 finstall iscontrol[2084]: cam_open_btl: no passthrough > device found at 1:0:2 > Jun 7 22:53:08 finstall iscontrol[2084]: cam_open_btl: no passthrough > device found at 1:0:3 > Jun 7 22:53:38 finstall kernel: _nop_out: called > Jun 7 22:53:38 finstall kernel: 0] _nop_out: cws=3D1 > Jun 7 22:53:38 finstall kernel: proc_out: called > Jun 7 22:53:38 finstall kernel: 0] ism_proc: odone=3D0 > > The message on the machine running scsi-target is: "Unsupported INQUIRY > VPD page 80"yes, I have tested it against ports/net/iscsi-target, I use it to try out errror recovery :-), and as far as I could tell it's harmelss. Anothere thing I can report is that running both (target/initiator) does not work, and it seems that the target gets stuck. danny