Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uwm.edu!ogicse!ucsd!ucbvax!DCDMJW.FNAL.GOV!wicks From: wicks@DCDMJW.FNAL.GOV ("Matthew J. Wicks") Newsgroups: comp.sys.sgi Subject: Re: Listing names of linked files Message-ID: <9101291417.AA15961@dcdmjw.fnal.gov> Date: 29 Jan 91 14:17:49 GMT Sender: daemon@ucbvax.BERKELEY.EDU Organization: The Internet Lines: 35 >>Date: 29 January 1991, 11:58:25 MEZ >>From: Ralf Beyer (0531) 395-2530 FL17 at DLRVMBS >>To: info-iris at brl.mil >> >>Listing file links >> >>Hi, >> >>does anyone have an idea how to list the (path)names of the files a >>file is linked to ? ls -l gives the number of links but how can the >>associated names be retrieved ? >> >>Thanks and best regards >> >>Ralf Beyer >>fl17@dlrvmbs.bitnet >> A combination of ls and /etc/ncheck will provide this information. ls is required to get the inode number of the file (using the -i option) and then ncheck will return the path names for this inode. For example, to determine all the path names of inode 1971 in the root file system, the following command could be used: /etc/ncheck -i 1971 /dev/root Please note, you will most likely need to be root for this to work, as you need to be able to have read permission of the special device file (/dev/root) for this to work. Matt Wicks Fermi National Accelerator Laboratory wicks@fnal.fnal.gov 708-840-8083