-
Notifications
You must be signed in to change notification settings - Fork 149
/
xrdcp.1
555 lines (451 loc) · 14.4 KB
/
xrdcp.1
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
.TH xrdcopy 1 "__VERSION__"
.SH NAME
xrdcp - copy files
.SH SYNOPSIS
.nf
\fBxrdcp\fR [\fIoptions\fR] \fIsource\fR \fIdestination\fR
\fIoptions\fR: [\fB--cksum\fR \fIargs\fR] [\fB--debug\fR \fIlvl\fR]
[\fB--coerce\fR] [\fB--force\fR] [\fB--help\fR] [\fB--license\fR]
[\fB--nopbar\fR] [\fB--posc\fR] [\fB--proxy \fIipaddr\fB:\fIport\fR]
[\fB--recursive\fR] [\fB--retry\fR \fItime\fR] [\fB--server\fR]
[\fB--silent\fR] [\fB--sources\fR \fInum\fR] [\fB--streams\fR \fInum\fR]
[\fB--tpc\fR [\fBdelegate\fR] \fBfirst\fR|\fBonly\fR] [\fB--verbose\fR]
[\fB--version\fR] [\fB--xrate\fR \fIrate\fR] [\fB--zip\fR \fIfile\fR]
[\fB--dynamic-src\fR] [\fB--infiles\fR \fIfn\fR] [\fB--path\fR]
[\fB--parallel\fR \fIn\fR] [\fB--allow-http\fR] [\fB--xattr\fR]
\fIlegacy options\fR: [\fB-adler\fR] [\fB-DS\fR\fIparm string\fR] [\fB-DI\fR\fIparm number\fR]
[\fB-md5\fR] [\fB-np\fR] [\fB-OD\fR\fIcgi\fR] [\fB-OS\fR\fIcgi\fR] [\fB-x\fR]
.fi
.br
.ad l
.SH DESCRIPTION
The \fBxrdcp\fR utility copies one or more files from one location to
another. The data source and destination may be a local
or remote file or directory. Additionally, the data source may also reside
on multiple servers.
.SH OPTIONS
\fB-C\fR | \fB--cksum\fR \fItype\fR[\fB:\fR\fIvalue\fR|\fIprint\fR|\fIsource\fR]
.RS 5
obtains the checksum of \fItype\fR (i.e. adler32, crc32, or md5) from the source,
computes the checksum at the destination, and verifies that they are the same. If a \fIvalue\fR
is specified, it is used as the source checksum. When \fIprint\fR
is specified, the checksum at the destination is printed but is \fInot\fR verified.
.RE
\fB-d\fR | \fB--debug\fR \fIlvl\fR
.RS 5
debug level: 1 (low), 2 (medium), 3 (high)
.RE
\fB-F\fR | \fB--coerce\fR
.RS 5
ignores locking semantics on the destination file. This option may lead to
file corruption if not properly used.
.RE
\fB-f\fR | \fB--force\fR
.RS 5
re-creates a file if it is already present.
.RE
\fB-h\fR | \fB--help\fR
.RS 5
displays usage information.
.RE
\fB-H\fR | \fB--license\fR
.RS 5
displays license terms and conditions.
.RE
\fB-N\fR | \fB--nopbar\fR
.RS 5
does not display the progress bar.
.RE
\fB-P\fR | \fB--posc\fR
.RS 5
requests POSC (persist-on-successful-close) processing
to create a new file. Files are automatically deleted should they not be
successfully closed.
.RE
\fB-D\fR | \fB--proxy\fR \fIproxyaddr\fB:\fIproxyport\fR
.RS 5
[NOT YET IMPLEMENTED]
use \fIproxyaddr\fB:\fIproxyport\fR as a SOCKS4 proxy. Only numerical addresses are supported.
.RE
\fB-r\fR | \fB--recursive\fR
.RS 5
recursively copy all files starting at the given source directory.
.RE
\fB--server\fR
.RS 5
runs as if in a server environment. Used only for server-side
third party copy support.
.RE
\fB-s\fR | \fB--silent\fR
.RS 5
neither produces summary information nor displays the progress bar.
.RE
\fB-y\fR | \fB--sources\fR \fInum\fR
.RS 5
uses up to \fInum\fR sources to copy the file.
.RE
\fB-S\fR | \fB--streams\fR \fInum\fR
.RS 5
use \fInum\fR parallel data streams to do the transfer (the main stream is
in this case not used to carry out the transfer).
The maximum value is 15. The default is 0 (i.e., use only the control stream).
.RE
\fB--tpc\fR [\fBdelegate\fR] \fBfirst\fR|\fBonly\fR
.RS 5
copies the file from remote server to remote server using third-party-copy
protocol (i.e., data flows from server to server). The source and destination
servers must support third party copies. Additional security restrictions
may apply and may cause the copy to fail if they cannot be satisfied.
Argument '\fBfirst\fR' tries tpc and if it fails, does a normal copy;
while '\fBonly\fR' fails the copy unless tpc succeeds. When '\fBdelegate\fR' is
specified, the copy delegates the command issuer's credentials to the target
server which uses those credentials to authenticate with the source server.
Delegation is ignored if the target server is not configured to use delegated
credentials. Currently, only gsi credentials can be delegated.
.RE
\fB-v\fR | \fB--verbose\fR
.RS 5
displays summary output.
.RE
\fB-V\fR | \fB-version\fR
.RS 5
displays version information and immediately exits.
.RE
\fB-z\fR | \fB--zip\fR \fIfile\fR
.RS 5
copy given file from a ZIP archive (same as xrdcl.unzip opaque info).
.RE
\fB-X\fR | \fB--xrate\fR \fIrate\fR
.RS 5
[NOT YET IMPLEMENTED]
limits the copy speed to the specified \fIrate\fB. The rate may be qualified
with the letter \fBk\fR, \fBm\fR, or \fBg\fR to indicate kilo, mega, or giga
bytes, respectively. The option only applies when the source or destination is
local.
.RE
\fB-Z\fR | \fB--dynamic-src\fR
.RS 5
file size may change during the copy
.RE
\fB-I\fR | \fB--infiles\fR \fIfn\fR
.RS 5
specifies the file that contains a list of input files
.RE
\fB-p\fR | \fB--path\fR
.RS 5
automatically create remote destination path
.RE
\fB--parallel\fR \fIn\fR
.RS 5
number of copy jobs to be run simultaneously
.RE
\fB--allow-http\fR
.RS 5
allow HTTP as source or destination protocol. Requires the XrdClHttp client plugin
.RE
\fB--xattr\fR
.RS 5
preserve extended attributes
.SH LEGACY OPTIONS
Legacy options are provided for backward compatability. These are now
deprecated and should be avoided.
.RE
\fB-adler\fR
.RS 5
equivalent to "\fB--cksum adler32:source\fR".
.RE
\fB-DI\fR\fIpname numberval\fR
.RS 5
set the internal parameter \fIpname\fR with the numeric value \fInumberval\fR.
.RE
\fB-DS\fR\fIpname stringval\fR
.RS 5
set the internal parameter \fIpname\fR with the string value \fIstringval\fR.
.RE
\fB-md5\fR
.RS 5
equivalent to "\fB--cksum md5:source\fR".
.RE
\fB-np\fR
.RS 5
equivalent to "\fB--nopbar\fR".
.RE
\fB-OD\fR\fIcgi\fR
.RS 5
add cgi information \fIcgi\fR to any destination xrootd URL.
You should specify the opaque information directly on the destination URL.
.RE
\fB-OS\fR\fIcgi\fR
.RS 5
add cgi information \fIcgi\fR to any source xrootd URL.
.RE
\fB-x\fR
.RS 5
equivalent to "\fB--sources 12\fR".
.RE
.SH OPERANDS
\fIsource\fR
.RS 5
a dash (i.e. \fB-\fR) indicating stanard in, a local file, a local directory name suffixed by /, or
an xrootd URL in the form of
.ce 1
\fBxroot://[\fIuser\fB@\fR]\fIhost[\fB:\fIport\fR]\fB/\fIabsolutepath\fR
The \fIabsolutepath\fR can be a directory.
.RE
\fIdestination\fR
.RS 5
a dash (i.e. \fB-\fR) indicating stanard out, a local file, a local directory
name suffixed by /, or an xrootd URL in the form
.ce 1
\fBxroot://[\fIuser\fB@\fR]\fIhost[\fB:\fIport\fR]\fB/\fIabsolutepath\fR
The \fIabsolutepath\fR can be a directory.
.RE
.SH ENVIRONMENT
The following environment variables are supported. They apply to xrdfs and any
other application using the libXrdCl library, unless specified otherwise. The
text in the brackets is a name of the corresponding xrdcp commandline parameter.
.br
XRD_LOGLEVEL
.RS 5
Detemines the amout of diagnostics that should be printed. Valid values are:
\fIDump\fR, \fIDebug\fR, \fIInfo\fR, \fIWarning\fR, and \fIError\fR.
.RE
XRD_LOGFILE
.RS 5
If set, the diagnostics will be printed to the specified file instead of stderr.
.RE
XRD_LOGMASK
.RS 5
Determines which diagnostics topics should be printed at all levels. It's a
"|" separated list of topics. The first element may be "All" in which case
all the topics are enabled and the subsequent elements may turn them off, or
"None" in which case all the topics are disabled and the subsequent flags may
turn them on. If the topic name is prefixed with "^", then it means that
the topic should be disabled. If the topic name is not prefixed, then it means
that the topic should be enabled.
.br
The log mask may as well be handled for each diagnostic level separately by
setting one or more of the following variables: \fIXRD_LOGMASK_ERROR\fR,
\fIXRD_LOGMASK_WARNING\fR, \fIXRD_LOGMASK_INFO\fR, \fIXRD_LOGMASK_DEBUG\fR,
and \fIXRD_LOGMASK_DUMP\fR. The default for each level is "All", except
for the \fIDump\fR level, where the default is "All|^PollerMsg". This means
that, at the \fIDump\fR level, all the topics but "PollerMsg" are enabled.
.br
Available topics: AppMsg, UtilityMsg, FileMsg, PollerMsg, PostMasterMsg,
XRootDTransportMsg, TaskMgrMsg, XRootDMsg, FileSystemMsg, AsyncSockMsg
.RE
XRD_PARALLELEVTLOOP
.RS 5
The number of event loops.
.RE
XRD_READRECOVERY
.RS 5
Determines if read recovery should be enabled or disabled (enabled by default).
.RE
XRD_WRITERECOVERY
.RS 5
Determines if write recovery should be enabled or disabled (enabled by default).
.RE
XRD_OPENRECOVERY
.RS 5
Determines if open recovery should be enabled or disabled for mutable (truncate or create) opens (enabled by default).
.RE
XRD_CONNECTIONWINDOW (-DIConnectionWindow)
.RS 5
A time window for the connection establishment. A connection failure is declared if
the connection is not established within the time window. If a connection failure
happens earlier then another connection attempt will only be made at the beginning
of the next window.
.RE
XRD_CONNECTIONRETRY (-DIConnectionRetry)
.RS 5
Number of connection attempts that should be made (number of available connection
windows) before declaring a permanent failure.
.RE
XRD_REQUESTTIMEOUT (-DIRequestTimeout)
.RS 5
Default value for the time after which an error is declared if it was impossible
to get a response to a request.
.RE
XRD_STREAMTIMEOUT (-DIStreamTimeout)
.RS 5
Default value for the time after which a connection error is declared (and a
recovery attempted) if there are unfulfilled requests and there is no socket
activity or a registered wait timeout.
.RE
XRD_SUBSTREAMSPERCHANNEL (-DISubStreamsPerChannel)
.RS 5
Number of streams per session.
.RE
XRD_TIMEOUTRESOLUTION (-DITimeoutResolution)
.RS 5
Resolution for the timeout events. Ie. timeout events will be
processed only every XRD_TIMEOUTRESOLUTION seconds.
.RE
XRD_STREAMERRORWINDOW (-DIStreamErrorWindow)
.RS 5
Time after which the permanent failure flags are cleared out and a new connection
may be attempted if needed.
.RE
XRD_RUNFORKHANDLER (-DIRunForkHandler)
.RS 5
Determines whether the fork handlers should be enabled, making the API fork safe.
.RE
XRD_REDIRECTLIMIT (-DIRedirectLimit)
.RS 5
Maximum number of allowed redirections.
.RE
XRD_NOTAUTHORIZEDRETRYLIMIT (-dNotAuthorizedRetryLimit)
.RS 5
Maximum number of allowed retries at a meta-manager for not-authorized error.
.RE
XRD_POLLERPREFERENCE (-DSPollerPreference)
.RS 5
A comma separated list of poller implementations in order of preference. The
default is: built-in.
.RE
XRD_CLIENTMONITOR (-DSClientMonitor)
.RS 5
Path to the client monitor library.
.RE
XRD_CLIENTMONITORPARAM (-DSClientMonitorParam)
.RS 5
Additional optional parameters that will be passed to the monitoring object
on initialization.
.RE
XRD_WORKERTHREADS (-DIWorkerThreads)
.RS 5
Number of threads processing user callbacks.
.RE
XRD_CPPARALLELCHUNKS (-DICPParallelChunks)
.RS 5
Maximum number of asynchronous requests being processed by the xrdcp command
per connected channel substream (adjusted in real-time).
.RE
XRD_CPCHUNKSIZE (-DICPChunkSize)
.RS 5
Size of a single data chunk handled by xrdcp.
.RE
XRD_NETWORKSTACK (-DSNetworkStack)
.RS 5
The network stack that the client should use to connect to the server. Possible
values are:
.B IPAuto
- automatically detect which IP stack to use
.B IPAll
- use IPv6 stack (AF_INET6 sockets) and both IPv6 and IPv4 (mapped to IPv6)
addresses
.B IPv6
- use only IPv6 stack and addresses
.B IPv4
- use only IPv4 stack (AF_INET sockets) and addresses
.B IPv4Mapped6
- use IPv6 stack and mapped IPv4 addresses
.RE
XRD_DATASERVERTTL (-DIDataServerTTL)
.RS 5
Time period after which an idle connection to a data server should be
closed.
.RE
XRD_LOADBALANCERTTL (-DILoadBalancerTTL)
.RS 5
Time period after which an idle connection to a manager or a load balancer
should be closed.
.RE
XRD_APPNAME (-DSAppName)
.RS 5
Override the application name reported to the server.
.RE
XRD_PLUGINCONFDIR
.RS 5
A custom location containing client plug-in config files.
.RE
XRD_PLUGIN
.RS 5
A default client plug-in to be used.
.RE
XRD_CPINITTIMEOUT (-DICPInitTimeout)
.RS 5
Maximum time allowed for the copy process to initialize, ie. open the source
and destination files.
.RE
XRD_CPTPCTIMEOUT (-DICPTPCTimeout)
.RS 5
Maximum time allowed for a third-party copy operation to finish.
.RE
XRD_TCPKEEPALIVE (-DITCPKeepAlive)
.RS 5
Enable/Disable the TCP keep alive functionality
.RE
XRD_TCPKEEPALIVETIME (-DITCPKeepAliveTime)
.RS 5
Time between last data packet sent and the first keepalive probe (Linux only)
.RE
XRD_TCPKEEPALIVEINTERVAL (-DITCPKeepAliveInterval)
.RS 5
Interval between subsequent keepalive probes (Linux only)
.RE
XRD_TCPKEEPALIVEPROBES (-DITCPKeepProbes)
.RS 5
Number of unacknowledged probes before considering the connection dead
(Linux only)
.RE
XRD_METALINKPROCESSING
.RS 5
Enable/Disable Metalink processing (enabled by default)
.RE
XRD_LOCALMETALINKFILE
.RS 5
Enable/Disable local Metalink file processing (by convention the following URL schema has to be used: root://localfile//path/filename.meta4)
The 'localfile' semantic is now deprecated, use file://localhost/path/filename.meta4 instead!
.RE
XRD_GLFNREDIRECTOR
.RS 5
The redirector will be used as a last resort if the GLFN tag is specified in a Metalink file.
.RE
XRD_XCPBLOCKSIZE
.RS 5
Maximu size of a data block assigned to a single source in case of an extreme copy transfer.
.RE
XRD_NODELAY
.RS 5
Disables the Nagle algorithm if set to 1 (default), enables it if set to 0.
.RE
XRD_PREFERIPV4
.RS 5
If set the client tries first IPv4 address (turned off by default).
.RE
XRD_MAXMETALINKWAIT
.RS 5
The maximum time in seconds a clinet can be stalled by the server if a Metalink redirector is available (defaults to 60s).
.RE
XRD_PRESERVELOCATETRIED
.RS 5
If set to 1 XRootD client will preserve tired/triedrc cgi opaque info for kXR_locate request accross redirects/retries,
if set to 0 XRootD client will treat kXR_locate as any other passive request.
.RE
XRD_PRESERVEXATTRS
.RS 5
If set to 1 (default) xrdcp will preverve file extended attribues,
if set to 0 file extended attributes wont be preserved.
.RE
.SH RETURN CODES
.RE
\fB50\fR : generic error (e.g. config, internal, data, OS, command line option)
\fB51\fR : socket related error
\fB52\fR : postmaster related error
\fB53\fR : XRootD related error
\fB54\fR : redirection error
\fB55\fR : query response was negative (this is not an error)
.SH NOTES
Documentation for all components associated with \fBxrdcp\fR can be found at
http://xrootd.org/docs.html
.SH DIAGNOSTICS
Errors yield an error message and a non-zero exit status.
.SH LICENSE
LGPL
.SH SUPPORT LEVEL
The \fBxrdcp\fR command is supported by the xrootd collaboration.
Contact information can be found at:
.ce
http://xrootd.org/contact.html