Hot swapping drives: requirements

Notice: Page may contain affiliate links for which we may earn a small commission through services like Amazon Affiliates or Skimlinks.

SantaSCSI

New Member
May 22, 2011
20
3
3
I'm currently thinking of adding disks to my NAS at home and I was wondering where the requirements lie for a succesful hot insert/removal of a drive. Is it the drive type, OS, Backplane, ... ?

My current setup:
- Supermicro 846 with EL1 backplane
- IBM M1015 IT mode
- Debian stable
- SATA3 disks

I usually power down my NAS, but that was when I was still using a Norco hot swap chassis and those are known to blow drives due to the flaky backplane. Shutting down my Vsphere environment is also a cumbersome task so if hot adding drives is safe, I'd rather do that.
 
  • Like
Reactions: T_Minus

T_Minus

Build. Break. Fix. Repeat
Feb 15, 2015
7,625
2,043
113
Great thread.

I'm curious if someone could explain "all" of what's needed for a successful "hot swap" too.

I've been testing drives hot-swapping them in my desktop, and it just randomly STOPPED detecting drives unless I reboot, which obv. doesn't make it efficient at all. Nothing I've done can get "hot swap" to work again. (2011-v3 desktop w/consumer board). At first it would max out at SATA II until I Rebooted, then it worked then stopped 100%, it's very strange because I think it's technically still "fine" to do hot swap it just doesn't work anymore.
 

EffrafaxOfWug

Radioactive Member
Feb 12, 2015
1,394
511
113
Indeed a good topic for a thread B^)

A few pointers;
Hot-plug is, IIRC, part of the AHCI standard, but lots of BIOSes won't enable it by default. In many you'll be able to go into the BIOS, pick a SATA port and say "enable hotplug" or words to that effect... in other BIOSes (one that immediately springs to mind was the HP microserver) was hotplug functionality being masked entirely.
Windows support for SATA hotplug been mostly-good-but-spotty sometimes. Ran into the same issue as T Minus where an eSATA drive (from the intel chipset) just stopped working for hotplug until I rebooted (also a 2011-3, ASRock X99-WS).
Linux I've never had any problems with hotplug whatsoever. Heck I was using linux when ATA hotplug was still a thing...
All the LSI controllers I've ever used (only SAS2008-based) have supported hotplug without any tweaks whatsoever in linux. Slam in a new drive, look at dmesg for the new drive letter, rinse'n'repeat.

The file server before my current one (running of a combination of intel chipset and marvell PCIe card SATA ports) went through three drive iterations and MD expansions (1TB > 2TB > 3TB) without a reboot. Current server only has an uptime of ~200 days since I got a new UPS but it's already gone through one set of hot-swap drive upgrades. My current setup is the same as above minus the SM backplane. Debian jessie, M1015's flashed to 9211-8i IT, SATA3 discs.
 

uOpt

Member
Dec 12, 2014
43
7
8
Boston, MA, USA
Under Linux and FreeBSD I hotswap all SATA. Never had a problem. Do it all the time. Cages, no cages, no matter. I ground myself, FWIW.

I believe all my controllers are AHCI in AHCI mode, or at least should be.
 

SantaSCSI

New Member
May 22, 2011
20
3
3
Just tested this with a new disk I planned to add: Hitachi ultrastar 7k3000.

The following is seen in dmesg:
Code:
[9411930.963315] scsi 0:0:12:0: Direct-Access  ATA  HUA723020ALA640  A870 PQ: 0 ANSI: 5
[9411930.963328] scsi 0:0:12:0: SATA: handle(0x0015), sas_addr(0x5003048000f29dd9), phy(25), device_name(0x0000000000000000)
[9411930.963331] scsi 0:0:12:0: SATA: enclosure_logical_id(0x500304800000007f), slot(13)
[9411930.963418] scsi 0:0:12:0: atapi(n), ncq(y), asyn_notify(n), smart(y), fua(y), sw_preserve(y)
[9411930.963422] scsi 0:0:12:0: qdepth(32), tagged(1), simple(0), ordered(0), scsi_level(6), cmd_que(1)
[9411930.963788] sd 0:0:12:0: Attached scsi generic sg13 type 0
[9411930.964909] sd 0:0:12:0: [sdc] 3907029168 512-byte logical blocks: (2.00 TB/1.81 TiB)
[9411931.152241] sd 0:0:12:0: [sdc] Write Protect is off
[9411931.152246] sd 0:0:12:0: [sdc] Mode Sense: 7f 00 00 08
[9411931.156128] sd 0:0:12:0: [sdc] Write cache: enabled, read cache: enabled, doesn't support DPO or FUA
[9411931.344724]  sdc: unknown partition table
[9411931.549678] sd 0:0:12:0: [sdc] Attached SCSI disk
Looks like it is indeed no problem at all with my setup.

Looking at the replies, the OS seems to be a big factor though. Additionally, a good backplane is probably key on the mechanical side of things.