{"id":368,"date":"2021-08-03T23:35:55","date_gmt":"2021-08-03T23:35:55","guid":{"rendered":"https:\/\/mri.sbollmann.net\/?p=368"},"modified":"2021-08-03T23:59:48","modified_gmt":"2021-08-03T23:59:48","slug":"cloudstor-and-high-performance-computing-systems","status":"publish","type":"post","link":"https:\/\/mri.sbollmann.net\/index.php\/2021\/08\/03\/cloudstor-and-high-performance-computing-systems\/","title":{"rendered":"CloudStor and High Performance Computing Systems"},"content":{"rendered":"\n<p>When using a High Performance Computing System you also might have run into the problem of how to get data in and out of this system. <\/p>\n\n\n\n<p>We are very lucky in Australia to have <a rel=\"noreferrer noopener\" href=\"https:\/\/www.aarnet.edu.au\/network-and-services\/cloud-services\/cloudstor\" target=\"_blank\">CloudStor<\/a>, which is Aarnets hosted OwnCloud version with 1TB of storage available for every researcher and we can use it to move data between different computing systems.<\/p>\n\n\n\n<p>The only problem is that on an HPC you can\u2019t open a browser and you also can\u2019t install the owncloud client \u2013 so what other options exist?<\/p>\n\n\n\n<p>There is a wonderful tool called <a rel=\"noreferrer noopener\" href=\"https:\/\/rclone.org\" target=\"_blank\">rclone<\/a>, which interfaces with all cloud storage providers out there \ud83d\ude42<\/p>\n\n\n\n<p>You can find a detailed description how to <a rel=\"noreferrer noopener\" href=\"https:\/\/support.aarnet.edu.au\/hc\/en-us\/articles\/115007168507-Can-I-use-the-command-line-or-WebDav-\" target=\"_blank\">connect rclone to CloudStor<\/a>, so let&#8217;s go through this step by step and set it up together:<\/p>\n\n\n\n<p>Connect to your favorite HPC and install rclone on there. The official install instructions for rclone are a bit misleading as we will not be able to run as sudo or use their install script without sudo or install rpm or apt packages &#8211; so if you try any of the official instructions on an HPC you will see errors similar to this:<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"288\" src=\"https:\/\/mri.sbollmann.net\/wp-content\/uploads\/2021\/08\/image-5-1024x288.png\" alt=\"\" class=\"wp-image-369\" srcset=\"https:\/\/mri.sbollmann.net\/wp-content\/uploads\/2021\/08\/image-5-1024x288.png 1024w, https:\/\/mri.sbollmann.net\/wp-content\/uploads\/2021\/08\/image-5-300x84.png 300w, https:\/\/mri.sbollmann.net\/wp-content\/uploads\/2021\/08\/image-5-768x216.png 768w, https:\/\/mri.sbollmann.net\/wp-content\/uploads\/2021\/08\/image-5-1536x432.png 1536w, https:\/\/mri.sbollmann.net\/wp-content\/uploads\/2021\/08\/image-5-2048x576.png 2048w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Let&#8217;s install it in our home directory \ud83d\ude42<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>cd\nmkdir tools\ncd tools\nwget https:\/\/downloads.rclone.org\/rclone-current-linux-amd64.zip \nunzip rclone-current-linux-amd64.zip \nrm rclone-current-linux-amd64.zip \ncd rclone-*\necho \"export PATH=\\$PATH:$PWD\" >> ~\/.bashrc\nsource ~\/.bashrc\nrclone config<\/code><\/pre>\n\n\n\n<p>Create a new remote: n<\/p>\n\n\n\n<p>Provide a name for the remote: CloudStor<\/p>\n\n\n\n<p>For the &#8220;Storage&#8221; option choose: webdav<\/p>\n\n\n\n<p>As &#8220;url&#8221; set: https:\/\/cloudstor.aarnet.edu.au\/plus\/remote.php\/webdav\/<\/p>\n\n\n\n<p>As &#8220;vendor&#8221; set OwnCloud: 2<\/p>\n\n\n\n<p>Set your CloudStor username <a href=\"https:\/\/cloudstor.aarnet.edu.au\/plus\/settings\/personal?sectionid=security\" target=\"_blank\" rel=\"noreferrer noopener\">after generating an access token<\/a>: <\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img loading=\"lazy\" decoding=\"async\" width=\"1024\" height=\"434\" src=\"https:\/\/mri.sbollmann.net\/wp-content\/uploads\/2021\/08\/image-1024x434.png\" alt=\"\" class=\"wp-image-362\" srcset=\"https:\/\/mri.sbollmann.net\/wp-content\/uploads\/2021\/08\/image-1024x434.png 1024w, https:\/\/mri.sbollmann.net\/wp-content\/uploads\/2021\/08\/image-300x127.png 300w, https:\/\/mri.sbollmann.net\/wp-content\/uploads\/2021\/08\/image-768x325.png 768w, https:\/\/mri.sbollmann.net\/wp-content\/uploads\/2021\/08\/image.png 1341w\" sizes=\"auto, (max-width: 1024px) 100vw, 1024px\" \/><\/figure>\n\n\n\n<p>Choose to type in your own password: y<\/p>\n\n\n\n<p>Enter the Password \/ Token from the CloudStor App passwords page and confirm it again:<\/p>\n\n\n\n<p>Leave blank the bearer_token: &lt;hit Enter&gt;<\/p>\n\n\n\n<p>No advanced config necessary:  &lt;hit Enter&gt; <\/p>\n\n\n\n<p>accept the configuration:  &lt;hit Enter&gt; <\/p>\n\n\n\n<p>Quit the config: q<\/p>\n\n\n\n<p><\/p>\n\n\n\n<p>Now we can <strong>download <\/strong>data to the HPC easily:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>rclone copy --progress --transfers 8 CloudStor:\/raw-data-for-science-paper .<\/code><\/pre>\n\n\n\n<p>or <strong>upload <\/strong>data to CloudStor:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>rclone copy --progress --transfers 8 . CloudStor:\/hpc-data-processed<\/code><\/pre>\n\n\n\n<p>If you need to upload lots of data, there is a very nice wrapper script from AARNET that tweaks a few settings and checks if all files have been transferred: <strong><a href=\"https:\/\/github.com\/AARNet\/copyToCloudstor\">https:\/\/github.com\/AARNet\/copyToCloudstor<\/a><\/strong><\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>git clone https:\/\/github.com\/AARNet\/copyToCloudstor \ncd copyToCloudstor\n.\/copyToCloudstor.sh ~\/scratch\/data\/ CloudStor:\/all-my-important-HPC-data-for-nature-paper\n<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>When using a High Performance Computing System you also might have run into the problem of how to get data in and out of this system. We are very lucky in Australia to have CloudStor, which is Aarnets hosted OwnCloud version with 1TB of storage available for every researcher and [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":369,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[30,28,31,26],"tags":[],"class_list":["post-368","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-cloudstor","category-data-management","category-high-performance-computing","category-tutorials"],"jetpack_featured_media_url":"https:\/\/mri.sbollmann.net\/wp-content\/uploads\/2021\/08\/image-5.png","_links":{"self":[{"href":"https:\/\/mri.sbollmann.net\/index.php\/wp-json\/wp\/v2\/posts\/368","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/mri.sbollmann.net\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/mri.sbollmann.net\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/mri.sbollmann.net\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/mri.sbollmann.net\/index.php\/wp-json\/wp\/v2\/comments?post=368"}],"version-history":[{"count":8,"href":"https:\/\/mri.sbollmann.net\/index.php\/wp-json\/wp\/v2\/posts\/368\/revisions"}],"predecessor-version":[{"id":380,"href":"https:\/\/mri.sbollmann.net\/index.php\/wp-json\/wp\/v2\/posts\/368\/revisions\/380"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/mri.sbollmann.net\/index.php\/wp-json\/wp\/v2\/media\/369"}],"wp:attachment":[{"href":"https:\/\/mri.sbollmann.net\/index.php\/wp-json\/wp\/v2\/media?parent=368"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/mri.sbollmann.net\/index.php\/wp-json\/wp\/v2\/categories?post=368"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/mri.sbollmann.net\/index.php\/wp-json\/wp\/v2\/tags?post=368"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}