Skip to main content.
home | support | download

Back to List Archive

stale NFS and SWISH::API

From: Peter Karman <karman(at)not-real.cray.com>
Date: Thu Jan 06 2005 - 22:29:50 GMT
I've run into this before with SWISH::API and am now reminded [again] 
that I need to do something about it. but what?

the issue is:

I've got an open SWISH::API handle tied to an index, and the index 
changes. Typically this is when a cron job creates a new index and 
renames it to the existing index. My running app will hang indefinitely, 
ostensibly because it is tied to a file that no longer "exists" (or at 
least, has changed in content).

This is an issue with things like SWISHED where I might reindex a site 
and the SWISHED needs to be SIGHUP'd or something. That's not optimal.

Is there already a [undocumented?] way of stat()'ing the index (or 
something like that) to check that the open handle is still valid, and 
then destroying the old handle and creating a new one?

Is this the kind of thing that my Perl code should/could handle, or 
should I be thinking about writing some kind of patch for the SWISH::API 
itself?

thoughts, anyone?
-- 
Peter Karman . http://www.cray.com/craydoc/ . karman(at)not-real.cray.com
"I love deadlines. I love the whooshing sound they make as they go by."
         - Douglas Adams
Received on Thu Jan 6 14:30:00 2005