Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 14 May 1995 16:18:57 -0700
From:      Ted Lemon <mellon@vix.com>
To:        jtk@kolvir.blrc.ma.us
Cc:        seebs@solon.com, netbsd-bugs@NetBSD.ORG, freebsd-hackers@FreeBSD.org
Subject:   Re: kern/1043: unlink(2) should not let superuser remove directories 
Message-ID:  <9505142318.AA12654@gw.home.vix.com>
In-Reply-To: Your message of "Sun, 14 May 1995 15:53:06 EDT." <199505141953.PAA04095@kolvir.blrc.ma.us> 

next in thread | previous in thread | raw e-mail | index | archive | help

> That's an argument for using fsdb, not to let root run rampant causing
> file system corruption.  Using fsdb makes it absolutely clear that
> you're intentionally doing something dangerous.  Using unlink(2) on
> directories is just the _Wrong Way_ to fix a damaged/broken filesystem!

I agree completely - surgical tools for filesystems do not belong in
the kernel.

> I'll put my money where my mouth is, and volunteer to write an fsdb
> program.  Anybody want to send me a man page/reference/description of
> the fsdb that comes with other commercial BSD derivatives?

Unfortunately, fsdb is virtually impossible to use because its
interface is essentially adb-like, and all the commands are
single-character and non-mnemonic.   If it were something one used
every day, that would be okay, but it's more like once every two years
for me, so I always have to track down a man page, which can be hard
when my root partition is hosed.

If you're going to write an fsdb replacement, I think it would be a
win to put in a more gdb- or even dbx-like interface.  It might be
worth looking at the man page for advice on what features to put in,
but that'd be about it, IMHO.

			       _MelloN_



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?9505142318.AA12654>