From owner-freebsd-fs@FreeBSD.ORG Wed Oct 10 01:43:44 2012 Return-Path: Delivered-To: freebsd-fs@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id A4079419 for ; Wed, 10 Oct 2012 01:43:44 +0000 (UTC) (envelope-from spf72sa9@rhythm.ocn.ne.jp) Received: from smtp.rhythm.ocn.ne.jp (rhythm.ocn.ne.jp [122.28.30.178]) by mx1.freebsd.org (Postfix) with ESMTP id 158F38FC0C for ; Wed, 10 Oct 2012 01:43:43 +0000 (UTC) Received: from rhythm.ocn.ne.jp (p5061-ipngn100509fukuokachu.fukuoka.ocn.ne.jp [153.130.238.61]) by smtp.rhythm.ocn.ne.jp (Postfix) with SMTP id 7861B2838 for ; Wed, 10 Oct 2012 10:16:41 +0900 (JST) From: Wanpeng Qian To: freebsd-fs@freebsd.org Subject: Why zfs need to scan whole fs while I attach a HDD to mirror. Date: Wed, 10 Oct 2012 10:16:28 +0900 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Mailer: HidemaruMail 5.70 (WinNT,601) Message-Id: <29CDA684DFBE02spf72sa9@rhythm.ocn.ne.jp> X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 10 Oct 2012 01:43:44 -0000 Hi guys my zpool is config as follow: NAME STATE READ WRITE CKSUM storage ONLINE 0 0 0 mirror-0 ONLINE 0 0 0 da2 ONLINE 0 0 0 ada2 ONLINE 0 0 0 mirror-1 ONLINE 0 0 0 da1 ONLINE 0 0 0 da4 ONLINE 0 0 0 mirror-2 ONLINE 0 0 0 da3 ONLINE 0 0 0 ada3 ONLINE 0 0 0 mirror-3 ONLINE 0 0 0 ada0 ONLINE 0 0 0 ada1 ONLINE 0 0 0 cache da5 ONLINE 0 0 0 recently, I replace mirror-3, from two 2T to two 3T. first I detach one hdd, and attach new hdd to that mirror. after attach, zfs starting resilvering as expect. but zfs will scan whole fs to resiver new hdd. I think that is not necessery. only copy one disk data to new one is enough. scan the whole fs will spend a lot of time as follow: scan: resilver in progress since Wed Oct 10 07:12:52 2012 1.20T scanned out of 6.48T at 121M/s, 12h39m to go 308G resilvered, 18.60% done does this function correctly? Regards Qian.