Technical article 104771

Issues with removable SCSI direct-access devices.

OpenServer 5.0.0

Written · Last revised

Problem

Problems have been seen where a direct-access device spins
up or down at inappropriate times.  This causes the
installation to fail and an inability to eject the media.
This has been seen on some Syquest and Bernulli SCSI
direct-access devices.

Solution

Following are two _fst patches, one for SCO XENIX and one for SCO UNIX, which resolve various problems with removable SCSI direct-access devices.

The patches are provided as _fst scripts because this allows
them to be applied to a wide range of SCO XENIX and SCO UNIX
releases without the complexity of providing modified driver
object files for each different release.  This can be
particularly important when patches (such as the XENIX SCSI
driver Support Level Supplement (SLS) xnx316) may or may not
be applied to a system to correct other problems.
=============================================================================

For XENIX, the patch has the following effects:

1. XENIX will no longer attempt to eject the media from a
SCSI removable direct-access device.  The user must manually
eject the disk cartridge when needed.
2. XENIX will also never attempt to eject a SCSI tape device,
even when using the "unload" device nodes.  This is a side-effect
of the disk patch.
The patch is very simple and applies to releases 2.3.2 and 2.3.4
of SCO XENIX, using any version of the Adaptec 154x SCSI host
adapter driver.  (The patch does not affect the behavior of the
other supported host adapter, the IBM Hardfile adapter for
Micro Channel systems).
Because of limitations in the XENIX _fst command, the patch can
only be applied to an already-linked XENIX kernel.  While logged
in as root, enter:
echo scsi_unload+5/h 1 | _fst -w /xenix -

(If /etc/_fst does not exist, try /bin/adb).

The patch will be activated when the system is rebooted from the newly patched kernel.

This patch will be removed any time the kernel is relinked. If, after acceptance testing, you want to have the patch applied automatically each time the kernel is relinked, place the same command in the /usr/sys/conf/hdinstall script after the statement that moves the new kernel into place as /xenix.

Any patches applied to a system should be noted in a system log book.

=============================================================================

For SCO UNIX, the patch has the following effect:

UNIX will no longer instruct the removable hard disk drive
to prevent removal of active media.  The drive then acts
similarly to a standard PC floppy drive: media can be removed
or replaced, while the operating system is using it.  It is
the responsibility of the user to ensure that media is inactive
before being removed.  For instance, a disk containing a
mounted UNIX filesystem should first be unmounted with
umount(ADM) before being physically removed.
The patch is very simple and applies to SCO UNIX Version 4.0,
4.1 and 4.2, SCO Open Desktop Release 2.0 and 3.0, SCO Open
Server 3.0, and SCO OpenServer Release 5.0.0.  The patch can be
used with any SCSI host adapter.
The following patch may be applied either to an already linked
kernel (/unix) or to the SCSI disk peripheral driver
(/etc/conf/pack.d/Sdsk/Driver.o).  It is recommended that it
first be applied to the existing linked kernel for purposes of
acceptance testing.  Once it is verified to work correctly, the
same patch can be applied to the driver object file so that
future kernel relinks will automatically incorporate it.
While logged in as root, enter:
echo Sdsk_prevent_rm?h c3 | _fst -w /unix -

The patch will be activated when the system is rebooted from the newly patched kernel.

This patch will be removed any time the kernel is relinked. If, after acceptance testing, you want to have the patch applied automatically each time the kernel is relinked, use the same patch, substituting /etc/conf/pack.d/Sdsk/Driver.o in place of /unix in the _fst command.

One further parameter affects UNIX's treatment of removable
SCSI hard disks.  If "Sdsk_stop_option" in
/etc/conf/pack.d/Sdsk/space.c is set to 1, the SCSI disk
driver sends a "stop unit" command to the removable hard
disk drive when it believes the system is done accessing
the disk.  We have received reports that this sometimes
happens when the system isn't actually done accessing the
disk.  For this reason, we recommend leaving Sdsk_stop_option
set to its default value of 0.  A disk may be manually spun
down by pressing the "eject" button on the drive.

Any patches applied to a system should be noted in a system log book.

From the Xinuos technical article database, record 104771. Reproduced with permission. The original is at www.sco.com/ta/104771, which is reachable but blocked from search engines. Xinuos marks this article against a retired product line. That refers to the product’s lifecycle, not to whether the advice still works — plenty of it still applies to running systems.

Next step

Need this fixed rather than explained?

Tell us the release, what the system runs and what it is doing. We will reply by email with what we would do next.

  • You deal with the people who do the work
  • No obligation, and no upgrade required before we will help
  • We tell you plainly if something is not worth doing

Send an enquiry

We reply by email. If a server is down, say so in the first line. You can also write to help@scoexpert.com.