[sane-devel] Mandrake 9.1 and ServeRAID 5i

abel deuring a.deuring@satzbau-gmbh.de
Wed, 17 Sep 2003 13:12:02 +0200


Raf Schietekat wrote:
> 
> abel deuring wrote:
> 
> >[...]
> > Well, some RAID controllers have themselves an SG device file for
> > "maintenance purposes": to configure, which disks belong to an array, to
> > replace a disk in an array and whatever else you can do with a RAID
> > contoller. And the ServeRaid seems to be such a controller, so there is
> > a need for SG device file nodes under /dev. While this also means that
> > the virtual RAID disks will have both an SG and an SD device file, it
> > should not cause any risk to issue two INQUIRY commands to their SG
> > device file, if they behave well...
> 
> Let's see, with the test you suggested (IBM says they won't support
> Mandrake, so...):
> # export SANE_DEBUG_SANEI_SCSI=255
> # sane-find-scanner -v 2>&1 | tee /mnt/floppy/log-v
> No failure, even after a few repetitions. In a different shell (I admit
> I don't immediately know how to get rid of SANE_DEBUG_SANEI_SCSI otherwise):
> # sane-find-scanner -q 2>&1 | tee /mnt/floppy/log-q
> # while true; do sane-find-scanner -q > /dev/null; done
> No failure. Hmm, strange, nothing on the floppy, and the files are still

So it seems that neither the RAID controller nor its Linux driver nor
sane-find-scanner is buggy.

> in /mnt/floppy when looking from the shell (even though the floppy is no
> longer in the drive). Guess I'll still have to configure that, somehow
> (luckily it was not required). Well, anyway, this is what's in log-q:
> found SCSI processor "IBM SERVERAID 1.00" at /dev/sg1
> found SCSI processor "IBM 32P0042a S320  1 1" at /dev/sg2
> found SCSI processor "IBM SERVERAID 1.00" at /dev/sgb
> found SCSI processor "IBM 32P0042a S320  1 1" at /dev/sgc
> My questions to you:
> - Isn't sane-find-scanner supposed to only find scanners? Shouldn't it
> return nothing, and isn't this the first stone falling in a domino effect?

You're right, in general ;) The problem are some HP scanners. (I think,
models like the scanjet 2, 3 and 4.) These scanners don't use the SCSI
commands defined for scanners (like "set scan window" or "start scan").
Instead they have have their own command language, called HP-SCL or
similar. Hence they can't claim to be "regular SCSI scanners", but
return "I'm a SCSI processor" in the INQUIRY data.

This device type is used by all those SCSI devices which aren't
"ordinary" SCSI devices like hard disks, tape drives, CDROMs etc.
Another example for a SCSI processor device it the "robot part" of a
tape changer. 

sane-find-scanner lists all processor devices, just to be sure that no
device is missed, which is *possibly* a scanner. It is up to the user or
the calling program to decide, if the device called "IBM SERVERAID 1.00"
is indeed a scanner or something else -- in this case the "management
part" of a RAID controller.

> - Maybe the rest of scannerdrake etc. invokes other SANE programs for
> these devices, that will upset the RAID card? Does that sound plausible?
> I'll go have a look anyway.

Yes, scannerdrake might indeed call a program like scanimage. scanimage
is mainly a command line scan program, but it can also be used to list
all scanners that are connected to a host and supported by a Sane
backend.

If you run something like "strace scannerdrake", you should be able to
see, which programs are invoked by scannerdrake -- but that will produce
tons of debug output: I'm not sure, if the stuff will fit onto a floppy
disk... 

Abel