Project

General

Profile

Ifdh commands » History » Version 14

Marc Mengel, 01/10/2014 03:14 PM

1 2 Marc Mengel
h1. ifdh commands
2 1 Marc Mengel
3 9 Marc Mengel
Note that many of these commands rely on the environment variable
4 9 Marc Mengel
IFDH_BASE_URI being set, i.e. 
5 9 Marc Mengel
 export IFDH_BASE_URI="http://samweb-minerva.fnal.gov:20004/sam/minerva/api"
6 9 Marc Mengel
7 7 Marc Mengel
* *ifdh* *cp* _src  dest_
8 2 Marc Mengel
** general file copy using cpn or srmcp
9 10 Marc Mengel
@ifdh cp [--force=srm|gridftp|cpn|expftp] [-r]  src1 dest1 [ ";" src2 ...  dest2 [ ";" ... ]  ]@
10 10 Marc Mengel
@ifdh cp [--force=srm|gridftp|cpn|expftp] -f listfile@
11 10 Marc Mengel
@ifdh cp [--force=srm|gridftp|cpn|expftp] -D [-r]  src1 src2 destdir1 [ ";" src3 src4 ...  destdir2 [ ";" ... ]  ]@
12 10 Marc Mengel
One can also set IFDH_FORCE= in the environment rather than using --force=
13 12 Marc Mengel
* *ifdh* *ls* _dest_ [ _depth_ [--force=srm|gridftp|cpn]]
14 11 Marc Mengel
** list file or directory 
15 13 Marc Mengel
** also confirms existence
16 11 Marc Mengel
* *ifdh* *mkdir* _dest_ [--force=srm|gridftp|cpn]
17 11 Marc Mengel
** make directories
18 11 Marc Mengel
* *ifdh* *rm* _dest_ [--force=srm|gridftp|cpn]
19 11 Marc Mengel
** remove files
20 11 Marc Mengel
* *ifdh* *rmdir* _dest_ [--force=srm|gridftp|cpn]
21 11 Marc Mengel
** remove directories
22 7 Marc Mengel
* *ifdh* *fetchInput* _src_uri_
23 2 Marc Mengel
** get input file to local scratch, return scratch location
24 7 Marc Mengel
* *ifdh* *addOutputFile* _filename_
25 2 Marc Mengel
** add output file to set
26 7 Marc Mengel
* *ifdh* *copyBackOutput* _dest_dir_
27 2 Marc Mengel
** copy output file set to destination with cpn or srmcp
28 7 Marc Mengel
* *ifdh* *log* _message_
29 2 Marc Mengel
** logging 
30 7 Marc Mengel
* *ifdh* *enterState* _state_
31 2 Marc Mengel
** log entering/leaving states
32 7 Marc Mengel
* *ifdh* *leaveState* _state_
33 2 Marc Mengel
** log entering/leaving states
34 7 Marc Mengel
* *ifdh* *createDefinition* _name  dims  user  group_
35 2 Marc Mengel
** make a named dataset definition from a dimension string
36 7 Marc Mengel
* *ifdh* *deleteDefinition* _name_
37 2 Marc Mengel
** remove data set definition
38 7 Marc Mengel
* *ifdh* *describeDefinition* _name_
39 2 Marc Mengel
** describe a named dataset definition
40 7 Marc Mengel
* *ifdh* *translateConstraints* _dims_
41 2 Marc Mengel
** give file list for dimension string
42 7 Marc Mengel
* *ifdh* *locateFile* _name_
43 2 Marc Mengel
** locate a file
44 7 Marc Mengel
* *ifdh* *getMetadata* _name_
45 2 Marc Mengel
** get a files metadata
46 7 Marc Mengel
* *ifdh* *dumpStation* _name  what_
47 2 Marc Mengel
** give a dump of a SAM station status
48 7 Marc Mengel
* *ifdh* *startProject* _name  station  defname_or_id  user  group_
49 2 Marc Mengel
** start a new file delivery project
50 7 Marc Mengel
* *ifdh* *findProject* _name  station_
51 2 Marc Mengel
** find a started project
52 7 Marc Mengel
* *ifdh* *establishProcess* _projecturi  appname  appversion  location  user  appfamily   description   filelimit_
53 2 Marc Mengel
** set yourself up as a file consumer process for a project
54 7 Marc Mengel
* *ifdh* *getNextFile* _projecturi  processid_
55 2 Marc Mengel
** get the next file location from a project
56 7 Marc Mengel
* *ifdh* *updateFileStatus* _projecturi  processid  filename  status_
57 2 Marc Mengel
** update the file status (use: transferred, skipped, or consumed)
58 7 Marc Mengel
* *ifdh* *endProcess* _projecturi  processid_
59 2 Marc Mengel
** end the process
60 14 Marc Mengel
* *ifdh* *dumpProject* _projecturi_
61 2 Marc Mengel
** say what the sam station knows about your process
62 7 Marc Mengel
* *ifdh* *setStatus* _projecturi  processid  status_
63 2 Marc Mengel
** set process status
64 7 Marc Mengel
* *ifdh* *endProject* _projecturi_
65 2 Marc Mengel
** end the project
66 8 Marc Mengel
* *ifdh* *cleanup*
67 2 Marc Mengel
** clean up any tmp file stuff