From owner-freebsd-stable@FreeBSD.ORG Sun Jul 27 19:20:01 2014 Return-Path: Delivered-To: freebsd-stable@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 8890C1C4 for ; Sun, 27 Jul 2014 19:20:01 +0000 (UTC) Received: from woozle.rinet.ru (woozle.rinet.ru [195.54.192.68]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0507B29E3 for ; Sun, 27 Jul 2014 19:20:00 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by woozle.rinet.ru (8.14.5/8.14.5) with ESMTP id s6RJJmfT076274 for ; Sun, 27 Jul 2014 23:19:48 +0400 (MSK) (envelope-from marck@rinet.ru) Date: Sun, 27 Jul 2014 23:19:48 +0400 (MSK) From: Dmitry Morozovsky To: freebsd-stable@freebsd.org Subject: Re: restore: bad block size 5632 between different major versions In-Reply-To: Message-ID: References: User-Agent: Alpine 2.00 (BSF 1167 2008-08-23) X-NCC-RegID: ru.rinet X-OpenPGP-Key-ID: 6B691B03 MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (woozle.rinet.ru [0.0.0.0]); Sun, 27 Jul 2014 23:19:48 +0400 (MSK) X-BeenThere: freebsd-stable@freebsd.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Production branch of FreeBSD source code List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 27 Jul 2014 19:20:01 -0000 Colleagues, following up to myself: On Thu, 24 Jul 2014, Dmitry Morozovsky wrote: > I'm a bit stumbled. > > prerequisites: > > - backup server, stable/9 (a bit obsoleted, but this is unrelated to the > problem) I forgot to mention that it is ZFS-based. > ** on backup server: > backup@whale:/B/dump/lion> uname -r > 9.1-STABLE > backup@whale:/B/dump/lion> cat 5-var.dgz.?? | zcat | ./restore -t -v -f - > Verify tape and initialize maps > Dump date: Thu Jul 24 06:57:04 2014 > Dumped from: Wed Jul 23 06:57:04 2014 > Level 5 dump of /var on lion.rinet.ru:/dev/da0e > Label: none > bad block size 5632 ktrace'ing restore I've found that stat(".") on ZFS in my case returning blksize=5632, which makes restore unhappy somewhere at 261- if (stbuf.st_blksize >= TP_BSIZE && stbuf.st_blksize <= MAXBSIZE) 262- fssize = stbuf.st_blksize; 263- if (((fssize - 1) & fssize) != 0) { 264: fprintf(stderr, "bad block size %ld\n", fssize); 265- done(1); 266- } commenting lines 263-266 gives me working restore. Any hints from now? It's not clear to me why we check this at all? Thanks! -- Sincerely, D.Marck [DM5020, MCK-RIPE, DM3-RIPN] [ FreeBSD committer: marck@FreeBSD.org ] ------------------------------------------------------------------------ *** Dmitry Morozovsky --- D.Marck --- Wild Woozle --- marck@rinet.ru *** ------------------------------------------------------------------------