From owner-freebsd-fs@FreeBSD.ORG Sat Nov 26 18:17:48 2005 Return-Path: X-Original-To: freebsd-fs@FreeBSD.ORG Delivered-To: freebsd-fs@FreeBSD.ORG Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id ED05B16A41F for ; Sat, 26 Nov 2005 18:17:48 +0000 (GMT) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (lurza.secnetix.de [83.120.8.8]) by mx1.FreeBSD.org (Postfix) with ESMTP id 465DB43D5A for ; Sat, 26 Nov 2005 18:17:48 +0000 (GMT) (envelope-from olli@lurza.secnetix.de) Received: from lurza.secnetix.de (orgfel@localhost [127.0.0.1]) by lurza.secnetix.de (8.13.4/8.13.4) with ESMTP id jAQIHkRc096366 for ; Sat, 26 Nov 2005 19:17:46 +0100 (CET) (envelope-from oliver.fromme@secnetix.de) Received: (from olli@localhost) by lurza.secnetix.de (8.13.4/8.13.1/Submit) id jAQIHk09096365; Sat, 26 Nov 2005 19:17:46 +0100 (CET) (envelope-from olli) Date: Sat, 26 Nov 2005 19:17:46 +0100 (CET) Message-Id: <200511261817.jAQIHk09096365@lurza.secnetix.de> From: Oliver Fromme To: freebsd-fs@FreeBSD.ORG In-Reply-To: X-Newsgroups: list.freebsd-fs User-Agent: tin/1.5.4-20000523 ("1959") (UNIX) (FreeBSD/4.11-STABLE (i386)) Cc: Subject: Re: remind me ... (file undelete on FreeBSD 5.4) X-BeenThere: freebsd-fs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: freebsd-fs@FreeBSD.ORG List-Id: Filesystems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 26 Nov 2005 18:17:49 -0000 user 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. Best regards Oliver -- 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.