xrd.pl the Xrootd client admin interface

xrd.pl is a command line tool that allows a user to query xrootd in order to stat, remove or checksum a file. For a full listing of the supported commands see the description below or run xrd.pl -h to get a help print out.

Usage:

      xrd.pl   [OPTIONS]    [ACTION]    [filename|xrootdurl]

Options:

      --debug dbgLvl     set set debug level for xrootd communication.
      --verbose             be verbose.
      --server XrdSrv    Xrootd server to connect to.
      --where                print the xrd server name after the last command has been executed.
      --help                   print this help.

Action:

    stat <fname>         stat a file

    checksum <fname>     checksum a file. A stat is issued before the checksum.
    checksumonly <fname> issue only a checksum cmd no stat. works only angainst a data server

    rm  <fname>        remove Fname  (ES: 0 = success, 1 = failure)
    mv  <Src> <Trg>    move a file within a data server from src to trg

    dir <dirname>      list a directory. Has to run against data server.

filename|xrootdurl

There are two ways to specify the xrootd file name.

  1. using the --server (-s) options
    The xrootd server is specified using the --server option (-s also works) and the file name is the logical xrootd file name, e.g.:
    xrd.pl  -s glast-rdr  stat  /glast/mc/testfile
    
  2. specify the full xrootd url:
    xrd.pl  stat  root://glast-rdr//glast/mc/testfile
    

Examples:

(The annoying version line of XrdClientAdmin has been omitted)

 xrd.pl  -s glast-rdr  stat /glast/wilko/f1
    size 37 onDisk 1 flags 48 modTime 1178659009 Tue May  8 14:16:49 2007 /glast/wilko/f1

 xrd.pl  -s glast-rdr -w  stat /glast/wilko/f1
    size 37 onDisk 1 flags 48 modTime 1178659009 Tue May  8 14:16:49 2007 /glast/wilko/f1
    currentHost silky02.slac.stanford.edu

 xrd.pl -s glast-rdr  checksum /glast/wilko/f1
    checksum 3146320528 size 37 CRC crc32 /glast/wilko/f1

 xrd.pl  dir root://sulky47//glast/mc
   DC2
   ServiceChallenge
   junk

  • No labels