Re: cpio reporting too many 'blocks'

From: Tim Kientzle <kientzle_at_freebsd.org>
Date: Wed, 03 Sep 2008 09:05:53 -0700
Giorgos Keramidas wrote:
> In a CURRENT snapshot built at:
> FreeBSD 8.0-CURRENT #0: Mon Sep  1 03:13:59 EEST 2008
> 
> bsdcpio is reporting _very_ large block counts:
> 
>   keramida_at_kobe:/ws/bsd/doc$ find * | cpio -p -dmu /hg/doc/bsd-import
>   757935406 blocks
>   keramida_at_kobe:/ws/bsd/doc$ du -sh .
>    24M    .
>   keramida_at_kobe:/ws/bsd/doc$ env | fgrep BLOCK
>   BLOCKSIZE=K

What does 'find * | xargs cat | wc -c' show?

> I haven't tried building cpio from earlier versions yet, because an
> mpsafetty test patch is building as I type this.  The last few commits
> seem related though:
> 
>   ------------------------------------------------------------------------
>   r182151 | kientzle | 2008-08-25 09:39:29 +0300 (Mon, 25 Aug 2008) | 6 lines

This is just a change to the regression tests.  Certainly not relevant.

>   ------------------------------------------------------------------------
>   r182102 | kientzle | 2008-08-24 09:21:00 +0300 (Sun, 24 Aug 2008) | 5 lines
> 
>   Update the total archive byte counters when writing entries to disk using
>   archive_write_disk.
>   Update cpio to use this to emit block counts in -p mode.
>   Update cpio tests to verify these block counts.

Prior to this commit, cpio didn't emit block counts in -p mode
at all.  I suppose reversing this commit might qualify as "fixing"
the problem, but I'd like to do better.  ;-)

I'll take a look...

Tim
Received on Wed Sep 03 2008 - 14:04:47 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:34 UTC