Re: iSCSI Target and raw devices



On Tue, Sep 25, 2007 at 06:19:30PM -0400, Mark Saad wrote:
Does anyone know off hand if this works in FreeBSD or NetBSD?

The last time (about 1.5 months ago) I tried the iSCSI target from
ports -- net/iscsi-target, it had some issues.

The first was that it didn't work with raw devices. The cause was that
in a couple places it tries to read a single byte from the device, but
on FreeBSD where everything is a character device you have to read using
the block size. I suspect that NetBSD still has buffered block devices
so it isn't an issue there.

I hacked it locally to read 512 (at mediasize-512 instead of
mediasize-1) for its test and that seemed to work, but it was pretty
ugly. The right way would be to use an ioctl to get the block size I
think.

The other thing was that it was listening on a different port number
than the FreeBSD initiator was trying to connect to. For some reason
even though iscsi-target claims to have a "-p" option to specify the
port number, after reading the code it was clear that it doesn't
actually use that value for anything and instead is hardcoded to use
whatever is in /etc/services.

I checked the NetBSD cvs and the same issue existed there. Reading the
code gave me the distinct impression that it was incomplete.

The second question what iscsi initiators are out there ? Along time
ago Lucent had iscsi software for FreeBSD 4.x which has initiator
support but this has a restrictive license and does not support anything
newer then 4.9-RELEASE . Does anyone know what else could possibly be
used on 6-STABLE ?

I'm not sure about 6-STABLE, though a kernel initiator was added to 7
not too long ago.

Craig
_______________________________________________
freebsd-hackers@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscribe@xxxxxxxxxxx"



Relevant Pages

  • Re: SCSI Queue algorithm modifier
    ... It is allowed to support only one algorithm, in this case it is set by ... an initiator can change it. ... implementing the SCSI layer of an iSCSI target library. ... policy as allowed for the Control Mode page, ...
    (comp.periphs.scsi)
  • Re: ISCSI target on FreeBSD
    ... is causing a little-bit hitch is the availability of ISCSI target ... targets to Solaris based initiators, but i want to move out from it and ... come onto FreeBSD world. ...
    (freebsd-stable)
  • iSCSI target problem
    ... I was sick with iSCSI target and initiator on Solaris 10 x86. ... iscsiadm modify initiator-node -a CHAP ...
    (comp.unix.solaris)
  • iscsi
    ... Is there any limitation on attaching iscsi target disks to iscsi ... have been attached to one server (which is initiator). ... also have you heard any thing about RAID5 limitation, ...
    (SunManagers)
  • ISCSI target on FreeBSD
    ... I am very new to FreeBSD and am willing to explore it. ... is causing a little-bit hitch is the availability of ISCSI target ...
    (freebsd-stable)