forked from docs/doc-exports
Reviewed-by: Sabelnikov, Dmitriy <dmitriy.sabelnikov@t-systems.com> Co-authored-by: weihongmin1 <weihongmin1@huawei.com> Co-committed-by: weihongmin1 <weihongmin1@huawei.com>
301 lines
38 KiB
HTML
301 lines
38 KiB
HTML
<a name="obs_11_0064"></a><a name="obs_11_0064"></a>
|
|
|
|
<h1 class="topictitle1">Downloading Objects by Using an Authorization Code</h1>
|
|
<div id="body1568865770522"><div class="section" id="obs_11_0064__section1479112110815"><h4 class="sectiontitle">Function</h4><p id="obs_11_0064__p138646505217">You can use this command to download an object or download objects in a batch by object name prefix to your local PC.</p>
|
|
<div class="notice" id="obs_11_0064__note780411406113"><span class="noticetitle"><img src="public_sys-resources/notice_3.0-en-us.png"> </span><div class="noticebody"><p id="obs_11_0064__p24361115193913">Do not change the source objects in the OBS bucket when downloading a single object or objects in batches. Otherwise, the download may fail or data may be inconsistent.</p>
|
|
</div></div>
|
|
</div>
|
|
<div class="section" id="obs_11_0064__section19587175622519"><h4 class="sectiontitle">Command Line Structure</h4><ul id="obs_11_0064__ul4348115485212"><li id="obs_11_0064__li034819548529">In Windows<ul id="obs_11_0064__ul14371109125314"><li id="obs_11_0064__li645116618536">Enter the authorization code to download a single object.<pre class="screen" id="obs_11_0064__screen2021764195319">obsutil share-cp authorization_code file_or_folder_url -key=xxx [-ac=xxx] [-dryRun] [-tempFileDir=xxx] [-u] [-vlength] [-vmd5] [-p=1] [-threshold=52428800] [-ps=auto] [-cpd=xxx][-fr] [-o=xxx] [-config=xxx] </pre>
|
|
</li><li id="obs_11_0064__li1651115734815">Use the file path to transfer the authorization code and download a single object.<pre class="screen" id="obs_11_0064__screen1851167134817">obsutil share-cp file://authorization_code_file_url file_or_folder_url -key=xxx [-ac=xxx] [-dryRun] [-tempFileDir=xxx] [-u] [-vlength] [-vmd5] [-p=1] [-threshold=52428800] [-ps=auto] [-cpd=xxx][-fr] [-o=xxx] [-config=xxx] </pre>
|
|
</li><li id="obs_11_0064__li18337131475317">Enter the authorization code to download objects in a batch.<pre class="screen" id="obs_11_0064__screen15467124815533">obsutil share-cp authorization_code folder_url -r [-key=xxx] [-ac=xxx] [-dryRun] [-tempFileDir=xxx] [-f] [-u] [-vlength] [-vmd5] [-flat] [-j=1] [-p=1] [-threshold=52428800] [-ps=auto] [-include=*.xxx] [-exclude=*.xxx] [-timeRange=time1-time2] [-mf] [-o=xxx] [-cpd=xxx] [-config=xxx] </pre>
|
|
</li><li id="obs_11_0064__li03903527487">Use the file path to transfer the authorization code and download objects in a batch.<pre class="screen" id="obs_11_0064__screen1439016521486">obsutil share-cp file://authorization_code_file_url folder_url -r [-key=xxx] [-ac=xxx] [-dryRun] [-tempFileDir=xxx] [-f] [-u] [-vlength] [-vmd5] [-flat] [-j=1] [-p=1] [-threshold=52428800] [-ps=auto] [-include=*.xxx] [-exclude=*.xxx] [-timeRange=time1-time2] [-mf] [-o=xxx] [-cpd=xxx] [-config=xxx] </pre>
|
|
</li></ul>
|
|
</li><li id="obs_11_0064__li4476145885216">In Linux or macOS<ul id="obs_11_0064__ul10651133045317"><li id="obs_11_0064__li252718313536">Enter the authorization code to download a single object.<pre class="screen" id="obs_11_0064__screen970919582539">./obsutil share-cp authorization_code file_or_folder_url -key=xxx [-ac=xxx] [-dryRun] [-tempFileDir=xxx] [-u] [-vlength] [-vmd5] [-p=1] [-threshold=52428800] [-ps=auto] [-cpd=xxx][-fr] [-o=xxx] [-config=xxx] </pre>
|
|
</li><li id="obs_11_0064__li952883111532">Use the file path to transfer the authorization code and download a single object.<pre class="screen" id="obs_11_0064__screen2398117135418">./obsutil share-cp file://authorization_code_file_url file_or_folder_url -key=xxx [-ac=xxx] [-dryRun] [-tempFileDir=xxx] [-u] [-vlength] [-vmd5] [-p=1] [-threshold=52428800] [-ps=auto] [-cpd=xxx][-fr] [-o=xxx] [-config=xxx] </pre>
|
|
</li></ul>
|
|
<ul id="obs_11_0064__ul952830175011"><li id="obs_11_0064__li1952815013507">Enter the authorization code to download objects in a batch.<pre class="screen" id="obs_11_0064__screen152820015508">./obsutil share-cp authorization_code folder_url -r [-key=xxx] [-ac=xxx] [-dryRun] [-tempFileDir=xxx] [-f] [-u] [-vlength] [-vmd5] [-flat] [-j=1] [-p=1] [-threshold=52428800] [-ps=auto] [-include=*.xxx] [-exclude=*.xxx] [-timeRange=time1-time2] [-mf] [-o=xxx] [-cpd=xxx] [-config=xxx] </pre>
|
|
</li><li id="obs_11_0064__li1752819020508">Use the file path to transfer the authorization code and download objects in a batch.<pre class="screen" id="obs_11_0064__screen165286016501">./obsutil share-cp file://authorization_code_file_url folder_url -r [-key=xxx] [-ac=xxx] [-dryRun] [-tempFileDir=xxx] [-f] [-u] [-vlength] [-vmd5] [-flat] [-j=1] [-p=1] [-threshold=52428800] [-ps=auto] [-include=*.xxx] [-exclude=*.xxx] [-timeRange=time1-time2] [-mf] [-o=xxx] [-cpd=xxx] [-config=xxx] </pre>
|
|
</li></ul>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="obs_11_0064__section71771238124214"><h4 class="sectiontitle">Examples</h4><ul id="obs_11_0064__ul1017814387421"><li id="obs_11_0064__li41781387422">In Windows, you can run the <strong id="obs_11_0064__b1489721914333">obsutil share-cp xxx d:\temp\test.txt -ac=123456 -key=src/test.txt</strong> command to download a single object.<pre class="screen" id="obs_11_0064__screen917873824217"><strong id="obs_11_0064__b11178538144213">obsutil share-cp xxx </strong> <strong id="obs_11_0064__b6178193804215">d:\temp\test.txt -ac=123456 -key=test/test.txt</strong>
|
|
The authorized prefix is [test/test.txt]
|
|
|
|
Start at 2024-09-30 07:55:36.7698045 +0000 UTC
|
|
|
|
Parallel: 3 Jobs: 3
|
|
Threshold: 50.00MB PartSize: auto
|
|
VerifyLength: false VerifyMd5: false
|
|
CheckpointDir: xxxx
|
|
TempFileDir: xxxx
|
|
Waiting to prepare the temp file [xxx].
|
|
[==========================================] 100.00% 4.86 KB/s 0s
|
|
Download successfully, 19B, n/a, https://endpoint:443/test/test.txt --> d:\temp\test.txt
|
|
The authorized prefix is [test/test.txt]</pre>
|
|
</li></ul>
|
|
<ul id="obs_11_0064__ul10180103844214"><li id="obs_11_0064__li21801638184220">In Windows, you can run the <strong id="obs_11_0064__b9867164173417">obsutil share-cp xxx d:\temp -ac=123456 -f -r</strong> command to download objects in a batch.<pre class="screen" id="obs_11_0064__screen718153824211"><strong id="obs_11_0064__b1181173844214">obsutil share-cp xxx d:\temp -ac=123456 -f -r</strong>
|
|
The authorized prefix is [test]
|
|
|
|
Start at 2024-09-30 08:05:07.0097508 +0000 UTC
|
|
|
|
Parallel: 3 Jobs: 3
|
|
Threshold: 50.00MB PartSize: auto
|
|
VerifyLength: false VerifyMd5: false
|
|
CheckpointDir: xxxx
|
|
|
|
Task id: 1a50b1dd-3f92-42ae-a974-ff8fe514c2c2
|
|
OutputDir: xxxx
|
|
TempFileDir: xxxx
|
|
|
|
[======================================================] 100.00% 155.59 KB/s 0s
|
|
Succeed count: 6 Failed count: 0
|
|
Succeed bytes: xxx
|
|
Metrics [max cost:153 ms, min cost:129 ms, average cost:92.00 ms, average tps:17.86, transferred size:70B]
|
|
|
|
Task id: 1a50b1dd-3f92-42ae-a974-ff8fe514c2c2
|
|
The authorized prefix is [test/]</pre>
|
|
</li></ul>
|
|
</div>
|
|
<div class="section" id="obs_11_0064__section175878561255"><h4 class="sectiontitle">Parameter Description</h4>
|
|
<div class="tablenoborder"><table cellpadding="4" cellspacing="0" summary="" id="obs_11_0064__table1155454517538" frame="border" border="1" rules="all"><thead align="left"><tr id="obs_11_0064__row6558154516531"><th align="left" class="cellrowborder" valign="top" width="17.5%" id="mcps1.3.4.2.1.4.1.1"><p id="obs_11_0064__p1656117451534">Parameter</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="20.59%" id="mcps1.3.4.2.1.4.1.2"><p id="obs_11_0064__p155651545195310">Optional or Mandatory</p>
|
|
</th>
|
|
<th align="left" class="cellrowborder" valign="top" width="61.91%" id="mcps1.3.4.2.1.4.1.3"><p id="obs_11_0064__p165678456530">Description</p>
|
|
</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody><tr id="obs_11_0064__row16433162711504"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p66741317155112">authorization_code</p>
|
|
<p id="obs_11_0064__p4745172620131">or</p>
|
|
<p id="obs_11_0064__p12371530111313">file://authorization_code_file_url</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p154316502519">Mandatory</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p17425512259">The code for authorization</p>
|
|
<div class="note" id="obs_11_0064__note7117115211318"><span class="notetitle"> NOTE: </span><div class="notebody"><p id="obs_11_0064__p1511835281319">If the authorization code starts with <strong id="obs_11_0064__b06991041196">file://</strong>, the authorization code is obtained from a local file.</p>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row756944516535"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p85701245145318">file_or_folder_url</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p457314555313">Mandatory for downloading an object</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p4573114555313">The local file/folder path</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row195751145115315"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p1576945115318">folder_url</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p75772453537">Mandatory for downloading objects in a batch</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p12579194519531">The local folder path</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row1584114513535"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p17585144585310">key</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p121441934319">Mandatory for downloading an object (additional parameter)</p>
|
|
<p id="obs_11_0064__p19201728661">Optional for downloading objects in a batch</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p0588134575318">The name of the object to be downloaded, or the name prefix of the objects to be downloaded in batches</p>
|
|
<p id="obs_11_0064__p10591154565315">This parameter cannot be left blank when downloading an object. The saving and naming rules are as follows:</p>
|
|
<ul id="obs_11_0064__ul105928456532"><li id="obs_11_0064__li18704181916135">If this parameter specifies a file or folder path that does not exist, the tool checks whether the value ends with a slash (/) or backslash (\). If yes, a folder is created based on the path, and the object is downloaded to this newly created directory.</li><li id="obs_11_0064__li1230573911153">If this parameter specifies a file or folder path that does not exist and the value does not end with a slash (/) or backslash (\), the object is downloaded to your local PC with the value of the parameter as the file name.</li><li id="obs_11_0064__li4953132119137">If this parameter specifies an existing file, the object is downloaded to your local PC overwriting the existing file, with the value of the parameter as the file name.</li><li id="obs_11_0064__li1759284518535">If this parameter specifies an existing folder, the object is downloaded to the directory specified by <strong id="obs_11_0064__b18142520175817">file_or_folder_url</strong> with the object name as the file name.</li></ul>
|
|
<p id="obs_11_0064__p115612190125">During batch download, the saving rules are as follows:</p>
|
|
<ul id="obs_11_0064__ul15158191991211"><li id="obs_11_0064__li206451343181313">If this parameter is left blank, all objects in the authorized path specified in the authorization code are downloaded to the folder specified by <strong id="obs_11_0064__b1387123715161">folder_url</strong>.</li><li id="obs_11_0064__li171587195121">If this parameter is configured, objects whose name prefix is the configured value in the bucket are downloaded to the directory specified by <strong id="obs_11_0064__b202481059123017">folder_url</strong>.</li></ul>
|
|
<div class="note" id="obs_11_0064__note48056955718"><span class="notetitle"> NOTE: </span><div class="notebody"><ul id="obs_11_0064__ul54182557214"><li id="obs_11_0064__li1439119165515">If this parameter is specified, objects starting with this prefix are listed.</li><li id="obs_11_0064__li104859352371">If this parameter is configured but the <strong id="obs_11_0064__b25692434515">flat</strong> parameter is not configured when downloading objects in a batch, the name of the downloaded file contains the name prefix of the parent object. If <strong id="obs_11_0064__b80195614562">flat</strong> is configured, then the name of the downloaded file does not contain the name prefix of the parent object.</li></ul>
|
|
</div></div>
|
|
<div class="notice" id="obs_11_0064__note165161913165719"><span class="noticetitle"> NOTICE: </span><div class="noticebody"><p id="obs_11_0064__p1951661312576">During batch download, if the <strong id="obs_11_0064__b123561327141917">flat</strong> option is selected and the object name prefix is empty or does not end with a slash (/) during authorization code creation, the downloaded object list may be empty.</p>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row185692418511"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p1878833185111">ac</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p235543012513">Optional (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p183551330185117">The access code</p>
|
|
<div class="note" id="obs_11_0064__note65111626111415"><span class="notetitle"> NOTE: </span><div class="notebody"><ul id="obs_11_0064__ul206431628162318"><li id="obs_11_0064__li206439288237">If no access code is specified using this parameter, obsutil tool prompts you to enter the access code in interactive mode.</li><li id="obs_11_0064__li8644628102320">An access code is a six-digit string.</li></ul>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row346718210614"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p96521245195311">r</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p7654154512534">Mandatory for downloading objects in batches (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p206552045145317">Copies objects in batches based on a specified object name prefix.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row1314444315116"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p123051451513">fr</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p113071451811">Optional for downloading an object (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p73101351816">Generates an operation result file when downloading an object.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row20942144811418"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p1633845116148">flat</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p43401151111418">Optional for downloading objects in batches (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p2343205119145">The name prefix of the parent object is excluded when downloading objects in a batch.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row1163113812718"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p276284012715">tempFileDir</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p122055912103">Optional (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p1476264014710">The directory for storing temporary files during multipart download. The default value is the value of <strong id="obs_11_0064__b764136103815">defaultTempFileDir</strong> in the configuration file.</p>
|
|
<div class="note" id="obs_11_0064__note18655347142618"><span class="notetitle"> NOTE: </span><div class="notebody"><ul id="obs_11_0064__ul15994748142619"><li id="obs_11_0064__li55491537191019">If this parameter is left blank and the <strong id="obs_11_0064__b1866114104168">defaultTempFileDir</strong> parameter in the configuration file is also left blank, temporary files generated during multipart download are saved in the directory where to-be-downloaded files are located and end with the suffix of <strong id="obs_11_0064__b8662171081617">.obs.temp</strong>.</li><li id="obs_11_0064__li49941648132611">Temporary files generated during multipart download are stored in this directory. Therefore, ensure that the user who executes obsutil has the write permission on the path.</li><li id="obs_11_0064__li999594822612">The available space of the partition where the path is located must be greater than the size of the objects to be downloaded.</li></ul>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row1525855205616"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p1537517155414">dryRun</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p13376216548">Optional (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p1137981175411">Conducts a dry run.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row35998457538"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p206001459530">u</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p10601174595317">Optional (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p1260204518534">Indicates incremental download. If this parameter is set, each object can be downloaded only when it does not exist in the local path, its size is different from the namesake one in the local path, or it has the latest modification time.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row9603194595311"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p1605745105311">vlength</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p12605114512534">Optional (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p1660724595316">Checks whether the sizes of the local files are the same as those of the objects in the bucket after the download is complete.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row360812456535"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p136091945105315">vmd5</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p461011452539">Optional (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p19611745185310">Checks whether MD5 values of the local files are the same as those of the objects in the bucket after the download is complete.</p>
|
|
<div class="note" id="obs_11_0064__note2303131110278"><span class="notetitle"> NOTE: </span><div class="notebody"><p id="obs_11_0064__p12303311112719">Objects in the bucket must contain metadata <strong id="obs_11_0064__b262077113412">x-obs-meta-md5chksum</strong>, or MD5 verification will be skipped.</p>
|
|
</div></div>
|
|
<div class="caution" id="obs_11_0064__note183475244419"><span class="cautiontitle"> CAUTION: </span><div class="cautionbody"><p id="obs_11_0064__p98341052114418">If your object needs encryption, do not use this parameter.</p>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row36131445115310"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p14613194514535">p</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p15615164515317">Optional (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p1161744513534">The maximum number of concurrent multipart download tasks when downloading an object. The default value is the value of <strong id="obs_11_0064__b636105782416">defaultParallels</strong> in the configuration file.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row14617144520537"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p17619545185314">threshold</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p9620645185311">Optional (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p262174575315">The threshold for enabling multipart download, in bytes. The default value is the value of <strong id="obs_11_0064__b46731427193815">defaultBigfileThreshold</strong> in the configuration file.</p>
|
|
<div class="note" id="obs_11_0064__note94444118613"><span class="notetitle"> NOTE: </span><div class="notebody"><ul id="obs_11_0064__ul182059695115"><li id="obs_11_0064__li1320515655118">If the size of the object to be downloaded is smaller than the threshold, download the object directly. If not, a multipart download is required.</li><li id="obs_11_0064__li1651511123516">If you download an object directly, no part record is generated, and resumable transmission is not supported.</li><li id="obs_11_0064__li1184794414422">This parameter value can contain a unit, for example, <strong id="obs_11_0064__b562941025020">1MB</strong> (indicating 1,048,576 bytes).</li></ul>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row1363634595315"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p3637164545318">ps</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p1264164517532">Optional (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p10641184516531">The size of each part in a multipart download task, in bytes. The default value is the value of <strong id="obs_11_0064__b0520113153817">defaultPartSize</strong> in the configuration file.</p>
|
|
<div class="note" id="obs_11_0064__note1175045524310"><span class="notetitle"> NOTE: </span><div class="notebody"><ul id="obs_11_0064__ul230316596421"><li id="obs_11_0064__li153031459184220">This parameter value can contain a unit, for example, <strong id="obs_11_0064__b164931755507">1MB</strong> (indicating 1,048,576 bytes).</li><li id="obs_11_0064__li144561220153810">The parameter can be set to <strong id="obs_11_0064__b65982422414">auto</strong>. In this case, obsutil automatically sets the part size for each multipart task based on the source object size.</li></ul>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row196461145155314"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p1764874511530">cpd</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p206482455537">Optional (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p1965018458536">The folder where the part records reside. The default value is <strong id="obs_11_0064__b140163717387">.obsutil_checkpoint</strong>, the subfolder in the home directory of the user who executes obsutil commands.</p>
|
|
<div class="note" id="obs_11_0064__note519835512711"><span class="notetitle"> NOTE: </span><div class="notebody"><p id="obs_11_0064__p118866577266">A part record is generated during a multipart download and saved to the <strong id="obs_11_0064__b17221185615478">down</strong> subfolder. After the download succeeds, its part record is deleted automatically. If the download fails or is suspended, the system attempts to resume the task according to its part record when you perform the download the next time.</p>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row5655184520536"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p56577450535">f</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p13658645125314">Optional for downloading objects in a batch (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p566014515533">Runs in force mode.</p>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row1566014510533"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p3662204585313">j</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p19305175612615">Optional for downloading objects in a batch (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p17665114555311">The maximum number of concurrent tasks for downloading objects in a batch. The default value is the value of <strong id="obs_11_0064__b427184219388">defaultJobs</strong> in the configuration file.</p>
|
|
<div class="note" id="obs_11_0064__note891964620819"><span class="notetitle"> NOTE: </span><div class="notebody"><p id="obs_11_0064__p1091964618820">The value is ensured to be greater than or equal to 1.</p>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row109762261097"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p156173113915">exclude</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p1930885652611">Optional for downloading objects in a batch (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p16666614131519">The matching patterns of source objects that are excluded, for example: <strong id="obs_11_0064__b15305114610383">*.txt</strong></p>
|
|
<div class="note" id="obs_11_0064__note145284716208"><span class="notetitle"> NOTE: </span><div class="notebody"><ul id="obs_11_0064__ul05604713204"><li id="obs_11_0064__li14580477208">The asterisk (*) represents any group of characters, and the question mark (?) represents any single character. For instance, <strong id="obs_11_0064__b17220124561010">abc*.txt</strong> indicates any file whose name starts with <strong id="obs_11_0064__b1922154518107">abc</strong> and ends with <strong id="obs_11_0064__b1122313450103">.txt</strong>.</li><li id="obs_11_0064__li10293181913349">You can use <strong id="obs_11_0064__b1734764681019">\*</strong> to represent <strong id="obs_11_0064__b834814619103">*</strong> and <strong id="obs_11_0064__b19349646101016">\?</strong> to represent <strong id="obs_11_0064__b83501467102">?</strong>.</li><li id="obs_11_0064__li20603473203">If the name of the object to be downloaded matches the value of this parameter, the object is skipped.</li></ul>
|
|
</div></div>
|
|
<div class="notice" id="obs_11_0064__note179117549207"><span class="noticetitle"> NOTICE: </span><div class="noticebody"><ul id="obs_11_0064__ul877892116516"><li id="obs_11_0064__li1517310321518">You are advised to use quotation marks for the matching pattern to prevent special characters from being escaped by the OS and leading to unexpected results. Use single quotation marks for Linux or macOS and double quotation marks for Windows.</li><li id="obs_11_0064__li1371214438918">The matching pattern applies to the absolute path of an object, including the object name prefix and object name starting from the root directory. For example, if the path of an object in the bucket is <strong id="obs_11_0064__b36591141163013">obs://bucket/src1/src2/test.txt</strong>, then the absolute path of the object is <strong id="obs_11_0064__b66591141183017">src1/src2/test.txt</strong>.</li><li id="obs_11_0064__li1148165015513">This matching pattern applies only to objects whose names do not end with a slash (/).</li><li id="obs_11_0064__li1444644463920">Multiple <strong id="obs_11_0064__b1236834965915">exclude</strong> parameters can be specified, for example, <strong id="obs_11_0064__b8373174955910">-exclude=*.xxx -exclude=*.xxx</strong>.</li></ul>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row20666154513530"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p186661845145315">include</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p966784516533">Optional for downloading objects in a batch (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p37071730153119">The matching patterns of source objects that are included, for example: <strong id="obs_11_0064__b18688750163814">*.jpg</strong></p>
|
|
<div class="note" id="obs_11_0064__note195168716220"><span class="notetitle"> NOTE: </span><div class="notebody"><ul id="obs_11_0064__ul752013715229"><li id="obs_11_0064__li135211772221">The asterisk (*) represents any group of characters, and the question mark (?) represents any single character.</li><li id="obs_11_0064__li151801324163419">You can use <strong id="obs_11_0064__b146715119284">\*</strong> to represent <strong id="obs_11_0064__b6688119287">*</strong> and <strong id="obs_11_0064__b56931182812">\?</strong> to represent <strong id="obs_11_0064__b1870151117289">?</strong>.</li><li id="obs_11_0064__li201739642420">Only after identifying that the name of the file to be downloaded does not match the value of <strong id="obs_11_0064__b1874141931111">exclude</strong>, the system checks whether the file name matches the value of this parameter. If yes, the file is downloaded. If not, the file is skipped.</li></ul>
|
|
</div></div>
|
|
<div class="notice" id="obs_11_0064__note9270217202212"><span class="noticetitle"> NOTICE: </span><div class="noticebody"><ul id="obs_11_0064__ul1329413124584"><li id="obs_11_0064__li14294512115812">You are advised to use quotation marks for the matching pattern to prevent special characters from being escaped by the OS and leading to unexpected results. Use single quotation marks for Linux or macOS and double quotation marks for Windows.</li><li id="obs_11_0064__li5744647391">The matching pattern applies to the absolute path of an object, including the object name prefix and object name starting from the root directory. For example, if the path of an object in the bucket is <strong id="obs_11_0064__b6297623298">obs://bucket/src1/src2/test.txt</strong>, then the absolute path of the object is <strong id="obs_11_0064__b72989213296">src1/src2/test.txt</strong>.</li><li id="obs_11_0064__li19166484914">This matching pattern applies only to objects whose names do not end with a slash (/).</li><li id="obs_11_0064__li198622050183915">Multiple <strong id="obs_11_0064__b116155014591">include</strong> parameters can be specified, for example, <strong id="obs_11_0064__b156155018595">-include=*.xxx -include=*.xxx</strong>.</li></ul>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row949610111431"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p496314014481">timeRange</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p1664510223494">Optional for downloading objects in a batch (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p16963940134813">The time range matching pattern when downloading objects. Only objects whose latest modification time is within the configured time range are downloaded.</p>
|
|
<p id="obs_11_0064__p338461155315">This pattern has a lower priority than the object matching patterns (<strong id="obs_11_0064__b8524185317313">exclude</strong>/<strong id="obs_11_0064__b85251153539">include</strong>). That is, the time range matching pattern is executed after the configured object matching patterns.</p>
|
|
<div class="note" id="obs_11_0064__note8766915165919"><span class="notetitle"> NOTE: </span><div class="notebody"><ul id="obs_11_0064__ul19272430145915"><li id="obs_11_0064__li12731730115918">The matching time range is represented in <em id="obs_11_0064__i1297864783014">time1</em><strong id="obs_11_0064__b997934713304">-</strong><em id="obs_11_0064__i298074703013">time2</em>, where <em id="obs_11_0064__i109803471301">time1</em> must be earlier than or the same as <em id="obs_11_0064__i29811847203013">time2</em>. The time format is <em id="obs_11_0064__i3982547153012">yyyyMMddHHmmss</em>.</li><li id="obs_11_0064__li32731530185916">Automatic formatting is supported. For example, yyyyMMdd is equivalent to yyyyMMdd000000, and yyyyMM is equivalent to yyyyMM01000000.</li><li id="obs_11_0064__li5185481610">If this parameter is set to <strong id="obs_11_0064__b5889165023014">*-</strong><em id="obs_11_0064__i2890650113017">time2</em>, all files whose latest modification time is earlier than <em id="obs_11_0064__i68911450133018">time2</em> are matched. If it is set to <em id="obs_11_0064__i489205019306">time1</em><strong id="obs_11_0064__b1089215093014">-*</strong>, all files whose latest modification time is later than <em id="obs_11_0064__i98935500303">time1</em> are matched.</li></ul>
|
|
</div></div>
|
|
<div class="notice" id="obs_11_0064__note1078981817591"><span class="noticetitle"> NOTICE: </span><div class="noticebody"><ul id="obs_11_0064__ul881073612597"><li id="obs_11_0064__li1740024105917">Time in the matching pattern is the UTC time.</li><li id="obs_11_0064__li58105368598">This matching pattern applies only to objects whose names do not end with a slash (/).</li></ul>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row1116705416719"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p10122175516">mf</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p1562018121550">Optional (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p31226718512">Indicates that the name matching pattern (<strong id="obs_11_0064__b1423547113114">include</strong> or <strong id="obs_11_0064__b123616753117">exclude</strong>) and the time matching pattern (<strong id="obs_11_0064__b3237973318">timeRange</strong>) also take effect on objects whose names end with a slash (/).</p>
|
|
<p id="obs_11_0064__p15797105118514"></p>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row109093549288"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p143226572287">o</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p232405732811">Optional (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__p1632615718282">The folder that stores the result files. After the command is executed, result files (possibly success, failure, and warning files) will be created in the specified folder. The default value is <strong id="obs_11_0064__b172181520151212">.obsutil_output</strong>, a subfolder in the user's home directory where obsutil commands are executed.</p>
|
|
<div class="note" id="obs_11_0064__note1416817409247"><span class="notetitle"> NOTE: </span><div class="notebody"><ul id="obs_11_0064__ul101190347408"><li id="obs_11_0064__li111993418408">A result file should be named as follows: <strong id="obs_11_0064__b162206244343">share-cp_{succeed | failed | warning}_report_</strong><em id="obs_11_0064__i182214245342">time</em><strong id="obs_11_0064__b14221142473413">_TaskId.txt</strong>.</li><li id="obs_11_0064__li412103664016">By default, the maximum size of a single result file is 30 MB and the maximum number of result files that can be retained is 1,024. You can set the maximum size and number by configuring <strong id="obs_11_0064__b499664815463">recordMaxLogSize</strong> and <strong id="obs_11_0064__b59961948194618">recordBackups</strong> in the configuration file.</li><li id="obs_11_0064__li17449916048">If there are multiple folders and files and you need to confirm the details of a failed task, refer to the failure result file <strong id="obs_11_0064__obs_11_0013_b5396121718320">cp_failed_report_</strong><em id="obs_11_0064__obs_11_0013_i1639621714325">time</em><strong id="obs_11_0064__obs_11_0013_b1739631753215">_</strong><em id="obs_11_0064__obs_11_0013_i203979172328">TaskId</em><strong id="obs_11_0064__obs_11_0013_b1639718176326">.txt</strong> in the result folder and the <a href="obs_11_0056.html">log files</a> in the log path.</li></ul>
|
|
</div></div>
|
|
</td>
|
|
</tr>
|
|
<tr id="obs_11_0064__row1920762633614"><td class="cellrowborder" valign="top" width="17.5%" headers="mcps1.3.4.2.1.4.1.1 "><p id="obs_11_0064__p153951131317">config</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="20.59%" headers="mcps1.3.4.2.1.4.1.2 "><p id="obs_11_0064__p12395135316">Optional (additional parameter)</p>
|
|
</td>
|
|
<td class="cellrowborder" valign="top" width="61.91%" headers="mcps1.3.4.2.1.4.1.3 "><p id="obs_11_0064__obs_11_0008_p1750111452317">The user-defined configuration file for executing the current command. For details about parameters that can be configured, see <a href="obs_11_0035.html">Configuration Parameters</a>.</p>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
</div>
|
|
<div class="section" id="obs_11_0064__section6926520122416"><h4 class="sectiontitle">Response</h4><p id="obs_11_0064__p21251255183018">Refer to <a href="obs_11_0013.html#obs_11_0013__section6926520122416">Response</a> for uploading an object.</p>
|
|
</div>
|
|
</div>
|
|
<div>
|
|
<div class="familylinks">
|
|
<div class="parentlink"><strong>Parent topic:</strong> <a href="obs_11_0012.html">Object Commands</a></div>
|
|
</div>
|
|
</div>
|
|
|