Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 1 Aug 2006 13:42:52 -0500
From:      "Rick C. Petty" <rick-freebsd@kiwi-computer.com>
To:        Mike Meyer <mwm@mired.org>
Cc:        freebsd-hackers@freebsd.org
Subject:   Re: [PATCH] adding two new options to 'cp'
Message-ID:  <20060801184252.GB4272@megan.kiwi-computer.com>
In-Reply-To: <17615.40148.872008.53973@bhuda.mired.org>
References:  <44CE03D2.2050803@centtech.com> <17614.4005.407223.621637@bhuda.mired.org> <44CE199C.2020500@centtech.com> <17614.8289.134373.387558@bhuda.mired.org> <96b30c400607310847s1d2f845eo212b234d03f51e9a@mail.gmail.com> <17614.10982.499561.139268@bhuda.mired.org> <ealpn1$lan$1@sea.gmane.org> <20060801072611.GA717@turion.vk2pj.dyndns.org> <20060801171150.GB3413@megan.kiwi-computer.com> <17615.40148.872008.53973@bhuda.mired.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Aug 01, 2006 at 02:26:28PM -0400, Mike Meyer wrote:
> In <20060801171150.GB3413@megan.kiwi-computer.com>, Rick C. Petty <rick-freebsd@kiwi-computer.com> typed:
> 
> > Obviously, I didn't add the error checking/handling, but AFAIK this is
> > essentially what the -S option to gnu's tar does.
> 
> Yes, but gnu tar doesn't do this accurately,

That may be.  I haven't looked at their code, I just assumed how they did
it.

> so you're not doing what
> Peter said you couldn't do. You are doing what Ivan asked, though.

That depends upon what you mean by "accurately" and what you mean by
"sparse".  :-P  Yes, if you're looking for a block-wise "dump" of a file
system's file, you use dump.  If you're looking to make a "copy" of a file,
optimizing for sparseness, you use rsync.  A pretty heavyweight solution
when you're trying to copy one file.

> I always think of cp as a tool for making *copies of files*, not for
> creating an archive of a directory tree. We've got lots of tools that
> do the latter. Do we really need another one?

I wasn't thinking of the "sparse handling" utility for whole trees, but it
would be useful for that also.  I'm just looking for a lightweight tool
for copying files containing sparse chunks..  Since we switched to bsdtar,
the base system has been lacking this feature.  To me, this seems more
useful (as a base feature) than hard-linking trees.  But both have utility.

-- Rick C. Petty



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