From owner-freebsd-stable@FreeBSD.ORG Mon Jul 19 15:21:45 2010 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 E66EC106564A for ; Mon, 19 Jul 2010 15:21:45 +0000 (UTC) (envelope-from garrettmoore@gmail.com) Received: from mail-pv0-f182.google.com (mail-pv0-f182.google.com [74.125.83.182]) by mx1.freebsd.org (Postfix) with ESMTP id BCE138FC15 for ; Mon, 19 Jul 2010 15:21:44 +0000 (UTC) Received: by pvh1 with SMTP id 1so1966676pvh.13 for ; Mon, 19 Jul 2010 08:21:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:date:message-id :subject:from:to:content-type; bh=Worn6ZrlQfal11mDCuOPuBCMTSk75UvHxM5PgEn/7fQ=; b=iFBAs/mW16CibgMKHg6976c34xjxbI789XY+L/CpSPVysZODZj90G3en8Zgew8Qg2/ mBp8l3B195cq7K6WKCgnO4KmTIuFnbx59kJplkY86BovQTb4b5W3RBh+oj43MarqCDdc kHvSzjyYIo98NHmDFkPEs4Q7Lhn5kkaE/nyEk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=LKwmTT63EnC5aWrfN29fmHsijNmJHCLB7FWCZw9C2lZUoNCsrOrgyA2SYUOaeiCq0n JMn5+Hdwq8RP3DmAoDKR3YfMwPpmrRTj+wZdY5mLCuDUl/Bsy+XuwwN8wq0Xl2ADVKgG cq4WUFBMxfkpKwCjR+TYjugy8lylYzlNv6P5A= MIME-Version: 1.0 Received: by 10.142.142.15 with SMTP id p15mr6961545wfd.199.1279552898448; Mon, 19 Jul 2010 08:21:38 -0700 (PDT) Received: by 10.231.117.72 with HTTP; Mon, 19 Jul 2010 08:21:38 -0700 (PDT) Date: Mon, 19 Jul 2010 11:21:38 -0400 Message-ID: From: Garrett Moore To: freebsd-stable Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Subject: Problems replacing failing drive in ZFS pool 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: Mon, 19 Jul 2010 15:21:46 -0000 I have an 8-drive ZFS array consisting of WD15EADS drives. One of my disks has started to fail, so I got a replacement disk. I have replaced a disk before by: zpool offline tank /dev/da5 shutting down, swapping from old disk to new disk booting zpool replace tank /dev/da5 This worked fine. This time the failing disk was da3, and I tried the same thing: zpool offline tank /dev/da3 zpool status showed da3 offline. shut down, swapped old disk to new disk. When I booted again, I got: Code: NAME STATE READ WRITE CKSUM tank UNAVAIL 0 0 0 insufficient replicas raidz1 UNAVAIL 0 0 0 corrupted data da0 ONLINE 0 0 0 da1 ONLINE 0 0 0 da2 ONLINE 0 0 0 da3 ONLINE 0 0 0 da4 ONLINE 0 0 0 da5 ONLINE 0 0 0 da6 ONLINE 0 0 0 da7 ONLINE 0 0 0 I switched back to the old disk and booted again and then I could access my data again, and da3 still showed as offline. I tried 'zpool online tank /dev/da3' and after a few seconds resilvering completed and all 8 drives are back online again, but with the 'dying' disk as da3 still. I tried shutting down WITHOUT first offlining /dev/da3, and swapping the disks, and when I booted I again got 'insufficient replicas'. Why am I getting this error, and how come it worked ok the last time I replaced a disk? And more importantly, how do I switch to my new replacement disk without losing data? Thanks.