Date: Mon, 20 Oct 2008 10:25:15 -0700 From: Jeremy Chadwick <koitsu@FreeBSD.org> To: Steve Franks <stevefranks@ieee.org> Cc: freebsd-hardware@freebsd.org Subject: Re: sata hotswap on Intel ICH7 Message-ID: <20081020172515.GA8705@icarus.home.lan> In-Reply-To: <539c60b90810201018v455513a0tdc97d7465e6623c3@mail.gmail.com> References: <539c60b90810201018v455513a0tdc97d7465e6623c3@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Mon, Oct 20, 2008 at 10:18:50AM -0700, Steve Franks wrote: > Just curious if this works, what I need to do, etc, good/bad > experiences... Since I'm actually talking about internal drives, does > cabling matter, is the power supposed to mate before/after data, etc? Hot-swapping on SATA requires an actual hot-swap-capable SATA backplane. You *cannot* just "yank a disk out of a PC" by removing the SATA data or power cable. It also requires that you be using SATA in "Enhanced" mode, or under AHCI. Using SATA in "Emulation" or "Compatible" mode (e.g. a 2-channel SATA controller will assign disks as ata0-master and ata0-slave) will not work how you expect. AHCI is preferred, if available. Assuming you meet these criteria, all you need to do on FreeBSD is: - Unmount any filesystems using the disk (you may need to shut down or kill off processes using files on those filesystems before you can unmount). If you forget to do this, you will panic the box. - atacontrol list, and determine what channel to detach (E.g. ata0) - atacontrol detach <channel> - Kernel should show the disk disappearing. - Remove disk from machine, replace with new disk. - Wait for disk to spin up (sometimes the drive LEDs will be lit; wait for them to turn off) - atacontrol attach <channel> And that's all. Note that there are known problems with this when using BIOS-level RAID methods such as Intel MatrixRAID, so please do not use those. > Doesn't seem to be much on the subject in the handbook or man > atacontrol. You can file a PR to get this added, if you'd like. :-) > I assume we've had scsi hotswapping for quite some time, right? Correct, but it requires similar hardware as above. SCA drives, for example, are hot-swappable, while yanking a drive off a LVD cable will probably not do what you expect. camcontrol(8) is the utility you want to use for all that. -- | Jeremy Chadwick jdc at parodius.com | | Parodius Networking http://www.parodius.com/ | | UNIX Systems Administrator Mountain View, CA, USA | | Making life hard for others since 1977. PGP: 4BD6C0CB |
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20081020172515.GA8705>