Ticket #18 (closed defect: fixed)
3ware-status returns error in line 89
| Reported by: | anonymous | Owned by: | gandalf |
|---|---|---|---|
| Priority: | major | Milestone: | 1.0.0 |
| Component: | packages | Version: | |
| Keywords: | Cc: |
Description
It happens if number of installed disks is smaller then number of ports on the controller, ie if you have 8 disks in 16 port controller.
Here is the output:
-- Arrays informations --
-- ID Type Size Status
c0u0 RAID6 2793G OK
-- Disks informations
-- ID Model Status
c0u0p0 5QG1RZTM OK
c0u0p1 5QG1RZYQ OK
c0u0p2 5QG1S1AD OK
c0u0p3 5QG1RZTJ SMART-FAILURE
c0u0p4 5QG1RZW4 OK
c0u0p5 9QG6LRXY OK
c0u0p6 9QG8RSRF OK
c0u0p7 5QG1RZSR OK
Traceback (most recent call last):
File "/usr/sbin/3ware-status", line 89, in <module>
model = disk[6]
IndexError?: list index out of range
# tw-cli info c0
Unit UnitType? Status %RCmpl %V/I/M Stripe Size(GB) Cache AVrfy
u0 RAID-6 OK - - 64K 2793.91 ON OFF
Port Status Unit Size Blocks Serial
p0 OK u0 465.76 GB 976773168 5QG1RZTM
p1 OK u0 465.76 GB 976773168 5QG1RZYQ
p2 OK u0 465.76 GB 976773168 5QG1S1AD
p3 SMART-FAILURE u0 465.76 GB 976773168 5QG1RZTJ
p4 OK u0 465.76 GB 976773168 5QG1RZW4
p5 OK u0 465.76 GB 976773168 9QG6LRXY
p6 OK u0 465.76 GB 976773168 9QG8RSRF
p7 OK u0 465.76 GB 976773168 5QG1RZSR
p8 NOT-PRESENT - - - -
p9 NOT-PRESENT - - - -
p10 NOT-PRESENT - - - -
p11 NOT-PRESENT - - - -
p12 NOT-PRESENT - - - -
p13 NOT-PRESENT - - - -
p14 NOT-PRESENT - - - -
p15 NOT-PRESENT - - - -


Exactly the same with 2 8-port cards, as follows:
--- clip clip ---
-- Arrays informations --
-- ID Type Size Status
c0u0 SINGLE 465G OK
c0u1 SINGLE 465G OK
c0u2 SINGLE 465G OK
c0u3 SINGLE 465G OK
c0u4 SINGLE 465G OK
c1u0 SINGLE 465G OK
c1u1 SINGLE 465G OK
c1u2 SINGLE 465G OK
c1u3 SINGLE 465G OK
-- Disks informations
-- ID Model Status
c0u1p0 9QG0EGQ3 OK
c0u2p1 9QG0EXZW OK
c0u3p2 9QG0EGRN OK
c0u4p3 9QMAX91V OK
Traceback (most recent call last):
IndexError?: list index out of range
--- clip clip ---
Please fix the tool. It looks interesting....