Date: Fri, 31 Jan 2014 19:45:51 +0100 From: Adam Nowacki <nowakpl@platinum.linux.pl> To: Antonis Anastasiadis <anastasiadis@datalive.gr>, freebsd-fs@freebsd.org Subject: Re: ZFS - Uncompress raw LZ4 data Message-ID: <52EBEF5F.4060100@platinum.linux.pl> In-Reply-To: <52EB84F3.50602@datalive.gr> References: <52EB84F3.50602@datalive.gr>
next in thread | previous in thread | raw e-mail | index | archive | help
On 2014-01-31 12:11, Antonis Anastasiadis wrote: > Hi everyone, > > I'm trying to recover a deleted file from a single disk LZ4 compressed > dataset. The pool is in fine condition. > > I tried printing the uberblock history via zdb, but the file had been > deleted before the oldest uberblock I could find. So I guess I can't > roll back into that pool state. > > The file was very small (90-120 kb) so it should fit in a single ZFS > block. I do not know the deleted block's DVA in order to restore it via > zdb -R. But I have similar files on the disk, so I can get the file header. > > As a last resort, I'm thinking going brute force and somehow find all > ZFS blocks (even deleted ones) from the raw partition, decompress the > data and check the binary data for the file header. Is there a tool that > decompresses raw LZ4 data out there? Max Bruning has written a utility > called "zuncompress" but it doesn't support LZ4 > (http://mbruning.blogspot.gr/2009/12/zfs-raidz-data-walk.html) You'll find the code to decompress in sys/cddl/contrib/opensolaris/uts/common/fs/zfs/lz4.c, LZ4_uncompress_unknownOutputSize. > > I know 'm shooting in the dark here, but I would appreciate any other > ideas from the ZFS gurus out there. > > Thanks, > > Antonis Anastasiadis > _______________________________________________ > freebsd-fs@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-fs > To unsubscribe, send any mail to "freebsd-fs-unsubscribe@freebsd.org" >
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?52EBEF5F.4060100>