Newsgroups: comp.unix.shell
Path: utzoo!utgpu!news-server.csri.toronto.edu!torsqnt!lethe!druid!darcy
From: darcy@druid.uucp (D'Arcy J.M. Cain)
Subject: Re: File remove command?
Message-ID: <1991Jun16.142235.1137@druid.uucp>
Organization: D'Arcy Cain Consulting, West Hill, Ontario
References: <3431@crdos1.crd.ge.COM> <1991Jun15.210940.18999@cbnews.cb.att.com>
Distribution: na
Date: Sun, 16 Jun 91 14:22:35 GMT

In article <1991Jun15.210940.18999@cbnews.cb.att.com> ask@cblph.att.com writes:
>So, you now want to remove all files with inumber 397
>You need to know the root directory of your filesystem
>(use the /etc/mount or df command to find out if you are unsure)
>Then do a find and remove all occurences of that inumber
>$ cd /usrc    # /usrc is the filesystem containing the files
>$ find  .  -inum 397 -exec rm {} \;
>Caution:  inumbers are not unique in your system; only in your
>          filesystem.   So it's a very bad idea to do a
>                        find / -inum 397 .....

Don't try this at home kiddies.  Not every filesystem is mounted on root.
For example here is my system:

      /         :	Disk space:  20.54 MB of  31.64 MB available (64.95%).
      /usr      :	Disk space:  24.24 MB of 226.75 MB available (10.69%).
/usr/spool/news :	Disk space:  20.94 MB of  47.19 MB available (44.38%).

Now if I want to get rid of /usr/darcy/file and its inode is 397 I better
not try the above suggestion because there may be a file on my news
partition with the same inode number.

-- 
D'Arcy J.M. Cain (darcy@druid)     |
D'Arcy Cain Consulting             |   There's no government
Toronto, Ontario, Canada           |   like no government!
+1 416 424 2871                    |
