Path: utzoo!news-server.csri.toronto.edu!cs.utexas.edu!sun-barr!decwrl!deccrl!news.crl.dec.com!shlump.nac.dec.com!fyrpwr.enet.dec.com From: prakash@fyrpwr.enet.dec.com (Mayank Prakash) Newsgroups: comp.unix.shell Subject: Re: NFS File identity resolution? Message-ID: <21155@shlump.nac.dec.com> Date: 15 Mar 91 23:22:19 GMT References: <21078@shlump.nac.dec.com> <7169@idunno.Princeton.EDU> Sender: newsdaemon@shlump.nac.dec.com Reply-To: prakash@aiag.enet.dec.com Organization: Digital Equipment Corporation, Marlboro, MA. Lines: 25 In article <7169@idunno.Princeton.EDU>, subbarao@phoenix.Princeton.EDU (Kartik Subbarao) writes: |-> |-> You can stat() both files, and compare the inodes and see if they're the |-> same. This would only be a problem, I would guess, if the two files had the |-> exact same inode number but in fact came from two different disks. Of That is the problem I am trying to solve. |-> course, you could do a simple popen() to df, chop out the right field, and |-> make sure that they're the same. This would confirm that they were mounted This would almost work, except that df truncates the name of the source file, and it needs an extra process spawn. Perhaps I should rather ask how does df work, instead? -mayank. +--------------------------------------------------------------------------+ | InterNet: Prakash@AIAG.ENET.DEC.COM | | UUCP: ...!decwrl!aiag.enet.dec.com!Prakash | | VoiceNet: (508)490.8139 | | BitNet: prakash%aiag.enet at decwrl.dec.com | | SnailNet: DEC, 290 Donald Lynch Blvd. DLB5-2/B4, Marlboro, MA 01752-0749 | +--------------------------------------------------------------------------+ Disclaimer: The above is probably only line noise, and does not reflect the opinions of anybody, including mine, far less my employer's.