Good day.  I am glad I have the chance to play with NetBSD again.  Yesterday I 
put pxeboot_ia32.bin inside pxelinux.cfg/default, so I could PXE while I PXE:-) 
 Seriously, it went fine, and the the vendor-class-identifier trick helped the 
dhcp server differentiate normal BOOTP requests from those initiated by pxeboot 
-- this is only optional, one can also provide 'netbsd.gz' at the root of the 
tftp share to avoid interacting with the boot prompt.  I was just in the mood 
to talk.

Today's topic is rather iSCSI.  I am pleased to read in the NetBSD 7.1 
TARGETS(5) manual that,

     It is possible to use the word ``size'' to use the full size of the pre-
     existing regular file given in the extent name.

However I then realized that it goes for _file_ extends only, not bsd 
partitions.  In fact, when setting up an extend as a partition,

        # extent        file or device          start           length
        extent0         /dev/rwd0e               0               size

        # target        flags   storage         netmask
        target0         rw      extent0         0.0.0.0/0

I get this error when trying to start iscsi target daemon (identified size is 
**zero**),

        Starting iscsi_target.
        Reading configuration from `/etc/iscsi/targets'
        target0:rw:0.0.0.0/0
                extent0:/dev/rwd0e:0:0
        DISK: 1 logical unit (0 blocks, 512 bytes/block), type iscsi fs
        DISK: LUN 0: pid 
423:/usr/src/external/bsd/iscsi/lib/../dist/src/lib/disk.c:720: ***ERROR*** 
error reading "target0"
        pid 423:/usr/src/external/bsd/iscsi/lib/../dist/src/lib/disk.c:886: 
***ERROR*** error allocating space for "target0"
        pid 423:/usr/src/external/bsd/iscsi/lib/../dist/src/lib/target.c:1990: 
***ERROR*** device_init() failed
        iscsi_target_start() failed

So I guess all I could wish for is the 'size' feature to be able to handle 
devices sizes automatically.

Best regards and thank you for the good code
-- 
Pierre-Philipp

Reply via email to