From: Vladislav Bolkhovitin Subject: Re: [ANNOUNCE] Btrfs: a copy on write, snapshotting FS Date: Tue, 19 Jun 2007 14:01:22 +0400 Message-ID: <4677A972.6030909@vlnb.net> References: <20070612161029.GB28279@think.oraclecorp.com> <4676C2D6.8030708@vlnb.net> <46779DB1.7060807@draigBrady.com> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: Chris Mason , linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org To: =?ISO-8859-1?Q?P=E1draig_Brady?= Return-path: In-Reply-To: <46779DB1.7060807@draigBrady.com> Sender: linux-kernel-owner@vger.kernel.org List-Id: linux-fsdevel.vger.kernel.org P=E1draig Brady wrote: > Vladislav Bolkhovitin wrote: >=20 >>I would also suggest one more feature: support for block level >>de-duplication. I mean: >> >>1. Ability for Btrfs to have blocks in several files to point to the >>same block on disk >> >>2. Support for new syscall or IOCTL to de-duplicate as a single >>transaction two or more blocks on disk, i.e. link them to one of them >>and free others >> >>3. De-de-duplicate blocks on disk, i.e. copy them on write >> >>I suppose that de-duplication itself would be done by some user space >>process that would scan files, determine blocks with the same data an= d >>then de-duplicate them by using syscall or IOCTL (2). >> >>That would be very usable feature, which in most cases would allow to >>shrink occupied disk space on 50-90%. >=20 > Have you references for this number? No, I've seen it somewhere and it well confirms with my own observation= s. > In my experience one gets a lot of benefit from > the much simpler process of "de-duplication" of files. Yes, sure, de-duplication on files level brings its benefits, but on FS= =20 blocks level it would bring ever more benefits, because there are many=20 more or less big files, which are different as a whole, but with a lot=20 of the same blocks. Simple example of such files is UNIX-style mail=20 boxes on a mail server. > Note a checksum stored in file metadata, > that is automatically invalidated on write would > speed up user space file de duplification, > and rsync, etc.... Sure, file level deduplication is simpler to implement, but it is=20 generally less powerful, than FS block level one. And seems it should=20 not be hard to add the above (1)-(3) features in the existing Btrfs=20 structure, especially on this stage, when the disk format isn't=20 stabilized yet. > P=E1draig. > - > To unsubscribe from this list: send the line "unsubscribe linux-kerne= l" in > the body of a message to majordomo@vger.kernel.org > More majordomo info at http://vger.kernel.org/majordomo-info.html > Please read the FAQ at http://www.tux.org/lkml/ >=20