From owner-freebsd-stable Fri May 26 9:30:58 2000 Delivered-To: freebsd-stable@freebsd.org Received: from freeway.dcfinc.com (cx74889-a.phnx3.az.home.com [24.1.193.157]) by hub.freebsd.org (Postfix) with ESMTP id 144DC37B563 for ; Fri, 26 May 2000 09:30:53 -0700 (PDT) (envelope-from chad@freeway.dcfinc.com) Received: (from chad@localhost) by freeway.dcfinc.com (8.8.8/8.8.8) id JAA02025; Fri, 26 May 2000 09:30:47 -0700 (MST) (envelope-from chad) From: "Chad R. Larson" Message-Id: <200005261630.JAA02025@freeway.dcfinc.com> Subject: Re: I need to recover files and directories.. In-Reply-To: <4.3.1.2.20000526121516.00b4db20@msm.cl> from "Marcelo J. Iturbe" at "May 26, 0 12:20:32 pm" To: marcelo@msm.cl (Marcelo J. Iturbe) Date: Fri, 26 May 2000 09:30:47 -0700 (MST) Cc: stable@FreeBSD.ORG Reply-To: chad@DCFinc.com X-Mailer: ELM [version 2.4ME+ PL40 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-stable@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG As I recall, Marcelo J. Iturbe wrote: > Hello, > One of my users deleted a directory. > It is not in the backups. > Is there a way to recover? Is there a script that looks at the file systems > and recovers lost file pointers, I imagine that the info might still be on > the hard drive, just the sector was marked as usable.. Probably not if anyone or process has written to the drive since the deletion. The UFS free blocks get re-used most recently freed first. If you panic'd the machine immediately after learning of the deletion, you can get the files and/or directories back using the filesystem debugger (fsdb). It's not for the faint of heart, and requires a fair understanding of the filesystem internals. Usually the goal is to repair just enough stuff so that the filesystem check program (fsck) can put the data back together. Like, marking the inodes as allocated and let fsck find them and put them in lost+found. Don't ask me how I know this. :-) -crl -- Chad R. Larson (CRL15) 602-953-1392 Brother, can you paradigm? chad@dcfinc.com chad@larsons.org larson1@home.net DCF, Inc. - 14623 North 49th Place, Scottsdale, Arizona 85254-2207 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-stable" in the body of the message