I have a 3ware RAID controller running a RAID-6. I manage the RAID via the tw_cli command line utility.

So, one drive in the array failed, and I removed the faulty drive (p6) from the array, and then inserted a new drive.

For some reason, the 3ware controller placed the drive in an older, inoperable array (u1). So I deleted that array. I now want to add the new drive to the RAID-6, which is u0.

So I have:

# tw_cli /c0/u0 show

Unit     UnitType  Status         %RCmpl  %V/I/M  VPort Stripe  Size(GB)
u0       RAID-6    DEGRADED       -       -       -     256K    2793.91   
u0-0     DISK      OK             -       -       p0    -       465.651   
u0-1     DISK      OK             -       -       p1    -       465.651   
u0-2     DISK      OK             -       -       p2    -       465.651   
u0-3     DISK      OK             -       -       p3    -       465.651   
u0-4     DISK      OK             -       -       p4    -       465.651   
u0-5     DISK      OK             -       -       p5    -       465.651   
u0-6     DISK      DEGRADED       -       -       -     -       465.651   
u0-7     DISK      OK             -       -       p7    -       465.651   
u0/v0    Volume    -              -       -       -     -       10        
u0/v1    Volume    -              -       -       -     -       2783.91   

As you can see, drive p6 is not part of u0. However, it is detected by the controller:

# tw_cli /c0 show

Unit  UnitType  Status         %RCmpl  %V/I/M  Stripe  Size(GB)  Cache  AVrfy
u0    RAID-6    DEGRADED       -       -       256K    2793.91   RiW    OFF    

VPort Status         Unit Size      Type  Phy Encl-Slot    Model
p0    OK             u0   465.76 GB SATA  0   -            ST3500630AS         
p1    OK             u0   465.76 GB SATA  1   -            ST3500630AS         
p2    OK             u0   465.76 GB SATA  2   -            ST3500630AS         
p3    OK             u0   465.76 GB SATA  3   -            ST3500320AS         
p4    OK             u0   465.76 GB SATA  4   -            ST3500630AS         
p5    OK             u0   465.76 GB SATA  5   -            ST3500630AS         
p6    OK             -    465.76 GB SATA  6   -            ST3500320AS         
p7    OK             u0   465.76 GB SATA  7   -            ST3500630AS         

Name  OnlineState  BBUReady  Status    Volt     Temp     Hours  LastCapTest
bbu   On           Yes       OK        OK       OK       0      xx-xxx-xxxx  

So here we see that p6 is detected by the controller, but it is not part of the unit u0. So I just need to add it somehow. Unfortunately, I cannot find the syntax to do this.

Looking through the tw_cli docs, there doesn't seem to be a unit-level command to add a drive to a unit. So, how do you add a drive to a unit? How can I make p6 part of u0?


Hmm, I agree, it's vague. I've always worked with spares, so drives are added automatically. Perhaps you can hack that too:

tw_cli /c0 add raidtype=spare disk=6

Then perhaps it will pick it up automatically.


I was able to accomplish this on my system with the following command:

tw_cli /c0/u0 start rebuild disk=6

This happened to me, and as I was reading the tw_cli help screens to find the incantation, it actually changed the status on its own to add the changed p* disk to the u* unit, and start rebuilding the array. It's possible that the controller just has some small amount of back-off time in case you're taking time to seat the drive, and then it kicks into the logical course of action.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.