[Orca-users] Stopping 'file did exist and is now gone' message(s).

Blair Zajac blair at orcaware.com
Sat Nov 23 17:27:00 PST 2002


"isaac r." wrote:
> 
> Blair,
> 
> Better yet - forget about checking if the filename
> has changed (i.e. whether it got compressed or not).
> 
> Simply check if the inode is there. The inode stays
> the same eventhough the filename changes.

I don't believe there's a way to open a file by inode.  You need
the name and finding the new name won't be easy in general.  You
could check all the files in the directory.

In any case, the compression programs will create a brand new
file with a new inode.  I just tested it with gzip:

% ls -li group
  26585 -rw-r--r--    1 blair    arbz          820 Nov 23 17:22 group
% gzip group
% ls -li group.gz
  26586 -rw-r--r--    1 blair    arbz          439 Nov 23 17:22 group.gz

> 
> Perl has a system call (escapes my mind which one),
> that shows all the details about a file, including
> mtime,accesstime,filename, and all the rest of  it...

stat().

Best,
Blair

-- 
Blair Zajac <blair at orcaware.com>
Web and OS performance plots - http://www.orcaware.com/orca/



More information about the Orca-users mailing list