pq2-put man page

pq2-put — Register one or more datasets in a dataset meta-repository based on ROOT files


pq2-put [options] datasetfile


This manual page documents briefly the pq2-put program.

pq2-put is a script invoking the pq2 ROOT application to register one or more datasets in a dataset meta-repository based on ROOT files; the repository can be accessed via the local file system or a remote file server daemon or a PROOF facility.

More details about the underlying 'pq2' application can be found in the man page pq2(1).


Path to the file with the list of files in the dataset or directory with the files containing the file lists of the datasets to be registered; in the first case wildcards '*' can be specified in the file name, i.e. '<dir>/fil*' is ok but '<dir>/*/file' is not. In all cases the name of the dataset is the name of the file finally used. The format of the file is described below.


-h, --help
Display help information.
-k, --keep
Keep the temporary files created during the analysis under $TMPDIR
Verbose mode
-d <datasetfile>, --dataset <datasetfile>
Alternative way to define path to the file with the list of files.
-o <options>

Options for registering datasets; a combination of:

O   overwrite existing dataset
U   add information to existing dataset, if any or create a new one
T   Trust the information already present in the dataset
V   verify (scan) information in the dataset (can be very slow)
Alternative to '-o O'.
Alternative to '-o U'.
Alternative to '-o T'.
Set the name of the default tree name to 'default-tree-name' (option 'T' or --trust only); this allows to skip the tree name specification during Process when more TTree (or derivative) objects are available in the files.
Assume all files online or staged (option 'T' or --trust only).
-u <serverurl>, --url=<serverurl>
URL of the PROOF master or data server providing the information; for data servers, it must include the directory. Can also be specified via the environment variables PQ2PROOFURL or PQ2DSSRVURL (see Environment Variables)."
-t <dir>, --tmpdir=<dir>
Directory for temporary files; defualt is /tmp/<username>.

Format of the Files

The name of the file defining the dataset is the name of the dataset. The files must contain one line per each file in the dataset with the full file URL. If available, additional information can be specified on the same line with the following keywords:

sz:<size>                            size of the file in bytes
md5:<md5_ascii>                      MD5 sum of the file in ASCII form
uuid:<uuid>                          UUID of the file
tree:<name>,<entries>,<first>,<last> meta-information about a tree in the file; the should be in the form
                                     <subdir>/tree-name;'entries' is the number of entries in the tree;
                                     'first' and 'last' define the entry range.
obj:<name>,<class>,<entries>         meta-information about a generic object in the file; the should be in
                                     the form <subdir>/obj-name; 'class' is the object class; 'entries' is
                                     the number of occurences for this object.

Multiple occurences of 'tree:' or 'obj:' can be specified.


The following examples show how to register information corresponding to the H1 example of the ROOT tutorials.

Minimal information

In this example the files are read from the ROOT HTTP server. Detailed information about the content of the files is not available, so only the URLs are given. If the file is called h1-http, we get

$ cat h1-http

The dataset is registered and verification required:

$ pq2-put -o "V" h1-http
pq2-put: 1 dataset(s) registered
Full information

In this example the files are read from the local /data/h1 directory. Detailed information about the content of the files is available. If the file is called h1-local, we get

$ cat h1-local
file:/data/h1/dstarmb.root  sz:21330730 md5:0a60055370e16d954f90fb50c2d1a801 tree:h42,21920,0,-1
file:/data/h1/dstarp1a.root md5:e2f959b15235214be3c973c3e7a9ff2c sz:71464503 tree:h42,73243
file:/data/h1/dstarp1b.root md5:169ea4799661696a25e73257fe8a833d sz:83827959 tree:h42,85597
file:/data/h1/dstarp2.root md5:907d10b401a35c0240cfa76bedc31420 sz:100675234 tree:h42,103053

The dataset is registered trusting the passed information:

$ pq2-put -o T --tree=h42 --staged h1-local
pq2-put: 1 dataset(s) registered

Environment Variables

See setup-pq2(1).

See Also

pq2(1), setup-pq2(1), pq2-ls(1), pq2-ls-files(1), pq2-ls-files-server(1), pq2-info-server(1), pq2-ana-dist(1), pq2-verify(1), pq2-rm(1), pq2-cache(1)

For more information on the ROOT system, please refer to http://root.cern.ch

Original Authors

Gerardo Ganis for the ROOT team.


This manual page was originally written by Gerardo Ganis <gerardo.ganis@cern.ch>, for ROOT version 5.

Referenced By

pq2(1), pq2-cache(1), pq2-info-server(1), pq2-ls(1), pq2-ls-files(1), pq2-ls-files-server(1), pq2-redistribute(1), pq2-rm(1), pq2-verify(1).

Explore man page connections for pq2-put(1).

ROOT Version 5