home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / sys / sgi / 11152 < prev    next >
Encoding:
Text File  |  1992-07-21  |  20.6 KB  |  450 lines

  1. Newsgroups: comp.sys.sgi
  2. Path: sparky!uunet!darwin.sura.net!mips!odin!fido!zola!zuni!anchor!olson
  3. From: olson@anchor.esd.sgi.com (Dave Olson)
  4. Subject: Re: SCSI Disk Problem? (1.6 MB Seagate) [ with SCSI error info ]
  5. Message-ID: <njj76k8@zuni.esd.sgi.com>
  6. Sender: news@zuni.esd.sgi.com (Net News)
  7. Organization:  Silicon Graphics, Inc.  Mountain View, CA
  8. References: <1992Jul22.022754.10599@ringer.cs.utsa.edu>
  9. Date: Wed, 22 Jul 92 03:17:33 GMT
  10. Lines: 438
  11.  
  12. In <1992Jul22.022754.10599@ringer.cs.utsa.edu> senseman@ricky.brainlab.utsa.edu (David M. Senseman) writes:
  13.  
  14.  
  15. | We recently installed a 1.6 GB Seagate drive on the external
  16. | SCSI connector of an Indigo XS-24 (IRIX 4.0.5). The hardware
  17. | inventory is as follows:
  18.  
  19. |     sc0,4,0: cmd=0x1b timeout after 60 sec.  Resetting SCSI Bus
  20. |     SCSI device/cable diagnostic     * FAILED *
  21.  
  22. You almost certainly don't have the drive jumpered to not spinup
  23. until a startunit cmd is received.  When not jumpered this way,
  24. various drives will not respond to commands, or will accept commands
  25. but not complete them, etc.  In this case, the firmware appears to
  26. be somewhat confused, since a startunit command was issued (0x1b),
  27. but it timed out.  These drives should spinup in far less than 60
  28. seconds.  If the drive *is* jumpered to not spin up at poweron,
  29. then something is wrong with the drive.
  30.  
  31. | If you continue on with the start-up, the computer seems to
  32. | be fine. At least the 1.6 Gb disk seems to work alright. (see below).
  33. | I tried fiddling with the Motor On jumpers -- didn't seem to help
  34. | either way (on or off). The drive is NOT terminated so I removed
  35. | the "tp" jumpers.
  36. | We are also have some problems with the QIC and DAT tape drives
  37. | on this machine -- they tend to quit prematurely with 
  38. | unrecoverable errors. Sometimes they report I/O errors. The errors
  39. | _seem_ to be more numerous since we installed the Seagate. Is
  40. | is possible for the disk to work fine but screw up the tape drives?
  41.  
  42. Sounds like something is wrong with the SCSI bus.  Are you sure
  43. that the cable to the external drive is a real, honest to god,
  44. SCSI cable, and not a cheap lookalike ;)  Seriously, some centronics
  45. printer cables look just like SCSI cables, but have smaller conductors,
  46. and don't always have all pins connected, particularly some of the
  47. grounds.
  48.  
  49. Of course, even that wouldn't explain the earlier errors.  Check
  50. for unix: messages in /usr/adm/SYSLOG, and see if they indicate
  51. anything.
  52.  
  53. | Senseman's First Rule of Computers says that 99% of all computer
  54. | hardware errors is due to a bad cable -- and I suspect that
  55. | this is the most likely candidate here. However, before I go
  56. | into the cable making business, I wanted to know if anyone else
  57. | might had seen this problem with the 1.6 GB Seagate drive before.
  58. | I had a 140 Toshiba drive in there previously and didn't experience
  59. | any problems with it so maybe the cable not bad?
  60.  
  61. That drive (but not necessarily the firmware rev you have) has been
  62. qualified by the other division, and should work on an Indigo.
  63.  
  64. By the way, here is a (slightly out of date) list of SCSI error messages
  65. from the wd93 scsi driver, along with sense codes, and in some cases,
  66. likely causes for the error message.   I provided the raw data, and
  67. one of the TAC engineers cleaned it up.
  68.  
  69. There may be minor errors or inconsistencies that we haven't spotted,
  70. but in general should prove helpful.
  71.  
  72. =================================================================
  73. DATE
  74.     November 8, 1991
  75.  
  76. TITLE
  77.     Small Computer Interface (SCSI) Controller Error Messages
  78.  
  79. QUESTION
  80.     What do the phase and sense errors mean?
  81.  
  82. ANSWER
  83.  
  84.     This article lists the error strings that are printed by the
  85.     device drivers, tpsc, dksc, and (in some cases) devscsi. The 
  86.     specific parts of these error strings are contained in 
  87.     Tables 1 - 4, which follow the introductin of this article. 
  88.     
  89.     In the IRIX 3.3.3 release the Jaguar SCSI controller board (jag)
  90.     driver prints the information differently than the dksc driver;
  91.     in 4.0.1, they use the same form.  In IRIX 3.3.3, the information
  92.     is printed in the form:
  93.  
  94.           sense codes. key %x asc%x asq%x
  95.  
  96.     where
  97.           key is the number from Table 1,  
  98.           asc (additional sense code) is from Table 2, 
  99.           asq (additional sense qualifier) sometimes provides additional info. 
  100.          
  101.           NOTE: often there is only one possible asq for a given asc.
  102.  
  103.              
  104.     An example of a media error string is:
  105.  
  106.           jag0d2: sense key 3 asc11 asq0 (retry 2)
  107.             |            |       |     |    
  108.             |            |       |     |    
  109.           device number  |       | No additional 
  110.                          |       | information 
  111.                          |       |  
  112.                   "Media Error"  |
  113.                   (see Table 1)  |
  114.                                  |
  115.                          "Unrecovered data
  116.                           block read error"
  117.                           (see Table 2)
  118.  
  119.     The asq tends to be more vendor specific, although the IEEE SCSI 2  
  120.     specification defines the "standard" sense qualifiers.
  121.  
  122.     The integral SCSI controller on your system also often prints messages
  123.     in the form:
  124.  
  125.           sc#[,#,#]: message 
  126.     
  127.     where
  128.         
  129.           the first # is the SCSI adapter involved (0 for all
  130.           systems except those with the IO3 (input/output board) which
  131.           supports up to 4 adapters, 0-3),
  132.  
  133.           the second #,# pair is printed only if you know which device
  134.           is causing the problem. 
  135.    
  136.     An example of this type of message string is:
  137.  
  138.     SC0,1: resetting SCSI bus: Spurious SCSI interrupt, no connected channel    
  139.       
  140.     In a number of cases, a phase and possibly a state are printed. 
  141.     These error codes come from the files,
  142.     
  143.         usr/include/sys/scsidev.h.  
  144.         usr/include/sys/scsi.h
  145.  
  146.     The state and phase meanings are listed in Table 4.  A few comments 
  147.     have been added. Some of the messages are also included.
  148.  
  149.     NOTE: These tables are used by the smfd, tpsc, and dksc drivers
  150.           and will probably be used by other SCSI drivers in the 
  151.           future.  That is why they are now in scsi.c, even though 
  152.           not referenced here. 
  153.  
  154.     Table 1 - Primary sense key information
  155.     -------
  156.  
  157.  
  158.      Message                  Sense Key      Most common cause(s)
  159.  
  160.    No sense                      0x0   No error information available
  161.    Recovered Error               0x1   The device recovered by itself
  162.    Drive not ready               0x2   No media or not spun up
  163.    Media error                   0x3   An actual media problem
  164.    Unrecoverable device error    0x4   Usually a device hardware error
  165.    Illegal request               0x5   Invalid command or data issued
  166.    Unit Attention                0x6   Device was reset or power cycled
  167.    Data protect error            0x7   Usually device is write protected
  168.    Unexpected blank media        0x8   Tried to read at end of a tape
  169.    Vendor Unique error           0x9   Varies
  170.    Copy Aborted                  0xa   Copy cmd aborted by host (not used)
  171.    Aborted command               0xb   Target aborted command
  172.    Search data successful        0xc   Search Data command OK (not used)
  173.    Volume overflow               0xd   Tried to write past EOT on tape
  174.    Reserved (0xE)                0xe   should not be seen
  175.    Reserved (0xF)                0xf   should not be seen
  176.  
  177.  
  178.                Table 2 - Additional Sense Code
  179.     This table provides further information on the cause of an error.
  180.     The ASQ (additional sense qualifier) which is printed numerically
  181.     when non-zero (in 4.0; in 3.3.3 it is always printed by the Jaguar)
  182.     Missing numerical values are not printed, either because they are no
  183.     defined, or because the drivers treat them specially.
  184.     This table is provided primarly so the additional sense codes
  185.     can be looked up in the device manual.  Some are self explanatory,
  186.     others quite obscure.
  187.  
  188.          Message                    Additional Sense Code
  189.  
  190.       No index/sector signal             0x01
  191.       No seek complete                   0x02
  192.       Write fault                        0x03
  193.       Driver not ready                   0x04
  194.       Drive not selected                 0x05
  195.       No track 0                         0x06
  196.       Multiple drives selected           0x07
  197.       LUN communication error            0x08
  198.       Track error                        0x09
  199.       Error log overflow                 0x0a
  200.       Write error                        0x0c
  201.       ID CRC or ECC error                0x10
  202.       Unrecovered data block read error  0x11
  203.       No addr mark found in ID field     0x12
  204.       No addr mark found in Data field   0x13
  205.       No record found                    0x14
  206.       Seek position error                0x15
  207.       Data sync mark error               0x16
  208.       Read data recovered with retries   0x17
  209.       Read data recovered with ECC       0x18
  210.       Defect list error                  0x19
  211.       Parameter overrun                  0x1a
  212.       Synchronous transfer error         0x1b
  213.       Defect list not found              0x1c
  214.       Compare error                      0x1d
  215.       Recovered ID with ECC              0x1e
  216.       Invalid command code               0x20
  217.       Illegal logical block address      0x21
  218.       Illegal function                   0x22
  219.       Illegal field in CDB               0x24
  220.       Invalid LUN                        0x25
  221.       Invalid field in parameter list    0x26
  222.       Media write protected              0x27
  223.       Media change                       0x28
  224.       Device reset                       0x29
  225.       Log parameters changed             0x2a
  226.       Copy requires disconnect           0x2b
  227.       Command sequence error             0x2c
  228.       Update in place error              0x2d
  229.       Tagged commands cleared            0x2f
  230.       Incompatible media                 0x30
  231.       Media format corrupted             0x31
  232.       No defect spare location available 0x32
  233.       Media length error                 0x33
  234.       Toner/ink error                    0x36
  235.       Parameter rounded                  0x37
  236.       Saved parameters not supported     0x39
  237.       Medium not present                 0x3a
  238.       Forms error                        0x3b
  239.       Invalid ID msg                     0x3d
  240.       Self config in progress            0x3e
  241.       Device config has changed          0x3f
  242.       RAM failure                        0x40
  243.       Data path diagnostic failure       0x41
  244.       Power on diagnostic failure        0x42
  245.       Message reject error               0x43
  246.       Internal controller error          0x44
  247.       Select/Reselect failed             0x45
  248.       Soft reset failure                 0x46
  249.       SCSI interface parity error        0x47
  250.       Initiator detected error           0x48
  251.       Inappropriate/Illegal message      0x49
  252.  
  253.  
  254.     Table 3
  255.     -------
  256.  
  257.     This next section lists the messages that are printed by the SCSI driver.
  258.     After the message is printed, the driver resets the SCSI bus. 
  259.     These messages are from IRIX 4.0, but similar ones are printed by
  260.     earlier releases.
  261.     
  262.     "timeout after %d %ssec"
  263.         A SCSI command didn't complete with the reported number of
  264.         seconds (or milliseconds, if it wasn't an even number of seconds).
  265.         This happens only if the command was successfully sent to the
  266.         device; i.e., the device is at least partly alive.
  267.  
  268.     "Spurious SCSI interrupt, no connected channel"
  269.         This happens in cases that would have panic'ed 3.3.  We got
  270.         a SCSI interrupt that should only happen when a device is
  271.         logically connected on the bus (command or transfer in progress)
  272.         but the driver doesn't think any device is active.  Seems to
  273.         happen with some configurations after a SCSI bus reset has
  274.         occurred; possibly could be do to SCSI bus problems also.
  275.  
  276.     "illegal disconnection interrupt: phase %x"
  277.         A disconnect message has been received in a phase where it shouldn't
  278.         have occurred.  (A disconnect message is sent by a device when
  279.         relinquishing the bus temporarily, as when it is seeking.)
  280.         This could be caused (improbably) by some kind of SCSI bus problem.
  281.  
  282.     "reselect without ID"
  283.         Some device has reselected (after a disconnect), but the ID
  284.         of the reselector hasn't been recieved by the SCSI chip.  This
  285.         could be a cabling problem, or some kind of device failure.
  286.  
  287.     "unexpected message in %x, phase %x",
  288.     "Unexpected msg in %x, phase %x"
  289.         A device has either gone to a message in phase at a point where
  290.         neither the SCSI chip nor the driver is prepared for it, or a
  291.         message phase is on the bus when no devices are connected.  The
  292.         first number printed is the message byte.  This can also be caused
  293.         by cabling problems, and in some cases by devices failing a SCSI
  294.         sync negotiation in a why the driver isn't prepared to handle.
  295.  
  296.     "Unexpected info phase %x, state %x"
  297.         Same as above, but it was some SCSI bus phase other than message in.
  298.  
  299.     "Hardware error"
  300.         Almost always caused by a driver or chip problem, despite
  301.         the word hardware.  The SCSI chip has reported a failure to
  302.         select some SCSI device on the bus, but the driver didn't think
  303.         it was at the point where it should have been doing a select.
  304.  
  305.     "unexpected reselection"
  306.         Some device has reselected us, but either no device was
  307.         active (only sc# in message), or the device that selected
  308.         us wasn't in the disconnected state (sc#,#,# in msg).
  309.  
  310.     "disconnected on non-word boundary (addr=%x, 0x%x left)"
  311.         On all of the 4D series, DMA has to be aligned on a 32
  312.         bit boundary at the start of DMA.  If a device disconnects
  313.         from the bus in the middle of a transfer, and then reconnects
  314.         to transfer more data, but the disconnect wasn't after a multiple
  315.         of 4 bytes were transferred, then we can't transfer the rest of
  316.         the data correctly, so we abort the transfer.  This has been seen
  317.         to happen on the Exabyte 8500 when used under 3.3, and will happen
  318.         with some models of DAT drives (other than the one qualified by SGI).
  319.  
  320. Table 4
  321. -------
  322.  
  323. Several of the SCSI states and phases are listed below. There
  324. are other possible states and phases but they rarely occur.
  325. The SCSI states and phases are listed in the file, 
  326. /usr/include/sys/scsidev.h. The comments below have been extracted
  327. from this file and supplemented with additional information.
  328.  
  329.  
  330. Note: "out" is from the CPU to the SCSI device in these
  331.       descriptions and "receive" and "send" are also from the 
  332.       SCSI device point of view, since the target controls all
  333.       of the bus phases except for initial selection.
  334.  
  335. ST_RESET        0x00    SCSI chip Reset by reset command or power-up
  336. ST_SELECT       0x11    Selection of target complete (after C93SELATN)
  337. ST_SATOK        0x16    Select-And-Transfer completed successfully
  338.                         that is, all phases have completed in a
  339.                         normal manner
  340.  
  341. ST_TR_DATAOUT   0x18    transfer cmd done, target requesting data
  342. ST_TR_DATAIN    0x19    transfer cmd done, target sending data
  343. ST_TR_STATIN    0x1b    Target is sending status in
  344. ST_TR_MSGIN     0x1f    transfer cmd done, target sending msg
  345. ST_TRANPAUSE    0x20    transfer cmd has paused with ACK
  346.                         above 5 seen during sync negotiations
  347.  
  348. ST_SAVEDP       0x21    Save Data Pointers message during SAT
  349.                         normal state when device is disconnecting
  350.                         from the bus
  351. ST_A_RESELECT   0x27    reselected after disc (93A)
  352. ST_UNEXPDISC    0x41    An unexpected disconnect
  353.                         device disconnected without sending a
  354.                         disconnect message; sometimes happens when
  355.                         devices with removable media have had
  356.                         the media removed during a transfer.
  357. ST_PARITY       0x43    cmd terminated due to parity error on the SCSI bus
  358. ST_PARITY_ATN   0x44    cmd terminated due to parity error
  359.                         (ATN is asserted so that host can send a 
  360.                         message to device; we just abort the transfer)
  361. ST_TIMEOUT      0x42    Time-out during Select or Reselect
  362.                         that is, the device never responded to an 
  363.                         attempt to select it; normally seen only 
  364.                         during hardware inventory probing, but sometimes
  365.                         happens after a SCSI bus reset, if device takes 
  366.                         a long time to  recover from the reset, or is
  367.                         powered off
  368. ST_INCORR_DATA  0x47    incorrect message or status byte
  369. ST_UNEX_RDATA   0x48    Unexpected receive data phase
  370.                         device tried to send us more data than we
  371.                         programmed the SCSI chip to expect.  This
  372.                         can be OK, as when a high level  request is
  373.                         made to transfer more data than the DMA
  374.                         hardware can map on a single request.  In
  375.                         this case, we simply reprogram  the DMA
  376.                         hardware for the next chunk of data, and
  377.                         restart the transfer (but we don't send a
  378.                         new SCSI command to the device).   When
  379.                         printed as part of an error message, it can
  380.                         sometimes be  caused by a SCSI cabling
  381.                         problem, or (particularly with devscsi
  382.                         user drivers) by a mismatch in the byte
  383.                         count given to the driver  and the byte
  384.                         count implied by the SCSI command sent to
  385.                         the device.
  386.  
  387. ST_UNEX_SDATA   0x49    Unexpected send data phase
  388.                         Same as above, but device is asking us
  389.                         to send more data.
  390. ST_UNEX_CMDPH   0x4a    Unexpected cmd phase
  391. ST_UNEX_SSTATUS 0x4b    Unexpected send status phase
  392.                         status phases occur at the end of 
  393.                         SCSI command (i.e. byte count remaining
  394.                         is 0); if they happen at other times, the
  395.                         chip interrupts.  This can frequently  
  396.                         happen when we ask a device for more data 
  397.                         than it can give us, and in this case
  398.                         we just return a short i/o count to the 
  399.                         caller.  When printed as part of an 
  400.                         error message, it usually implies a
  401.                         cabling or termination problem.
  402. ST_UNEX_RMESGOUT 0x4e   Unexpected request msg out phase
  403.                         usually indicates a SCSI cabling problem.
  404. ST_UNEX_SMESGIN 0x4f    Unexpected send message in phase
  405.                         in a message, usually indicates a SCSI 
  406.                         cabling problem;  also happens when device
  407.                         sends a disconnect message in normal use
  408.                         when preparing to disconnect from the bus
  409. ST_RESELECT     0x80    WD33C93 has been reselected
  410. ST_93A_RESEL    0x81    reselected while idle (93A)
  411. ST_DISCONNECT   0x85    Disconnect has occurred
  412. ST_NEEDCMD      0x8a    Target is ready for a cmd
  413. ST_REQ_SMESGOUT 0x8e    REQ signal for send message out
  414. ST_REQ_SMESGIN  0x8f    REQ signal for send message in
  415.                         above 3 usually seen only during sync 
  416.                         negotiations.
  417.  
  418. Phases during a Select and Transfer command
  419.  
  420. PH_NOSELECT     0x00    Selection not successful
  421. PH_SELECT       0x10    Selection successful
  422. PH_IDENTSEND    0x20    Identify message sent (during selection
  423.                         when sending initial command to a device) 
  424.                         phase 30 indicates none of the cmd bytes 
  425.                         have yet been sent; every cmd byte sent 
  426.                         increments that by one.
  427. PH_CDB_START    0x30    Start of CDC transfers
  428. PH_CDB_6        0x36    6th cmd byte sent
  429. PH_CDB_10       0x3a    0xAth cmd byte sent
  430. PH_CDB_12       0x3c    0xCth cmd byte sent
  431. PH_SAVEDP       0x41    Save data pointers
  432. PH_DISCRECV     0x42    Disconnect message received
  433. PH_DISCONNECT   0x43    Target disconnected
  434. PH_RESELECT     0x44    Original target reselected
  435. PH_IDENTRECV    0x45    Correct identify (right LUN) message rcv'd 
  436.                         (during reselection)
  437. PH_DATA         0x46    Data transfer completed (expect status next)
  438. PH_STATUSRECV   0x50    Status byte received (expect cmd complete next)
  439. PH_COMPLETE     0x60    Command complete message received; 
  440.                         SCSI command is finished, and SCSI bus 
  441.                         is free.
  442.  
  443. =================================================================
  444. --
  445. Let no one tell me that silence gives consent,  |   Dave Olson
  446. because whoever is silent dissents.             |   Silicon Graphics, Inc.
  447.     Maria Isabel Barreno                        |   olson@sgi.com
  448.