From owner-freebsd-hackers Mon Oct 27 20:03:30 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id UAA22473 for hackers-outgoing; Mon, 27 Oct 1997 20:03:30 -0800 (PST) (envelope-from owner-freebsd-hackers) Received: from smtp03.primenet.com (smtp03.primenet.com [206.165.5.84]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id UAA22464 for ; Mon, 27 Oct 1997 20:03:27 -0800 (PST) (envelope-from tlambert@usr08.primenet.com) Received: (from daemon@localhost) by smtp03.primenet.com (8.8.7/8.8.7) id VAA14244; Mon, 27 Oct 1997 21:03:24 -0700 (MST) Received: from usr08.primenet.com(206.165.6.208) via SMTP by smtp03.primenet.com, id smtpd014227; Mon Oct 27 21:03:18 1997 Received: (from tlambert@localhost) by usr08.primenet.com (8.8.5/8.8.5) id VAA05753; Mon, 27 Oct 1997 21:03:16 -0700 (MST) From: Terry Lambert Message-Id: <199710280403.VAA05753@usr08.primenet.com> Subject: Re: Recovering Lost Inode? To: perlsta@cs.sunyit.edu (Alfred Perlstein) Date: Tue, 28 Oct 1997 04:03:15 +0000 (GMT) Cc: freebsd-hackers@FreeBSD.ORG In-Reply-To: from "Alfred Perlstein" at Oct 27, 97 10:31:26 pm X-Mailer: ELM [version 2.4 PL23] Content-Type: text Sender: owner-freebsd-hackers@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk > i've always wondered why when a file was deleted there was an intelegent > way of moving it to a volatile directory where it could be overwritten at > any time, but if moved out of that dir it would be marked non-volitile > again.... Yes, but it's best implemented as a stacking layer. 8-). You could also set a "deleted" bit (there's an extra bit in the flags field in the directory entry -- or was), and not return it on search based on a mount option. The "purge" issue is a little more complex. I used a POSIX namespace escape to implement this functionality in an attributed FS I wrote for NetWare. Without the escape, deleted files were hidden; with it, they were visibile. An unlink of a visible file made it invisibile, and an unlink of an invisible file actually removed it. You would want to make /tmp and probably several other places immune from deletes like this. You can get a similar effect to VMS versions using another namespace escape; stacking name space escapes, anyone? 8-). Terry Lambert terry@lambert.org --- Any opinions in this posting are my own and not those of my present or previous employers.