From owner-freebsd-stable@FreeBSD.ORG Tue Jan 11 16:12:37 2011 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BF1EF1065673 for ; Tue, 11 Jan 2011 16:12:37 +0000 (UTC) (envelope-from hirez@libeljournal.com) Received: from outbound-queue-1.mail.thdo.gradwell.net (outbound-queue-1.mail.thdo.gradwell.net [212.11.70.34]) by mx1.freebsd.org (Postfix) with ESMTP id 782DB8FC14 for ; Tue, 11 Jan 2011 16:12:37 +0000 (UTC) Received: from outbound-edge-2.mail.thdo.gradwell.net (bonnie.gradwell.net [212.11.70.2]) by outbound-queue-1.mail.thdo.gradwell.net (Postfix) with ESMTP id E830E21F24; Tue, 11 Jan 2011 16:12:35 +0000 (GMT) Received: from cpc2-chap5-0-0-cust256.aztw.cable.virginmedia.com (HELO propellor.libeljournal.com) (77.103.165.1) (smtp-auth username hirez, mechanism cram-md5) by outbound-edge-2.mail.thdo.gradwell.net (qpsmtpd/0.83) with (AES256-SHA encrypted) ESMTPSA; Tue, 11 Jan 2011 16:12:35 +0000 Received: from propellor.libeljournal.com (localhost [127.0.0.1]) by propellor.libeljournal.com (Postfix) with ESMTP id E7FF2170BB; Tue, 11 Jan 2011 16:10:47 +0000 (GMT) X-Virus-Scanned: amavisd-new at libeljournal.com Received: from propellor.libeljournal.com ([127.0.0.1]) by propellor.libeljournal.com (propellor.libeljournal.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id MpZMBaVt44j4; Tue, 11 Jan 2011 16:10:43 +0000 (GMT) Received: from [172.16.0.10] (twister.libeljournal.com [172.16.0.10]) by propellor.libeljournal.com (Postfix) with ESMTPA id BE92517076; Tue, 11 Jan 2011 16:10:43 +0000 (GMT) Message-ID: <4D2C810E.2070007@libeljournal.com> Date: Tue, 11 Jan 2011 16:10:54 +0000 From: John Hawkes-Reed User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-GB; rv:1.9.2.13) Gecko/20101207 Thunderbird/3.1.7 MIME-Version: 1.0 To: Dan Langille References: <4D228F41.7040403@langille.org> <4D23504D.8060103@libeljournal.com> <4D2BD0A7.9060003@langille.org> In-Reply-To: <4D2BD0A7.9060003@langille.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Gradwell-MongoId: 4d2c8173.11ef5-532c-2 X-Gradwell-Auth-Method: smtpauth X-Gradwell-Auth-Credentials: hirez Cc: freebsd-stable Subject: Re: ZFS - hot spares : automatic or not? X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 11 Jan 2011 16:12:37 -0000 On 11/01/2011 03:38, Dan Langille wrote: > On 1/4/2011 11:52 AM, John Hawkes-Reed wrote: >> On 04/01/2011 03:08, Dan Langille wrote: >>> Hello folks, >>> >>> I'm trying to discover if ZFS under FreeBSD will automatically pull in a >>> hot spare if one is required. >>> >>> This raised the issue back in March 2010, and refers to a PR opened in >>> May 2009 >>> >>> * http://lists.freebsd.org/pipermail/freebsd-fs/2010-March/007943.html >>> * http://www.freebsd.org/cgi/query-pr.cgi?pr=134491 >>> >>> In turn, the PR refers to this March 2010 post referring to using devd >>> to accomplish this task. >>> >>> http://lists.freebsd.org/pipermail/freebsd-stable/2010-March/055686.html >>> >>> Does the above represent the the current state? >>> >>> I ask because I just ordered two more HDD to use as spares. Whether they >>> sit on the shelf or in the box is open to discussion. >> >> As far as our testing could discover, it's not automatic. >> >> I wrote some Ugly Perl that's called by devd when it spots a drive-fail >> event, which seemed to DTRT when simulating a failure by pulling a drive. > > Without such a script, what is the value in creating hot spares? We went through that loop in the office. We're used to the way the Netapps work here, where often one's first notice of a failed disk is a visit from the courier with a replacement. (I'm only half joking) In the end, writing enough perl to swap in the spare disk made much more sense than paging the relevant admin on disk-fail and expecting them to be able to type straight at 4AM. Our thinking is that having a hot spare allows us to do the physical disk-swap in office hours, rather than (for instance) running in a degraded state over a long weekend. If it's of interest, I'll see if I can share the code. -- JH-R