Hi, Andy
I implemented the trigger which gets executed when closing a file that was
open in write mode (in order to initiate immediate migration to another disk
pool). I chose to do it on the ofs level by inheriting from XrdOfs, and just
overriding the Unopen() and the ConfigXeq() methods.
But I had to change a few things in the XrdOfs.hh file: declare members as
protected instead of private and declare methods as virtual. Could this be
changed in the main source? It's nice to make additions inheriting from
XrdOfs, because the patch is small, a lot of helper functionality exists and
I don't need to patch the original sources, except for the instance
definition in XrdOfs.icc.
Sources (they unpack into /src/XrdOfs):
http://people.web.psi.ch/feichtinger/doc/XrdOfsWriteTrigger.tar.gz
(need to remove the object for XrdOfsConfig.o first befor building over an
existing installation. I need to clean up the build)
New Functionality:
The config file can now contain the command line for a program which gets
launched during the configuration phase. Upon closing a file that was opened
in write mode, the current filename is sent to the script's stdin.
Configuration option example:
ofs.writetrig /opt/xrootd/ardautils/migrate.pl -l logfile
Cheers,
Derek
--
Dr. Derek Feichtinger Tel: +41 22 767 10 07
ARDA project email: [log in to unmask]
CERN http://people.web.psi.ch/feichtinger
CH-1211 Genève 23
|