Print

Print


All this behavior is consistent with a non-locked file on a Unix system, 
i.e. you can delete an open file, you can continue accessing it and will 
only disappear when closed. But of course in this case we would like to 
have a lock.

-- Fons


Derek Feichtinger wrote:
> Hi,
> 
> I have a r/w + MSS setup.
> 
> My little test from the ROOT shell:
> root [0] File *f 
> =TFile::Open("root://redirector.cern.ch//tmp/xrootd/new.root","create")
> root [1] TTree *t = new TTree("t","title")
> root [2] t->Write()
> 
> Now I use another shell to execute this perl client command:
> @ans = XrdClientAdmin::XrdRm("/tmp/xrootd/new11.root");
> 
> This succeeds and I can see, that the file was indeed erased from the 
> respective leaf node (and the cache and the MSS!), even though the other 
> client should have a lock on it!!!
> 
> Moreover, in my ROOT session I go happily on writing to the file:
> root [3] TTree *t2 = new TTree("t2","title")
> root [4] t2->Write()
> 
> (I can see on the leaf node log that it correctly acknowledges the bytes sent)
> 
> root [5] f->Close()
> 
> (here, too, I receive no errors upon closing and the leaf node log also shows 
> no peculiar entries.).
> 
> I try to open my file again, and I fail
> root [0] File *f 
> =TFile::Open("root://redirector.cern.ch//tmp/xrootd/new.root","read")
> 
> (I can see that it has not been recreated!). Where have my bytes gone?
> 
> 
> Background:
> I'm trying to investigate how an external MPS (Migration, Purge, Staging) 
> script could interact with the xrootd system.
> 
> Cheers,
> Derek
> 
> 

-- 
Org:    CERN, European Laboratory for Particle Physics.
Mail:   1211 Geneve 23, Switzerland
E-Mail: [log in to unmask]              Phone: +41 22 7679248
WWW:    http://www.rademakers.org/fons/      Fax:   +41 22 7679480