I've been trying to set up one of my machines to serve as a SCSI drive to retro computers. I'd like to use my FreeBSD machine to host fast, easily backed-up disk images for them rather than using noisy worn-out SCSI drives.
I'm running FreeBSD 10.3 amd64 on an Intel i7.
The target machine has an Adaptec 29160 (ahc driver) set to unit #7.
The test initiator machine also runs the same version of FreeBSD and has an LSI ultra160 card of some kind (mpt driver) set to unit #6.
Both machines are connected by a 68 pin internal SCSI cable to their internal LVD connectors with the cases open.
No other SCSI devices are in the systems.
I've followed most closely to the steps referenced in targ(4) which are available here: http://www.root.org/~nate/freebsd/scsi/README.targ
I've built my kernel with this configuration:
I create a test file as shown in the link above.
I build /usr/share/examples/scsi_target/ and then run it with either 8 or 16 bit wide options:
or
So far, so good. It seems to be waiting for an initiator.
When I power on the other machine and it begins to scan devices I get the following:
Running
I'm stumped. Thanks for any help you may be able to offer.
I'm running FreeBSD 10.3 amd64 on an Intel i7.
The target machine has an Adaptec 29160 (ahc driver) set to unit #7.
The test initiator machine also runs the same version of FreeBSD and has an LSI ultra160 card of some kind (mpt driver) set to unit #6.
Both machines are connected by a 68 pin internal SCSI cable to their internal LVD connectors with the cases open.
No other SCSI devices are in the systems.
I've followed most closely to the steps referenced in targ(4) which are available here: http://www.root.org/~nate/freebsd/scsi/README.targ
I've built my kernel with this configuration:
Code:
include GENERIC
ident TARGET
device scbus
device da
device targ
device targbh
options CAMDEBUG
options VFS_AIO
device ahc
options AHC_TMODE_ENABLE=0x7f
I create a test file as shown in the link above.
I build /usr/share/examples/scsi_target/ and then run it with either 8 or 16 bit wide options:
./scsi_target -d 0:3:0 test_file
or
./scsi_target -W 16 -d 0:3:0 test_file
So far, so good. It seems to be waiting for an initiator.
Code:
root@:/usr/share/examples/scsi_target # ./scsi_target -W 16 -d 0:3:0 test_file
scsi_target: volume_size: 512 bytes x 40960 sectors
scsi_target: aio support tested ok
scsi_target: opened /dev/targ
scsi_target: sending ccb (0x4)
scsi_target: sending ccb (0x332)
scsi_target: sending ccb (0x336)
scsi_target: sending ccb (0x332)
scsi_target: sending ccb (0x336)
scsi_target: sending ccb (0x332)
scsi_target: sending ccb (0x336)
scsi_target: sending ccb (0x332)
scsi_target: sending ccb (0x336)
scsi_target: sending ccb (0x332)
scsi_target: sending ccb (0x336)
scsi_target: sending ccb (0x332)
scsi_target: sending ccb (0x336)
scsi_target: sending ccb (0x332)
scsi_target: sending ccb (0x336)
scsi_target: sending ccb (0x332)
scsi_target: sending ccb (0x336)
scsi_target: main loop beginning
When I power on the other machine and it begins to scan devices I get the following:
Code:
scsi_target: read ready
scsi_target: event -1 done
scsi_target: Working on INOT 0x80180f720
scsi_target: abort_all_pending
scsi_target: Aborting pending CCB 0x801806200
scsi_target: sending ccb (0x10)
scsi_target: Aborting pending CCB 0x80180f100
scsi_target: sending ccb (0x10)
scsi_target: Aborting pending CCB 0x801806400
scsi_target: sending ccb (0x10)
scsi_target: Aborting pending CCB 0x80180f1e0
scsi_target: sending ccb (0x10)
scsi_target: Aborting pending CCB 0x801806600
scsi_target: sending ccb (0x10)
scsi_target: Aborting pending CCB 0x80180f2c0
scsi_target: sending ccb (0x10)
scsi_target: Aborting pending CCB 0x801806800
scsi_target: sending ccb (0x10)
scsi_target: Aborting pending CCB 0x80180f3a0
scsi_target: sending ccb (0x10)
scsi_target: Aborting pending CCB 0x801806a00
scsi_target: sending ccb (0x10)
scsi_target: Aborting pending CCB 0x80180f480
scsi_target: sending ccb (0x10)
scsi_target: Aborting pending CCB 0x801806c00
scsi_target: sending ccb (0x10)
scsi_target: Aborting pending CCB 0x80180f560
scsi_target: sending ccb (0x10)
scsi_target: Aborting pending CCB 0x801806e00
scsi_target: sending ccb (0x10)
scsi_target: Aborting pending CCB 0x80180f640
scsi_target: sending ccb (0x10)
scsi_target: Aborting pending CCB 0x801807000
scsi_target: sending ccb (0x10)
scsi_target: sending ccb (0x336)
scsi_target: Queue frozen receiving CCB, releasing
scsi_target: sending ccb (0x5)
scsi_target: read ready
scsi_target: event -1 done
scsi_target: Working on INOT 0x80180f3a0
scsi_target: INOT 0x80180f3a0 aborted
scsi_target: sending ccb (0x336)
scsi_target: read ready
scsi_target: event -1 done
scsi_target: Working on INOT 0x80180f640
scsi_target: INOT 0x80180f640 aborted
scsi_target: sending ccb (0x336)
scsi_target: Working on INOT 0x80180f560
scsi_target: INOT 0x80180f560 aborted
scsi_target: sending ccb (0x336)
scsi_target: Working on INOT 0x80180f480
scsi_target: INOT 0x80180f480 aborted
scsi_target: sending ccb (0x336)
scsi_target: Working on INOT 0x80180f2c0
scsi_target: INOT 0x80180f2c0 aborted
scsi_target: sending ccb (0x336)
scsi_target: Working on INOT 0x80180f1e0
scsi_target: INOT 0x80180f1e0 aborted
scsi_target: sending ccb (0x336)
scsi_target: Working on INOT 0x80180f100
scsi_target: INOT 0x80180f100 aborted
scsi_target: sending ccb (0x336)
scsi_target: Working on ATIO 0x801806200
scsi_target: ATIO 0x80180e040 aborted: Invalid argument
scsi_target: sending ccb (0x332)
scsi_target: Working on ATIO 0x801806400
scsi_target: ATIO 0x80180e080 aborted: Invalid argument
scsi_target: sending ccb (0x332)
scsi_target: Working on ATIO 0x801806600
scsi_target: ATIO 0x80180e0c0 aborted: Invalid argument
scsi_target: sending ccb (0x332)
scsi_target: Working on ATIO 0x801806800
scsi_target: ATIO 0x80180e100 aborted: Invalid argument
scsi_target: sending ccb (0x332)
scsi_target: Working on ATIO 0x801806a00
scsi_target: ATIO 0x80180e140 aborted: Invalid argument
scsi_target: sending ccb (0x332)
scsi_target: Working on ATIO 0x801806c00
scsi_target: ATIO 0x80180e180 aborted: Invalid argument
scsi_target: sending ccb (0x332)
scsi_target: Working on ATIO 0x801806e00
scsi_target: ATIO 0x80180e1c0 aborted: Invalid argument
scsi_target: sending ccb (0x332)
scsi_target: Working on ATIO 0x801807000
scsi_target: ATIO 0x80180e200 aborted: Invalid argument
scsi_target: sending ccb (0x332)
Running
camcontrol rescan 0
on the initiator finds no new drives. camcontrol devlist
shows only my sata devices.I'm stumped. Thanks for any help you may be able to offer.