remind me ... (file undelete on FreeBSD 5.4)
olli at lurza.secnetix.de
Sat Nov 26 18:17:49 GMT 2005
user <user at dhp.com> wrote:
> ln -s /some/dir/somewhere local
> (used the symlink named local for a while)
> rm -rf local
> local still exists in my current working directory, but now
> /some/dir/somewhere is gone.
> So I rm -rf'd a symlink. I just wanted to delete the link, and of course,
Then why did you specify the -rf options in the first place?
UNIX usually does exactly what you tell it to do. That's
not a bug, it's a feature.
I know poeple who always type "rm -rf", no matter what they
want to delete. It's kind of a finger alias: Whenever they
type "rm", their fingers automatically add "-rf". I don't
know what the cause of that behaviour is (maybe they're too
lazy to think about it), but it definitely is dangerous, as
the above example shows. It's better to think first before
using the -rf options, especially when there's no backup.
> I know the bits are still there ... is there any way to get them back ?
With increasing complexity of the file system, the importance
of metadata also increases. That's why "undelete" is easy to
implement on FAT, but very difficult or even impossible on UFS.
I'd suggest you fetch your backup. If you don't have a backup
of the files, then I imply that the files weren't important.
Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing
Dienstleistungen mit Schwerpunkt FreeBSD: http://www.secnetix.de/bsd
Any opinions expressed in this message may be personal to the author
and may not necessarily reflect the opinions of secnetix in any way.
Passwords are like underwear. You don't share them,
you don't hang them on your monitor or under your keyboard,
you don't email them, or put them on a web site,
and you must change them very often.
More information about the freebsd-fs