Technical article 105353

"NOTICE: Data underrun" message appears when I use a Compaq 32-bit Fast SCSI-2 host adapter.

OpenServer 5.0.0OpenServer 5.0.2OpenServer 5.0.4OpenServer 5.0.5

Written · Last revised

Problem

I am using a Compaq 32-bit Fast SCSI-2 host adapter in my system, and whenever I use SCSI peripherals such as tape drives, I see an error message similar to:

NOTICE: Data underrun ha=0 id=6 lun=0 cmd=3 len=32

This message appears especially frequently if I have installed ARCserve/Open and that product starts a backup job or connects to the tape drive.

In the Troubleshooting ARCserve/Open section of the SCO Server Enhancement Products Release and Installation Notes booklet, there is an instruction to edit the file /etc/conf/pack.d/cha/space.c and change the line:

cha_suppress_underrun = 0x00000000;
to:
cha_suppress_underrun = -1;
but this does not solve the problem.  The line containing
cha_suppress_underrun does not look like this.

Cause

In earlier versions of the cha driver, shipped in versions of the Compaq EFS earlier than 5.10 (efs150), the cha_suppress_underrun flag field was a single integer. It represented only targets 0 to 7 on host adapters 0 to 3. This feature was not available on higher numbered host adapters. The definition was enhanced when wide-SCSI, including support for targets 0 to 15, was added to the cha driver. The cha_suppress_underrun flag field now looks like:

int cha_suppress_underrun[] = {0,0,0,0,0,0,0,0};

Solution

Below is the relevant section of text from /etc/conf/pack.d/cha/space.c:

/*  If necessary, SCSI bus underruns can be totally ignored for
    particular SCSI devices.  Normally this is not done to allow
    detection of abnormal premature end of data on reads.
    Each word in cha_suppress_underrun contains bits for one host
    adapter.
    The first word is for ha=0, etc.  Each 1 bit suppresses
    underrun reporting on all SCSI requests to one SCSI target ID.
    The least significant bit is for SCSI ID 0 on this controller.
*/
int cha_suppress_underrun[] = {0,0,0,0,0,0,0,0};

Each integer in the cha_suppress_underrun array represents one host adapter:

int cha_suppress_underrun[] = {0,0,0,0,0,0,0,0};

Host adapter 0 (the first adapter) is represented by the first integer in the array (the leftmost), and host adapter 7 (the eighth adapter) is represented by the last integer in the array (the rightmost).

Each integer in the array is made up of bits representing target IDs. Bit 0 (the least significant) is for ID 0.

Examples:

1. If the SCSI tape is on ID 6 and connected to host adapter 0, the bits will be:

Bit 15 14 13 12 11 10 9 8  7 6 5 4 3 2 1 0
    --------------------------------------
     0  0  0  0  0  0 0 0  0 1 0 0 0 0 0 0 which is 40 hex.
(binary 01000000 = 40 hex)

and the array should be set to:

int cha_suppress_underrun[] = {0x40,0,0,0,0,0,0,0};

2. If the SCSI tape is on ID 6 and connected to host adapter 1 (which is the second host adapter), the bits will be the same:

Bit 15 14 13 12 11 10 9 8  7 6 5 4 3 2 1 0
    --------------------------------------
     0  0  0  0  0  0 0 0  0 1 0 0 0 0 0 0 which is 40 hex.
(binary 01000000 = 40 hex)

and the array should be set to:

int cha_suppress_underrun[] = {0,0x40,0,0,0,0,0,0};

3. If there are two SCSI tapes, one on ID 6 and the other on ID 3 connected to host adapter 1 (which is the second host adapter), the bits can be set as follows:

Bit 15 14 13 12 11 10 9 8  7 6 5 4 3 2 1 0
   --------------------------------------
     0  0  0  0  0  0 0 0  0 1 0 0 1 0 0 0 which is 48 hex.
(binary 01001000 = 48 hex)

and the array should be set to:

int cha_suppress_underrun[] = {0,0x48,0,0,0,0,0,0};
Therefore, if there are two or more SCSI peripherals on the same                 controller, set the appropriate ID bits and convert the
binary number to a hexadecimal (hex) number.  Assign the
hex number to the array element corresponding to the
host adapter the peripherals are connected to.  Read through
the above examples again if this is not clear.

When the array is set, the kernel should then be relinked with /etc/conf/cf.d/link_unix and the system rebooted.

From the Xinuos technical article database, record 105353. Reproduced with permission. The original is at www.sco.com/ta/105353, which is reachable but blocked from search engines.

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.