Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 17 Oct 2000 03:54:37 +0000
From:      Tony Finch <dot@dotat.at>
To:        "Jason C. Wells" <jcwells@nwlink.com>
Cc:        Kris Kirby <kris@catonic.net>, freebsd-chat@FreeBSD.ORG
Subject:   Re: Traditional UN*X conventions (Or: Why not to login as root?)
Message-ID:  <20001017035437.B537@hand.dotat.at>
In-Reply-To: <Pine.SOL.3.96.1001016133315.4098A-100000@utah>
References:  <Pine.BSF.4.21.0010150739480.59649-100000@spaz.huntsvilleal.com> <Pine.SOL.3.96.1001016133315.4098A-100000@utah>

next in thread | previous in thread | raw e-mail | index | archive | help
"Jason C. Wells" <jcwells@nwlink.com> wrote:
>
>Let's consider the following typo:
>
># cd /
># rm -rf /tmp/ *
>
>Which the user intended to be:
>
># cd /
># rm -rf /tmp/*
>
>If you are in fact root, then you are in fact very, very screwed if you
>issue the typo.  In this case, not being root will save you from removing
>every last file on every mounted disc. 

Well, one usually spots the mistake and interrupts it fairly quickly.
There's /boot /bin /dev /etc before you get to anything important :-)
(One of the disadvantages of softupdates, however, is that it'll get
through those directories in the blink of an eye...)

I have managed to recover a machine that had crashed and destroyed
those directories. Recovering it was tricky, because of various
infelicities in the fixit CD and the difficulty of remounting /
read-write when /dev is missing. Oh, and init does interesting things
when /bin/sh is missing (it oscillates rapidly back-and-forth between
failing to start /etc/rc and failing to drop into single-user mode).

Tony.
-- 
en oeccget g mtcaa    f.a.n.finch
v spdlkishrhtewe y    dot@dotat.at
eatp o v eiti i d.    fanf@covalent.net


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-chat" in the body of the message




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