From owner-freebsd-fs@FreeBSD.ORG Tue Aug 9 13:11:07 2011 Return-Path: Delivered-To: freebsd-fs@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5A98E1065670 for ; Tue, 9 Aug 2011 13:11:07 +0000 (UTC) (envelope-from jeremie@le-hen.org) Received: from smtp5-g21.free.fr (unknown [IPv6:2a01:e0c:1:1599::14]) by mx1.freebsd.org (Postfix) with ESMTP id B18A18FC0C for ; Tue, 9 Aug 2011 13:11:05 +0000 (UTC) Received: from endor.tataz.chchile.org (unknown [82.233.239.98]) by smtp5-g21.free.fr (Postfix) with ESMTP id 294F6D480B7; Tue, 9 Aug 2011 15:10:58 +0200 (CEST) Received: from felucia.tataz.chchile.org (felucia.tataz.chchile.org [192.168.1.9]) by endor.tataz.chchile.org (Postfix) with ESMTP id 13DF63723C; Tue, 9 Aug 2011 13:10:58 +0000 (UTC) Received: by felucia.tataz.chchile.org (Postfix, from userid 1000) id 0ABA8A128A; Tue, 9 Aug 2011 13:10:58 +0000 (UTC) Date: Tue, 9 Aug 2011 15:10:57 +0200 From: Jeremie Le Hen To: freebsd-fs@FreeBSD.org Message-ID: <20110809131057.GA53580@felucia.tataz.chchile.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.5.21 (2010-09-15) Cc: jeremie@le-hen.org Subject: zfs mirror reads only on one disk X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Aug 2011 13:11:07 -0000 Hi, Please Cc: me when replying, as I've not subscribed. Thanks. I'm using FreeBSD 8.2-STABLE, with a mirrored ZFS pool v15: NAME STATE READ WRITE CKSUM data ONLINE 0 0 0 mirror ONLINE 0 0 0 ad10s1 ONLINE 0 0 0 ad6s1 ONLINE 0 0 0 ad6: 1907729MB at ata3-master UDMA100 SATA 3Gb/s ad10: 1907729MB at ata5-master UDMA100 SATA 3Gb/s (For those who wonder why I use a sliced disk, this is because the disks are not the same and this allows me to get the same size on each side. Besides, ZFS v15 doesn't have the autoexpand property, this is a workaround.) The mirror is correctly synchronized and when I write on it, I get the following iostat(8) output (3 seconds interval): extended device statistics device r/s w/s kr/s kw/s wait svc_t %b ad6 0.0 682.8 0.0 41593.3 16 18.7 77 ad10 0.3 686.8 21.3 41465.4 19 19.4 80 extended device statistics device r/s w/s kr/s kw/s wait svc_t %b ad6 0.0 680.9 0.0 41910.7 16 17.3 78 ad10 0.0 671.2 0.0 41228.1 16 19.6 80 However, when I read on the mirror, only ad10 is being used: extended device statistics device r/s w/s kr/s kw/s wait svc_t %b ad6 0.0 0.0 0.0 0.0 0 0.0 0 ad10 762.7 0.0 48796.7 0.0 2 1.8 82 extended device statistics device r/s w/s kr/s kw/s wait svc_t %b ad6 0.0 0.0 0.0 0.0 0 0.0 0 ad10 740.2 0.0 47373.1 0.0 1 1.9 81 extended device statistics device r/s w/s kr/s kw/s wait svc_t %b ad6 0.0 0.3 0.0 1.3 0 0.2 0 ad10 716.2 0.3 45836.0 1.3 2 1.9 82 One of my colleagues told me this was maybe an optimization of ZFS for sequentials reads, so I tried to run two reading processes in parallel, with the same unfortunate outcome. I also tried to run "cat *" in a highly populated Maildir, so I'm sure the reads are not sequential, same outcome. Do you have any idea why this happens? Thanks, -- Jeremie Le Hen Humans are born free and equal. But some are more equal than others. Coluche