From owner-freebsd-hackers@FreeBSD.ORG Sun Jul 6 09:07:32 2003 Return-Path: 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 A774637B401 for ; Sun, 6 Jul 2003 09:07:26 -0700 (PDT) Received: from bluejay.mail.pas.earthlink.net (bluejay.mail.pas.earthlink.net [207.217.120.218]) by mx1.FreeBSD.org (Postfix) with ESMTP id 33C0A43FD7 for ; Sun, 6 Jul 2003 09:07:26 -0700 (PDT) (envelope-from tlambert2@mindspring.com) Received: from user-2ivfmrb.dialup.mindspring.com ([165.247.219.107] helo=mindspring.com) by bluejay.mail.pas.earthlink.net with asmtp (SSLv3:RC4-MD5:128) (Exim 3.33 #1) id 19ZC2v-00015w-00; Sun, 06 Jul 2003 09:07:25 -0700 Message-ID: <3F0848FF.A386477C@mindspring.com> Date: Sun, 06 Jul 2003 09:06:23 -0700 From: Terry Lambert X-Mailer: Mozilla 4.79 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Josh Brooks References: <20030704015704.Y57224-100000@mail.econolodgetulsa.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-ELNK-Trace: b1a02af9316fbb217a47c185c03b154d40683398e744b8a4cd6f194732abf3687cdd8ac3363233e8350badd9bab72f9c350badd9bab72f9c350badd9bab72f9c cc: freebsd-hackers@freebsd.org Subject: Re: recovering data from a truncated vn-file possible? X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 06 Jul 2003 16:07:33 -0000 Josh Brooks wrote: > Long story short, I have a 4gig vn-backed filesystem. The file backing it > is now missing the last 750megs ... I can vnconfig it, but when I fsck it > I see: Probably the first thing you'll want to do is write a small program to open the file and write a zero at the offset of the 750M to make the "device" the right size. Most of the recovery tools, including fsck, go into convulsions if the device size shrinks on them. So the first thing you want to do is change the size back to what it should be. -- Terry