[Gllug] Which files link to an inode?

Richard Jones rich at annexia.org
Wed Apr 23 13:30:01 UTC 2003


On Wed, Apr 23, 2003 at 01:19:41PM +0100, Simon Morris wrote:
> Hello,
> 
> I have a IRIX server at work. When other engineers were deleting masses of
> data from the disks, the disk free (df -h) command showed no difference to
> the amount of free space.
> 
> Having checked the directory in question I think there are multiple hard
> links pointing to the data..
> 
> server 17# ls -l
> total 552
> drwxrwxr-x    3 root     it            66 Jul 17  2002   GREEN = DVD
> -rwxrw-rw-    1 evagorou user       12292 Mar 21 17:56 .DS_Store
> drwxrwxr-x    2 root     it            49 Dec 12 09:07 .HSResource
> -rw-rw-rw-    1 root     it        256500 Mar 21 14:44 .HSancillary
> -rwxrwxr-x    1 root     it             0 Jul 29  1998 .HSicon
> drwxrwxrwx    5 root     sys           78 Apr 15 15:47 BAT.2723.1
> drwxrwxrwx    8 root     sys          121 Jan  9 15:29 BAT.2734.1
> drwxrwxrwx    8 root     sys          121 Jan  9 15:30 BAT.2752.1
> drwxrwxrwx    8 root     sys          121 Jan 13 09:36 BAT.2783.1
> drwxrwxrwx    8 root     sys          139 Mar 17 16:39 BAT.2797.1.12122002a
> drwxrwxr-x   24 root     it          4096 Aug 21  2002 No data
> drwxrwxrwx   20 remy     user        4096 Feb 19 13:20 Storage
> drwxrwxrwx    5 evagorou sys           72 Mar  4 11:29 Temporary Items
> server 18#
> 
> Am I right in saying the number after the permission bits are the number
> of hard links associated?

Yup.

> What command can I run to see which other files are linked to this data,
> so I can correctly delete the data.

Unfortunately you need to do something like:

find /mount/point -xdev -inum INODE_NUM -print

Not sure if -xdev works on IRIX. If not, just omit it.

Rich.

-- 
Richard Jones, Red Hat Inc. (London) and Merjis Ltd. http://www.merjis.com/
http://www.annexia.org/ Freshmeat projects: http://freshmeat.net/users/rwmj
NET::FTPSERVER is a full-featured, secure, configurable, database-backed
FTP server written in Perl: http://www.annexia.org/freeware/netftpserver/


-- 
Gllug mailing list  -  Gllug at linux.co.uk
http://list.ftech.net/mailman/listinfo/gllug




More information about the GLLUG mailing list