From owner-freebsd-current Thu Oct 22 23:17:24 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id XAA27818 for freebsd-current-outgoing; Thu, 22 Oct 1998 23:17:24 -0700 (PDT) (envelope-from owner-freebsd-current@FreeBSD.ORG) Received: from gatekeeper.tsc.tdk.com (gatekeeper.tsc.tdk.com [207.113.159.21]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id XAA27802 for ; Thu, 22 Oct 1998 23:17:22 -0700 (PDT) (envelope-from gdonl@tsc.tdk.com) Received: from sunrise.gv.tsc.tdk.com (root@sunrise.gv.tsc.tdk.com [192.168.241.191]) by gatekeeper.tsc.tdk.com (8.8.8/8.8.8) with ESMTP id XAA10310; Thu, 22 Oct 1998 23:16:51 -0700 (PDT) (envelope-from gdonl@tsc.tdk.com) Received: from salsa.gv.tsc.tdk.com (salsa.gv.tsc.tdk.com [192.168.241.194]) by sunrise.gv.tsc.tdk.com (8.8.5/8.8.5) with ESMTP id XAA18616; Thu, 22 Oct 1998 23:16:50 -0700 (PDT) Received: (from gdonl@localhost) by salsa.gv.tsc.tdk.com (8.8.5/8.8.5) id XAA19968; Thu, 22 Oct 1998 23:16:49 -0700 (PDT) From: Don Lewis Message-Id: <199810230616.XAA19968@salsa.gv.tsc.tdk.com> Date: Thu, 22 Oct 1998 23:16:49 -0700 In-Reply-To: Julian Elischer "Soft-Updates aware fsck available." (Oct 20, 8:22pm) X-Mailer: Mail User's Shell (7.2.6 alpha(3) 7/19/95) To: Julian Elischer , current@FreeBSD.ORG, mckusick@McKusick.COM Subject: Re: Soft-Updates aware fsck available. Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Oct 20, 8:22pm, Julian Elischer wrote: } Subject: Soft-Updates aware fsck available. } Kirk has supplied a 'soft-updates aware' fsck. } It requires a small tweek to compile under FreeBSD } but that's all. } } I've made the shar file available at: } http://www.freebsd.org/~julian/ } (at the bottom of the page). I now think that inoinfo(orphan)->ino_state = DFOUND; propagate(); needs to happen in pass3() even if linkup() fails (because lost+found filled or whatever), otherwise we risk tossing away files because their parent directory could not be reconnected. This gives the administrator the option of cleaning out lost+found and rerunning fsck to reconnect more stuff, and comes closer to the behavior of the current version of fsck in the tree. I also worry that /* * If we are running with soft updates and we come * across unreferenced directories, we just leave * them in DSTATE which will cause them to be pitched * in pass 4. */ if (preen && resolved && usedsoftdep && state == DSTATE) { if (inp->i_dotdot >= ROOTINO) inoinfo(inp->i_dotdot)->ino_linkcnt++; continue; } might be too agressive. What happens if we lose a directory close to the root due to an bad block? I'd only toss the directory if it is empty, which appears to be the usual cruft left behind by a crash when softupdates is in use. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message