Ciop-copy » History » Version 5
Herve Caumont, 2013-09-21 00:26
1 | 4 | Herve Caumont | h1. ciop-copy CLI reference |
---|---|---|---|
2 | 1 | Herve Caumont | |
3 | 4 | Herve Caumont | {{>toc}} |
4 | 1 | Herve Caumont | |
5 | h2. Name |
||
6 | |||
7 | 5 | Herve Caumont | ciop-copy -- copies the data from logical of physical location to a local directory of the sandbox |
8 | 1 | Herve Caumont | |
9 | h2. Synopsys |
||
10 | |||
11 | <pre> |
||
12 | ciop-copy [-h] [-a] [-q] [-f] [-b <url-base>] [-d <driver-def>] |
||
13 | [-o|O <sink-dir>] [-w <work-dir>] [-c] [-p <prefix>] [-z|-Z] |
||
14 | [-r <num-retries>] [-t <timeout>] [-R] [-l <log-label>] [-D] |
||
15 | <url1> [<url2> ... <urlN>] |
||
16 | </pre> |
||
17 | |||
18 | URL Parameters: |
||
19 | > Arguments are URL strings provided by seurl |
||
20 | > if a parameter is specified as '-', URLs are read and inserted from standard input |
||
21 | |||
22 | 5 | Herve Caumont | h2. Options |
23 | |||
24 | 1 | Herve Caumont | The following options are available: |
25 | > -h displays this help page |
||
26 | > -a abort on first error without attempting to process further URLs |
||
27 | > -q quiet mode, local filenames are not echoed to stdout after transfer |
||
28 | > -f force transfer of a physical copy of the file for nfs and HDFS urls. |
||
29 | > -d <driver-file> get additional drivers from shell file <driver-file>. Drivers shall contain a named <protocol>Driver |
||
30 | > -o|O <out-dir> defines the output directory for transfers (default is /root) with -O the sink files or directories possibly existing in the output directory will be overwritten. |
||
31 | > -co <out-dir> same as -c -o <out-dir>. Kept for retro-compatibility. |
||
32 | > -c creates the output directory if it does not exist |
||
33 | > -p <prefix> prepend the given prefix to all output names |
||
34 | > -z provide output as a compressed package (.gz for files or .tgz for folders). NOTE that it will not compress already compressed files (.gz, .tgz or .zip) |
||
35 | > -U|--no-uzip disable file automatic decompression of .gz, .tgz and .zip files. |
||
36 | > -r <num-retries> defines the maximum number of retries (default is 5) |
||
37 | > -rt <seconds> define the time (in seconds) between retries (default is 60) |
||
38 | > -t <timeout> defines the timer (in seconds) for the watchdog timeout applicable to gridftp, scp, ftp, http, and https schemes (default is 600 seconds) |
||
39 | > -R do not retry transfer after timeout |
||
40 | > -D set debug mode for command output parsing debugging |
||
41 | > -H do not follow html and rdf tags and .uar archives. |
||
42 | > -s skip download if sink path already exists |
||
43 | > -x <pattern> exclude the files matching the pattern |
||
44 | > -w do not overwrite single files iif already exist |
||
45 | |||
46 | h2. Output |
||
47 | |||
48 | 5 | Herve Caumont | Unless the -q option is used (quiet mode), the local path of each file or directory downloaded after each URL transfer is echoed, one per line. |
49 | 1 | Herve Caumont | |
50 | 5 | Herve Caumont | Unless the -U option is used, .gz or .tgz output files will be decompressed. |
51 | 1 | Herve Caumont | |
52 | 5 | Herve Caumont | Unless the -H option is used, the software will follow the RDF <dclite4g:onlineResource> and the HTML href & refresh tags. |
53 | |||
54 | h2. Exit codes |
||
55 | |||
56 | 1 | Herve Caumont | > 0 all URLs were successfully downloaded |
57 | > 1 an error occured during processing |
||
58 | > 255 environment is invalid (e.g. invalid working directory) or invalid options are provided |
||
59 | > 254 output directory does not exist or failed creating it (with -c option) |
||
60 | |||
61 | 5 | Herve Caumont | if the -a option is used, the exit code is set to the error code of the last URL transfer: |
62 | 1 | Herve Caumont | |
63 | 5 | Herve Caumont | > 252 no driver available for URL |
64 | > 251 an existing file or directory conflicts with the sink for the URL in the output directory |
||
65 | > 250 an error occured while unpacking the output file or when packaging/compressing the output file (when -z or -Z option is used) |
||
66 | > 128 a timeout occured while fetching an url |
||
67 | > 127 a fatal error occured, source of error is not known or not handled by driver |
||
68 | > <128 error codes specific to the transfer scheme |
||
69 | > 1 resource pointed by input URL does not exist |
||
70 | |||
71 | 1 | Herve Caumont | h2. Examples |
72 | 4 | Herve Caumont | |
73 | h3. Example 1 |
||
74 | 5 | Herve Caumont | |
75 | TBD |