Other ctld (iSCSI)

Hi,

I would like to experiment with iSCSI but I'm having problems with the configuration.

Code:
portal-group pg0 {
        discovery-auth-group no-authentication
        listen 0.0.0.0
        listen [::]
}

target iqn.localhost:target0 {
        auth-group no-authentication
        portal-group pg0

        lun 0 {
                path /data/target0-0
                size 2G
        }
}

1. What is this iqn thing? What would be the correct reversely written hostname if I want to just use ctld on
localhost?

2. What is /data/target0-0 ?

3. what is the size parameter?

I have SCSI devices on sym0 host, and would like to make them available to e.g. VirtualBox using iSCSI since otherwise (if at all) I see no way to map my SCSI bus into VirtualBox and make the devices somehow visible to the
VM (WIndows XP).

TIA,

Christoph
 
OK. That's my ctl.conf now:
Code:
portal-group pg0 {
        discovery-auth-group no-authentication
        listen 0.0.0.0:3260
}

target iqn.2020-05-04.box.fritz.pc235:target0 {
        auth-group no-authentication
        portal-group pg0

        lun 0 {
                path /dev/cd1
                size 2G
        }
}

I'm not sure about the size parameter. A CD normally is 687974400 bytes. Does the size parameter have to match this value exactly?


when starting:
Code:
service ctld start

it seems to hang. The command lasts minutes to come back to the prompt.

It begins to look interesting. I started iscsid.

Code:
cd1 at sym0 bus 0 scbus7 target 4 lun 0
cd1: <TEAC CD-R55S 1.0R> Removable CD-ROM SCSI-2 device
cd1: Serial Number 8X32458B
cd1: 10.000MB/s transfers (10.000MHz, offset 8)
cd1: 656MB (335925 2048 byte sectors)
(probe0:sym0:0:4:7): INQUIRY. CDB: 12 e0 00 00 24 00
(probe0:sym0:0:4:7): CAM status: Auto-Sense Retrieval Failed
(probe0:sym0:0:4:7): Error 5, Unretryable error
WARNING: 10.10.10.10 (iqn.2020-05-04.box.fritz.pc235:target0): login timed out after 61 seconds; reconnecting
da4 at iscsi2 bus 0 scbus9 target 0 lun 0
da4: <FREEBSD CTLDISK 0001> Fixed Direct Access SPC-5 SCSI device
da4: Serial Number MYSERIAL0000
da4: 150.000MB/s transfers
da4: Command Queueing enabled
da4: Attempt to query device size failed: NOT READY, Logical unit not ready, manual intervention required
WARNING: 10.10.10.10 (iqn.2020-05-04.box.fritz.pc235:target0): login timed out after 61 seconds; reconnecting

In the first place I gave a wrong IP host to connect to (10.10.10.10). iscsid seem to never forget. It's continuously trying to connect to that address (10.10.10.10). How can I make iscsid make forget about that wrong attempt. Does it cache this somewhere? Second time I gave localhost as the address and it fund already the correct scsi device (da4 at scsi2 - via /dev/cd1). Amazing. Now I gotta make that visible in VirtualBox.
 
The joy was premature: trying to connect to the device give the following:

Code:
da4 at iscsi1 bus 0 scbus9 target 0 lun 0
da4: <FREEBSD CTLDISK 0001> Fixed Direct Access SPC-5 SCSI device
da4: Serial Number MYSERIAL0000
da4: 150.000MB/s transfers
da4: Command Queueing enabled
da4: Attempt to query device size failed: NOT READY, Logical unit not ready, manual intervention required

This is with
Code:
iscsictl -An t0
and
Code:
/etc/iscsi.conf:

t0 {
       TargetAddress = localhost
       Targetname = iqn.2020-05-04.box.fritz.pc235:target0
}

A CD is inserted in the drive.
 
Back
Top