DaemonForums  

Go Back   DaemonForums > FreeBSD > FreeBSD General

FreeBSD General Other questions regarding FreeBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 12th November 2008
PeterSteele PeterSteele is offline
Port Guard
 
Join Date: Jul 2008
Posts: 43
Default Yet another question about hot swapping drives

I've done some searched regarding FreeBSD's 7 support for the hot swapping of SATA drives and the general consensus is that it *is* supported, but not necessarily with all drive models/brands. In our own testing, we've discovered that our Seagate 250GB drives cannot be hot swapped in our servers. The systems hang and eventually panic, even if the drive is simply removed and then put back in.

We also have some Western Digital drives, and these fare much better. FreeBSD appears to recognize when these drives are removed and inserted; the geom driver for example automatically re-inserts a previously configured drive as soon as it is plugged in. It isn't even necessary to do an atacontrol attach/detach.

However, even with the Western Digital drive, there are issues. In particular, if there are any mounted file systems on a drive when it is removed, attempting to unmount the file systems after it has been removed usually leads to a kernel panic, not necessarily immediately but shortly afterwards.

Why does FreeBSD panic instead of simply issuing an I/O error. The implication is that if a drive was to suddenly die on a live system, even if we have gmirror configured for HA, the system will panic. We have software that detects when a drive disappears, but if the system is going to end up panicking, our detection code isn't going to do us much good.

Is there any solution to this? Can a server be built around FreeBSD that supports hot swappable SATA drives?
Reply With Quote
  #2   (View Single Post)  
Old 13th November 2008
PeterSteele PeterSteele is offline
Port Guard
 
Join Date: Jul 2008
Posts: 43
Default

Let me clarify this a bit. We have a system with four identical drives configured with three slices--one for the OS, one for swap, and one for our application. We use gmirror to mirror the OS across all four drives. The third slice on each disk is not mirrored but is rather configured as a single file system and mounted for use by our our application.

When we take a drive out (assuming we're using the WD drives), the geom driver automatically detects the missing drive and takes it out of the mirror. If we put the drive back in, it is automatically re-inserted.

The problem is with the application slice. When a drive is removed and not properly unmounted first, attempting to force an unmount after the fact fails, and the system ends throwing a kernel panic.

We want to make an HA system that can handle the sudden loss of a drive, but so far we've been unable to get this to work with FreeBSD. Is there a solution?
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
external drive partition question + fdisk question gosha OpenBSD General 15 15th June 2009 02:00 PM
can't access ZFS drives Bubba_HoTep FreeBSD General 6 6th November 2008 02:06 PM
Adding drives annoys OpenBSD. diw OpenBSD General 4 4th September 2008 02:14 AM
Moving ZFS partitions/drives between systems corey_james Guides 2 6th August 2008 08:36 PM
Automounting drives jwhal OpenBSD General 4 12th June 2008 05:00 PM


All times are GMT. The time now is 07:46 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick