You need to enable JavaScript to run this app.
Torch Object Storage

Torch Object Storage

Copy page
Download PDF
Upload, download, and copy objects
Resume a failed task (cp)
Copy page
Download PDF
Resume a failed task (cp)
You can use the cp command to resume a failed task.​
Command syntax​
​
Linux/macOS
Windows
​
​
​
./tosutil cp -recover=xxx [-dryRun] [-tempFileDir=xxx] [-u] [-vchecksum] [-j=1] [-p=1] [-threshold=52428800] [-nfj=1] [-ps=auto] [-cpd=xxx] [-acl=xxx] [-meta=aaa:bbb#ccc:ddd] [-sse=xxx] [-sseKeyId=xxx] [-contentType=xxx] [-contentDisposition=xxx] [-contentEncoding=xxx] [-contentLanguage=xxx] [-cacheControl=xxx] [-expires=xxx] [-include=*.xxx] [-exclude=*.xxx] [-timeRange=time1-time2] [-at] [-ddo] [-dmf] [-o=xxx] [-bt=xxx] [-sbt=xxx] [-e=xxx] [-re=xxx] [-i=xxx] [-k=xxx] [-t=xxx] [-conf=xxx]​
​
​
​
​
Parameters​
For descriptions of common optional parameters, see Global options.​
​
Parameter​
Type​
Description​
-dryRun​
Bool​
Run in test mode without executing any actual uploads, downloads, or copy operations.​
-tempFileDir​
String​
The folder where temporary files generated during multipart downloads are stored. The default location is specified in the configuration file as defaultTempFileDir.​
tip​
  • If this parameter and the defaultTempFileDir parameter in the configuration file are both left blank, the temporary files will be stored in the same directory as the objects to be downloaded. These files will have names ending in .tos.temp.​
  • Since these temporary files will be saved in this directory, ensure that the user running tosutil has write permissions to this path. The available space in this directory must exceed the size of the objects to be downloaded.​
-recover​
String​
The ID of an object upload, download, or copy task to be resumed in the result file. For instructions on how to obtain the task IDs, see Viewing result files of batch tasks.​
-u​
Bool​
This parameter is used for incremental uploads, downloads, or copies of objects. It compares the source and destination. We recommend using this setting in the following cases:​
  • The destination does not exist.​
  • The file size at the destination differs from that at the source.​
  • The last modified time at the destination is earlier than that at the source.​
-vchecksum​
Bool​
Validate data integrity during uploads or downloads using the CRC-64 algorithm.​
-j​
Integer​
The maximum concurrency for batch operations. This value is set to 3 by default, which is the defaultJobs value in the configuration file.​
-p​
Integer​
The maximum concurrency for each multipart task. This value is set to 1 by default, which is the defaultParallels value in the configuration file.​
-threshold​
Integer​
The limit, in bytes, for a multipart task. This value is set to the defaultBigfileThreshold value in the configuration file by default.​
tip​
This parameter supports configuration with capacity units. For example, there is no need to manually calculate how many bytes are in 1 MB—just write "1 MB," and the program will recognize it.​
-nfj​
Integer​
The maximum concurrency for regular object batch processing (non-multipart tasks). The default is the maximum concurrency for batch operations. This parameter only takes effect during batch operations.​
-ps​
Integer/String​
The size, in bytes, of each part during a multipart task. This value is set to the defaultPartSize value in the configuration file by default.​
tip​
This parameter supports configuration with capacity units. For example, there is no need to manually calculate how many bytes are in 1 MB—just write "1 MB," and the program will recognize it.​
-cpd​
String​
The folder where checkpoint files are stored. The default location is specified in the configuration file as defaultCheckpointDir.​
-acl​
String​
Sets the predefined access control lists (ACLs) for objects to be uploaded or copied. Possible values:​
  • private​
  • public-read​
  • public-read-write​
  • authenticated-read​
  • bucket-owner-read​
  • bucket-owner-full-control​
-meta​
String​
Sets the user-defined metadata of objects to be uploaded or copied.​
-sse​
String​
Sets the server-side encryption algorithm used when uploading or copying objects. Possible values:​
  • aes256​
  • Kms​
This value is set to the defaultSse value in the configuration file by default.​
-sseKeyId​
String​
The key used when uploading or copying objects with server-side encryption with Key Management Service (KMS). This value is set to the defaultSseKeyId value in the configuration file by default.​
-contentType​
String​
Sets the Content-Type metadata for objects during upload or copy operations.​
-contentDisposition​
String​
Sets the Content-Disposition metadata for objects during upload or copy operations.​
-contentEncoding​
String​
Sets the Content-Encoding metadata for objects during upload or copy operations.​
-contentLanguage​
String​
Sets the Content-Language metadata for objects during upload or copy operations.​
-cacheControl​
String​
Sets the Cache-Control metadata for objects during upload or copy operations.​
-expires​
String​
Sets the Expires metadata for objects during upload or copy operations, in the format of YYYYMMDDHHmmSS.​
-include​
String​
The object matching pattern used to include objects for upload, download, or copying. You can use the wildcards ? and * and the delimiter "#" in the match expression.​
-exclude​
String​
The object matching pattern used to exclude objects from upload, download, or copy operations. You can use the wildcards ? and * and the delimiter "#" in the match expression.​
-timeRange​
String​
Sets the time range for the last modified time of objects during upload, download, or copy, in the format of YYYYMMDDHHmmSS-YYYYMMDDHHmmSS.​
-at​
Bool​
Upload a list of objects whose last access time falls within the -timeRange.​
-ddo​
Bool​
Do not upload the folder itself as an object.​
-dmf​
Bool​
Do not apply the parameters, -include/-exclude and -timeRange, to folders.​
-o​
String​
The folder where result files are stored. The default location is specified in the configuration file as defaultOutputDir.​
-bt​
String​
The type of the bucket in which the object copying failed. The options are as follows:​
  • fns: A flat namespace (FNS) bucket.​
  • hns: A hierarchical namespace (HNS) bucket.​
If the bucket type is not specified, the default will be the type obtained from the bucket metadata.​
-sbt​
String​
The type of the bucket where the copied objects will be stored once the failed copy task is resumed. The options are as follows:​
  • fns: A flat namespace (FNS) bucket.​
  • hns: A hierarchical namespace (HNS) bucket.​
If the bucket type is not specified, the default will be the type obtained from the bucket metadata.​
​
​
Last updated: 2025.12.17 18:33:44