From owner-freebsd-hackers@FreeBSD.ORG Tue Aug 1 18:43:56 2006 Return-Path: X-Original-To: freebsd-hackers@freebsd.org Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 8C59C16A4DF for ; Tue, 1 Aug 2006 18:43:56 +0000 (UTC) (envelope-from rick@kiwi-computer.com) Received: from kiwi-computer.com (megan.kiwi-computer.com [63.224.10.3]) by mx1.FreeBSD.org (Postfix) with SMTP id 6466D43D53 for ; Tue, 1 Aug 2006 18:43:09 +0000 (GMT) (envelope-from rick@kiwi-computer.com) Received: (qmail 4662 invoked by uid 2001); 1 Aug 2006 18:42:52 -0000 Date: Tue, 1 Aug 2006 13:42:52 -0500 From: "Rick C. Petty" To: Mike Meyer Message-ID: <20060801184252.GB4272@megan.kiwi-computer.com> 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> <20060801072611.GA717@turion.vk2pj.dyndns.org> <20060801171150.GB3413@megan.kiwi-computer.com> <17615.40148.872008.53973@bhuda.mired.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <17615.40148.872008.53973@bhuda.mired.org> User-Agent: Mutt/1.4.2.1i Cc: freebsd-hackers@freebsd.org Subject: Re: [PATCH] adding two new options to 'cp' X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: rick-freebsd@kiwi-computer.com List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 01 Aug 2006 18:43:56 -0000 On Tue, Aug 01, 2006 at 02:26:28PM -0400, Mike Meyer wrote: > In <20060801171150.GB3413@megan.kiwi-computer.com>, Rick C. Petty 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