Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 23 May 1996 22:12:32 +0100 (GMT-1)
From:      af@biomath.jussieu.fr
To:        freebsd-scsi@freebsd.org
Subject:   How to send "start unit" to disk during boot?
Message-ID:  <199605232112.WAA03275@garfield.biomath.jussieu.fr>

next in thread | raw e-mail | index | archive | help
Hi FreeBSDers,

I have  been  given  a  DEC  RZ24  (200Mb)  SCSI  disk  which  I  have
successfully connected to my PC (133Mhz Pentium, Intel Endeavour  m/b,
AHA2940  controller,  IDE  boot  disk). This disk, like some other DEC
disks,   does  *not*  spin  up   when powered up. Other DEC disks have
jumpers to change this, the RZ24 doesn't seem to have them.

When  I  boot  DOS  or enable the AHA2940's BIOS, I can hear the drive
spin  up  and  see  the driver wait for it to become ready. If I don't
enable  the  AHA2940's BIOS and I boot FreeBSD (2.1-RELEASE), the disk
is not spun up and the  mount  fails  (note  that  the  mount  attempt
actually causes it to start spinning, but the FreeBSD driver obviously
does not wait at that time, the SCSI_DELAY wait  occurs  *before*  the
mount  attempt).  If  I soft reboot (CTRL-ALT-DEL) the machine at this
point, the next boot completes OK.

>From  the  FAQ,  I can guess that the SCSI inquiry FreeBSD sends before
waiting SCSI_DELAY does *not* cause the disk to start,  and  then  the
subsequent mount attempt fails. I don't want to enable the AHA2940 BIOS
because  I  want to save high memory for DOS usage (this is a multi-OS
machine) and I'd really love to have this machine boot unattended.

How  can  I  make  FreeBSD  issue  a  "start unit" command to the disk
*before* it waits for SCSI devices to  settle ?  From  my  reading  of
./sys/scsi/sd.c and cd.c, it seems to me that such a thing is done for
CDROM units, but not for disks.

Another possibility I imagined would be to add a scsi(8) command  (and
a sleep(1)) at the very beginning of /etc/rc to send a "start unit" to
the disk. But:

1) this really is an ugly hack (hardcoded device names in /etc/rc)

2) I have not even managed to use scsi(8) to do that, all  my  attempts
(like "scsi -f /dev/rsd0c -c "1b 0 0 0 1 0") have at best produced i/o
errors. I  even have locked up the machine tight sometimes (SCSI
bus  hung)

Would someone please enlighten me ?
Thanks in advance,
_Alain_
--
Alain FAUCONNET    Ingenieur systeme - System Manager     AP-HP/SIM
Public Health                91 bld de l'Hopital 75013 PARIS FRANCE
Medical Computing Research Labs         Mail: af@biomath.jussieu.fr
Tel: (+33) 1-40-77-96-19                   Fax: (+33) 1-45-86-80-68
    I've RTFMed. It says: "Refer to your system administrator"
            But... I *am* the system administrator :-]




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199605232112.WAA03275>