Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 1 Mar 2010 21:45:19 -0600
From:      Dan Nelson <dnelson@allantgroup.com>
To:        Aryeh Friedman <aryeh.friedman@gmail.com>
Cc:        freebsd-hackers@freebsd.org, Garrett McNeill <garrett@garrettmcneill.com>
Subject:   Re: unable to offline a failing drive in a zfs RAIDZ
Message-ID:  <20100302034519.GW70798@dan.emsphone.com>
In-Reply-To: <bef9a7921003011615g15198714kc5408cd46eda5a91@mail.gmail.com>
References:  <bef9a7921003011615g15198714kc5408cd46eda5a91@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
In the last episode (Mar 01), Aryeh Friedman said:
> I have a raidz setup as per the handbook but when I attempt to "offline" a
> failing drive it will not let me:
> 
> kate# zpool status -c
> invalid option 'c'
> usage:
>         status [-vx] [pool] ...
> kate# zpool status -v
>   pool: storage
>  state: ONLINE
>  scrub: resilver completed with 0 errors on Mon Mar  1 17:36:48 2010
> config:
> 
>         NAME        STATE     READ WRITE CKSUM
>         storage     ONLINE       0     0     0
>           raidz1    ONLINE       0     0     0
>             ad7     ONLINE       0     0     0
>             ad8     ONLINE       0     0     0
>             ad9     ONLINE       0     0     0
>             ad10    ONLINE       0     0     0
>             ad12    ONLINE       0     0     0
> 
> errors: No known data errors
> kate# zpool offline storage ad12
> cannot offline ad12: no valid replicas

What version of FreeBSD are you running?  This looks like a known bug.  It
originally worked for mirrors but not RAIDZ vdevs - "zpool offline is a bit
too conservative":
http://bugs.opensolaris.org/bugdatabase/view_bug.do?bug_id=2171359 , and
works for me on a 7-stable kernel:

(root@studio) /root># uname -a
FreeBSD studio.evoy.net 7.3-PRERELEASE FreeBSD 7.3-PRERELEASE #53: Tue Feb 2 17:19:46 CST 2010 zsh@studio.evoy.net:/usr/src-7/sys/amd64/compile/STUDIO  amd64
(root@studio) /root># mdconfig -a -t swap -s 1g ;  mdconfig -a -t swap -s 1g ; mdconfig -a -t swap -s 1g
md1
md2
md3
(root@studio) /root># zpool create dummy raidz md1 md2 md3
(root@studio) /root># zpool offline dummy md2
(root@studio) /root># zpool status dummy    
  pool: dummy
 state: DEGRADED
status: One or more devices has been taken offline by the administrator.
        Sufficient replicas exist for the pool to continue functioning in a
        degraded state.
action: Online the device using 'zpool online' or replace the device with
        'zpool replace'.
 scrub: none requested
config:

        NAME        STATE     READ WRITE CKSUM
        dummy       DEGRADED     0     0     0
          raidz1    DEGRADED     0     0     0
            md1     ONLINE       0     0     0
            md2     OFFLINE      0     0     0
            md3     ONLINE       0     0     0


-- 
	Dan Nelson
	dnelson@allantgroup.com



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20100302034519.GW70798>