From owner-freebsd-hackers@FreeBSD.ORG Thu May 5 12:32:27 2005 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 50A0316A4CE for ; Thu, 5 May 2005 12:32:27 +0000 (GMT) Received: from smtp-vbr13.xs4all.nl (smtp-vbr13.xs4all.nl [194.109.24.33]) by mx1.FreeBSD.org (Postfix) with ESMTP id B393743D7C for ; Thu, 5 May 2005 12:32:26 +0000 (GMT) (envelope-from wb@freebie.xs4all.nl) Received: from freebie.xs4all.nl (freebie.xs4all.nl [213.84.32.253]) j45CWKmY062371; Thu, 5 May 2005 14:32:20 +0200 (CEST) (envelope-from wb@freebie.xs4all.nl) Received: from freebie.xs4all.nl (localhost [127.0.0.1]) by freebie.xs4all.nl (8.13.3/8.13.1) with ESMTP id j45CWJdk001055; Thu, 5 May 2005 14:32:19 +0200 (CEST) (envelope-from wb@freebie.xs4all.nl) Received: (from wb@localhost) by freebie.xs4all.nl (8.13.3/8.13.1/Submit) id j45CWJgw001054; Thu, 5 May 2005 14:32:19 +0200 (CEST) (envelope-from wb) Date: Thu, 5 May 2005 14:32:19 +0200 From: Wilko Bulte To: Danny Braniss Message-ID: <20050505123219.GA1039@freebie.xs4all.nl> References: <427A094B.8040009@dnainternet.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-OS: FreeBSD 5.4-STABLE User-Agent: Mutt/1.5.9i X-Virus-Scanned: by XS4ALL Virus Scanner cc: freebsd-hackers@freebsd.org Subject: Re: req: New feature to rm? Remove file by the inode number X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 05 May 2005 12:32:27 -0000 On Thu, May 05, 2005 at 03:24:25PM +0300, Danny Braniss wrote.. > > Julien Gabel wrote: > > >>>I couldn't find a way to remove files that had scandic/non-printable > > >>>letters, then i remembered ls showed inode number of the file. Is it > > >>>possible to remove the file by the inode number? It would be a > > >>>useful feature :) > > >>> > > >>>I bet there is a way to remove those files, but only > > >>>third party programs came to my mind. > > > > > > > > > I think the -inum option of the find(1) utility can do the trick. > > > > > > > After trying clri, maybe find(1) is a better way :). I can imagine what > > would happen when i would use clri on wrong slice :) > > i haven't seen/used clri in years (maybe decades), but if memory doesn't fail, > clri just zeroes the inode, the blocks are not returned to the freelist! > and if it's a directory things can get nasty. man clri(8) tells you all about that.. -- Wilko Bulte wilko@FreeBSD.org