4 title: "Downloading data"
7 Copyright (C) The Arvados Authors. All rights reserved.
9 SPDX-License-Identifier: CC-BY-SA-3.0
12 Arvados Data collections can be downloaded using either the arv commands or using Workbench.
14 # "*Download using Workbench*":#download-using-workbench
15 # "*Creating a special download URL for a collection*":#download-shared-collection
16 # "*Download using command line tools*":#download-using-arv
18 h2(#download-using-workbench). Download using Workbench
20 You can also download Arvados data collections using the Workbench.
22 When you visit a project in Workbench (for instance, the <i class="fa fa-fw fa-folder"></i> *Home Projects* or any projects under it), the collections will show up on the project details page, with "_Data collection_" in the *Type* column.
24 Clicking on a collection will bring you to its details page. There, the lower panel acts like a file manager where you can navigate to or search for files, select them for actions, and download them.
26 To download a file, simply click on the file, or bring up the context menu using right-click or the triple-dot button on its row, and then select the menu item *Download*.
28 h2(#download-shared-collection). Creating a special download URL for a collection
30 To share a collection with users that do not have an account on your Arvados cluster, locate the collection and then go to the *Sharing settings* dialog box as described above. There, select the *SHARING URLS* tab.
32 You can then generate a new sharing URL using the <span class="btn btn-sm btn-primary">CREATE SHARING URL</span> button, with the option to set an expiration time for the URL. You can then copy the URL to the clipboard for sharing with others. To revoke (that is, delete) a sharing URL, click on the cross icon beside it.
34 <figure>!{width: 80%}{{ site.baseurl }}/images/sharing-collection-url.png!<figcaption>_The_ *SHARING URLS* _tab in the_ *Sharing settings* _dialog box, showing the created URL with an expiration time_</figcaption></figure>
36 Any user with the sharing URL can download this collection by simply accessing this URL using browser. It will present a downloadable version of the collection as shown below.
38 !{display: block;margin-left: 25px;margin-right: auto;border:1px solid lightgray;}{{ site.baseurl }}/images/download-shared-collection.png!
40 When a collection is being shared by URL, in the *WITH USERS/GROUS* tab of *Sharing settings*, the following message will appear if *General access* is Private: _Although there aren't specific permissions set, this is publicly accessible via Sharing URL(s)._
42 * *Note:* Sharing by URL is specific to collections. Projects or individual files cannot be shared in this way.
44 h2(#download-using-arv). Download using command line tools
46 {% include 'tutorial_expectations' %}
48 You can download Arvados data collections using the command line tools @arv-ls@ and @arv-get@.
50 Use @arv-ls@ to view the contents of a collection:
53 <pre><code>~$ <span class="userinput">arv-ls ae480c5099b81e17267b7445e35b4bc7+180</span>
54 ./HWI-ST1027_129_D0THKACXX.1_1.fastq
55 ./HWI-ST1027_129_D0THKACXX.1_2.fastq
58 Use @-s@ to print file sizes, in kilobytes, rounded up:
61 <pre><code>~$ <span class="userinput">arv-ls -s ae480c5099b81e17267b7445e35b4bc7+180</span>
62 12258 ./HWI-ST1027_129_D0THKACXX.1_1.fastq
63 12258 ./HWI-ST1027_129_D0THKACXX.1_2.fastq
67 Use @arv-get@ to download the contents of a collection and place it in the directory specified in the second argument (in this example, @.@ for the current directory):
70 <pre><code>~$ <span class="userinput">$ arv-get ae480c5099b81e17267b7445e35b4bc7+180/ .</span>
71 23 MiB / 23 MiB 100.0%
72 ~$ <span class="userinput">ls</span>
73 HWI-ST1027_129_D0THKACXX.1_1.fastq HWI-ST1027_129_D0THKACXX.1_2.fastq
77 You can also download individual files:
80 <pre><code>~$ <span class="userinput">arv-get ae480c5099b81e17267b7445e35b4bc7+180/HWI-ST1027_129_D0THKACXX.1_1.fastq .</span>
81 11 MiB / 11 MiB 100.0%
85 h3. Federated downloads
87 If your cluster is "configured to be part of a federation":{{site.baseurl}}/admin/federation.html you can also download collections hosted on other clusters (with appropriate permissions).
89 If you request a collection by portable data hash, it will first search the home cluster, then search federated clusters.
91 You may also request a collection by UUID. In this case, it will contact the cluster named in the UUID prefix (in this example, @zzzzz@).
94 <pre><code>~$ <span class="userinput">arv-get zzzzz-4zz18-fw6dnjxtkvzdewt/ .</span>