Nick Craig-WoodVersion v1.52.06882aef6 years agoHistory
21281 lines · 1.1 MB · HTML
RawDownload
<!DOCTYPE html><html xmlns="http://www.w3.org/1999/xhtml" lang="" xml:lang=""><head>  <meta charset="utf-8" />  <meta name="generator" content="pandoc" />  <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />  <meta name="author" content="Nick Craig-Wood" />  <meta name="dcterms.date" content="2020-05-27" />  <title>rclone(1) User Manual</title>  <style type="text/css">      code{white-space: pre-wrap;}      span.smallcaps{font-variant: small-caps;}      span.underline{text-decoration: underline;}      div.column{display: inline-block; vertical-align: top; width: 50%;}  </style></head><body><header id="title-block-header"><h1 class="title">rclone(1) User Manual</h1><p class="author">Nick Craig-Wood</p><p class="date">May 27, 2020</p></header><h1 id="rclone-syncs-your-files-to-cloud-storage">Rclone syncs your files to cloud storage</h1><p><img width="50%" src="https://rclone.org/img/logo_on_light__horizontal_color.svg" alt="rclone logo" style="float:right; padding: 5px;" ></p><ul><li><a href="#about">About rclone</a></li><li><a href="#what">What can rclone do for you</a></li><li><a href="#features">What features does rclone have</a></li><li><a href="#providers">What providers does rclone support</a></li><li><a href="https://rclone.org/downloads/">Download</a></li><li><a href="https://rclone.org/install/">Install</a></li><li><a href="https://rclone.org/donate/">Donate.</a></li></ul><h2 id="about">About rclone</h2><p>Rclone is a command line program to manage files on cloud storage. It is a feature rich alternative to cloud vendors’ web storage interfaces. <a href="#providers">Over 40 cloud storage products</a> support rclone including S3 object stores, business &amp; consumer file storage services, as well as standard transfer protocols.</p><p>Rclone has powerful cloud equivalents to the unix commands rsync, cp, mv, mount, ls, ncdu, tree, rm, and cat. Rclone’s familiar syntax includes shell pipeline support, and <code>--dry-run</code> protection. It can be used at the command line, in scripts or via its <a href="/rc">API</a>.</p><p>Users have called rclone <em>“The Swiss army knife of cloud storage”</em> and <em>“Technology indistinguishable from magic”</em>.</p><p>Rclone really looks after your data. It preserves timestamps and verifies your data at all times. Transfers over limited bandwidth; intermittent connections, or subject to quota can be restarted, from the last good file transferred. You can <a href="https://rclone.org/commands/rclone_check/">check</a> the integrity of your files. Where possible, rclone employs server side transfers to minimise local bandwidth use and transfers from one provider to another without using your local disk.</p><p>Virtual backends wrap local and cloud file systems to apply <a href="https://rclone.org/crypt/">encryption</a>, <a href="https://rclone.org/cache/">caching</a>, <a href="https://rclone.org/chunker/">chunking</a> and <a href="https://rclone.org/union/">joining</a>.</p><p>Rclone can <a href="https://rclone.org/commands/rclone_mount/">mount</a> any local, cloud or virtual filesystem as a disk on Windows, macOS, linux and FreeBSD, and also serve these over <a href="https://rclone.org/commands/rclone_serve_sftp/">SFTP</a>, <a href="https://rclone.org/commands/rclone_serve_http/">HTTP</a>, <a href="https://rclone.org/commands/rclone_serve_webdav/">WebDAV</a>, <a href="https://rclone.org/commands/rclone_serve_ftp/">FTP</a> and <a href="https://rclone.org/commands/rclone_serve_dlna/">DLNA</a>.</p><p>Rclone is mature, open source software originally inspired by rsync and written in <a href="https://golang.org">Go</a>. The friendly support community are familiar with varied use cases. Official Ubuntu, Debian, Fedora, Brew and Chocolatey repos. include rclone. For the latest version <a href="https://rclone.org/downloads/">downloading from rclone.org</a> is recommended.</p><p>Rclone is widely used on Linux, Windows and Mac. Third party developers have built innovative backup, restore, GUI and business process solutions using the rclone command line or API.</p><p>Let rclone do the heavy lifting of communicating with cloud storage.</p><h2 id="what">What can rclone do for you</h2><p>Rclone can help you:</p><ul><li>Backup (and encrypt) files to cloud storage</li><li>Restore (and decrypt) files from cloud storage</li><li>Mirror cloud data to other cloud services or locally</li><li>Migrate data to cloud, or between cloud storage vendors</li><li>Mount multiple, encrypted, cached or diverse cloud storage as a disk</li><li>Analyse and account for data held on cloud storage using <a href="https://rclone.org/commands/rclone_lsf/">lsf</a>, <a href="https://rclone.org/commands/rclone_lsjson/">ljson</a>, <a href="https://rclone.org/commands/rclone_size/">size</a>, <a href="https://rclone.org/commands/rclone_ncdu/">ncdu</a></li><li><a href="https://rclone.org/union/">Union</a> file systems together to present multiple local and/or cloud file systems as one</li></ul><h2 id="features">Features</h2><ul><li>Transfers<ul><li>MD5, SHA1 hashes are checked at all times for file integrity</li><li>Timestamps are preserved on files</li><li>Operations can be restarted at any time</li><li>Can be to and from network, eg two different cloud providers</li><li>Can use multi-threaded downloads to local disk</li></ul></li><li><a href="https://rclone.org/commands/rclone_copy/">Copy</a> new or changed files to cloud storage</li><li><a href="https://rclone.org/commands/rclone_sync/">Sync</a> (one way) to make a directory identical</li><li><a href="https://rclone.org/commands/rclone_move/">Move</a> files to cloud storage deleting the local after verification</li><li><a href="https://rclone.org/commands/rclone_check/">Check</a> hashes and for missing/extra files</li><li><a href="https://rclone.org/commands/rclone_mount/">Mount</a> your cloud storage as a network disk</li><li><a href="https://rclone.org/commands/rclone_serve/">Serve</a> local or remote files over <a href="https://rclone.org/commands/rclone_serve_http/">HTTP</a>/<a href="https://rclone.org/commands/rclone_serve_webdav/">WebDav</a>/<a href="https://rclone.org/commands/rclone_serve_ftp/">FTP</a>/<a href="https://rclone.org/commands/rclone_serve_sftp/">SFTP</a>/<a href="https://rclone.org/commands/rclone_serve_dlna/">dlna</a></li><li>Experimental <a href="https://rclone.org/gui/">Web based GUI</a></li></ul><h2 id="providers">Supported providers</h2><p>(There are many other providers, built on standard protocols such as WebDAV or S3, that work out of the box.)</p><ul><li>1Fichier</li><li>Alibaba Cloud (Aliyun) Object Storage System (OSS)</li><li>Amazon Drive</li><li>Amazon S3</li><li>Backblaze B2</li><li>Box</li><li>Ceph</li><li>Citrix ShareFile</li><li>C14</li><li>DigitalOcean Spaces</li><li>Dreamhost</li><li>Dropbox</li><li>FTP</li><li>Google Cloud Storage</li><li>Google Drive</li><li>Google Photos</li><li>HTTP</li><li>Hubic</li><li>Jottacloud</li><li>IBM COS S3</li><li>Koofr</li><li>Mail.ru Cloud</li><li>Memset Memstore</li><li>Mega</li><li>Memory</li><li>Microsoft Azure Blob Storage</li><li>Microsoft OneDrive</li><li>Minio</li><li>Nextcloud</li><li>OVH</li><li>OpenDrive</li><li>OpenStack Swift</li><li>Oracle Cloud Storage</li><li>ownCloud</li><li>pCloud</li><li>premiumize.me</li><li>put.io</li><li>QingStor</li><li>Rackspace Cloud Files</li><li>rsync.net</li><li>Scaleway</li><li>Seafile</li><li>SFTP</li><li>StackPath</li><li>SugarSync</li><li>Tardigrade</li><li>Wasabi</li><li>WebDAV</li><li>Yandex Disk</li><li>The local filesystem</li></ul><p>Links</p><ul><li><a href="https://rclone.org/">Home page</a></li><li><a href="https://github.com/rclone/rclone">GitHub project page for source and bug tracker</a></li><li><a href="https://forum.rclone.org">Rclone Forum</a></li><li><a href="https://rclone.org/downloads/">Downloads</a></li></ul><h1 id="install">Install</h1><p>Rclone is a Go program and comes as a single binary file.</p><h2 id="quickstart">Quickstart</h2><ul><li><a href="https://rclone.org/downloads/">Download</a> the relevant binary.</li><li>Extract the <code>rclone</code> or <code>rclone.exe</code> binary from the archive</li><li>Run <code>rclone config</code> to setup. See <a href="https://rclone.org/docs/">rclone config docs</a> for more details.</li></ul><p>See below for some expanded Linux / macOS instructions.</p><p>See the <a href="https://rclone.org/docs/#usage">Usage section</a> of the docs for how to use rclone, or run <code>rclone -h</code>.</p><h2 id="script-installation">Script installation</h2><p>To install rclone on Linux/macOS/BSD systems, run:</p><pre><code>curl https://rclone.org/install.sh | sudo bash</code></pre><p>For beta installation, run:</p><pre><code>curl https://rclone.org/install.sh | sudo bash -s beta</code></pre><p>Note that this script checks the version of rclone installed first and won’t re-download if not needed.</p><h2 id="linux-installation-from-precompiled-binary">Linux installation from precompiled binary</h2><p>Fetch and unpack</p><pre><code>curl -O https://downloads.rclone.org/rclone-current-linux-amd64.zipunzip rclone-current-linux-amd64.zipcd rclone-*-linux-amd64</code></pre><p>Copy binary file</p><pre><code>sudo cp rclone /usr/bin/sudo chown root:root /usr/bin/rclonesudo chmod 755 /usr/bin/rclone</code></pre><p>Install manpage</p><pre><code>sudo mkdir -p /usr/local/share/man/man1sudo cp rclone.1 /usr/local/share/man/man1/sudo mandb </code></pre><p>Run <code>rclone config</code> to setup. See <a href="https://rclone.org/docs/">rclone config docs</a> for more details.</p><pre><code>rclone config</code></pre><h2 id="macos-installation-with-brew">macOS installation with brew</h2><pre><code>brew install rclone</code></pre><h2 id="macos-installation-from-precompiled-binary-using-curl">macOS installation from precompiled binary, using curl</h2><p>To avoid problems with macOS gatekeeper enforcing the binary to be signed and notarized it is enough to download with <code>curl</code>.</p><p>Download the latest version of rclone.</p><pre><code>cd &amp;&amp; curl -O https://downloads.rclone.org/rclone-current-osx-amd64.zip</code></pre><p>Unzip the download and cd to the extracted folder.</p><pre><code>unzip -a rclone-current-osx-amd64.zip &amp;&amp; cd rclone-*-osx-amd64</code></pre><p>Move rclone to your $PATH. You will be prompted for your password.</p><pre><code>sudo mkdir -p /usr/local/binsudo mv rclone /usr/local/bin/</code></pre><p>(the <code>mkdir</code> command is safe to run, even if the directory already exists).</p><p>Remove the leftover files.</p><pre><code>cd .. &amp;&amp; rm -rf rclone-*-osx-amd64 rclone-current-osx-amd64.zip</code></pre><p>Run <code>rclone config</code> to setup. See <a href="https://rclone.org/docs/">rclone config docs</a> for more details.</p><pre><code>rclone config</code></pre><h2 id="macos-installation-from-precompiled-binary-using-a-web-browser">macOS installation from precompiled binary, using a web browser</h2><p>When downloading a binary with a web browser, the browser will set the macOS gatekeeper quarantine attribute. Starting from Catalina, when attempting to run <code>rclone</code>, a pop-up will appear saying:</p><pre><code>“rclone” cannot be opened because the developer cannot be verified.macOS cannot verify that this app is free from malware.</code></pre><p>The simplest fix is to run</p><pre><code>xattr -d com.apple.quarantine rclone</code></pre><h2 id="install-with-docker">Install with docker</h2><p>The rclone maintains a <a href="https://hub.docker.com/r/rclone/rclone">docker image for rclone</a>. These images are autobuilt by docker hub from the rclone source based on a minimal Alpine linux image.</p><p>The <code>:latest</code> tag will always point to the latest stable release. You can use the <code>:beta</code> tag to get the latest build from master. You can also use version tags, eg <code>:1.49.1</code>, <code>:1.49</code> or <code>:1</code>.</p><pre><code>$ docker pull rclone/rclone:latestlatest: Pulling from rclone/rcloneDigest: sha256:0e0ced72671989bb837fea8e88578b3fc48371aa45d209663683e24cfdaa0e11...$ docker run --rm rclone/rclone:latest versionrclone v1.49.1- os/arch: linux/amd64- go version: go1.12.9</code></pre><p>There are a few command line options to consider when starting an rclone Docker container from the rclone image.</p><ul><li><p>You need to mount the host rclone config dir at <code>/config/rclone</code> into the Docker container. Due to the fact that rclone updates tokens inside its config file, and that the update process involves a file rename, you need to mount the whole host rclone config dir, not just the single host rclone config file.</p></li><li><p>You need to mount a host data dir at <code>/data</code> into the Docker container.</p></li><li><p>By default, the rclone binary inside a Docker container runs with UID=0 (root). As a result, all files created in a run will have UID=0. If your config and data files reside on the host with a non-root UID:GID, you need to pass these on the container start command line.</p></li><li><p>It is possible to use <code>rclone mount</code> inside a userspace Docker container, and expose the resulting fuse mount to the host. The exact <code>docker run</code> options to do that might vary slightly between hosts. See, e.g. the discussion in this <a href="https://github.com/moby/moby/issues/9448">thread</a>.</p><p>You also need to mount the host <code>/etc/passwd</code> and <code>/etc/group</code> for fuse to work inside the container.</p></li></ul><p>Here are some commands tested on an Ubuntu 18.04.3 host:</p><pre><code># config on host at ~/.config/rclone/rclone.conf# data on host at ~/data # make sure the config is ok by listing the remotesdocker run --rm \    --volume ~/.config/rclone:/config/rclone \    --volume ~/data:/data:shared \    --user $(id -u):$(id -g) \    rclone/rclone \    listremotes # perform mount inside Docker container, expose result to hostmkdir -p ~/data/mountdocker run --rm \    --volume ~/.config/rclone:/config/rclone \    --volume ~/data:/data:shared \    --user $(id -u):$(id -g) \    --volume /etc/passwd:/etc/passwd:ro --volume /etc/group:/etc/group:ro \    --device /dev/fuse --cap-add SYS_ADMIN --security-opt apparmor:unconfined \    rclone/rclone \    mount dropbox:Photos /data/mount &amp;ls ~/data/mountkill %1</code></pre><h2 id="install-from-source">Install from source</h2><p>Make sure you have at least <a href="https://golang.org/">Go</a> 1.7 installed. <a href="https://golang.org/dl/">Download go</a> if necessary. The latest release is recommended. Then</p><pre><code>git clone https://github.com/rclone/rclone.gitcd rclonego build./rclone version</code></pre><p>You can also build and install rclone in the <a href="https://github.com/golang/go/wiki/GOPATH">GOPATH</a> (which defaults to <code>~/go</code>) with:</p><pre><code>go get -u -v github.com/rclone/rclone</code></pre><p>and this will build the binary in <code>$GOPATH/bin</code> (<code>~/go/bin/rclone</code> by default) after downloading the source to <code>$GOPATH/src/github.com/rclone/rclone</code> (<code>~/go/src/github.com/rclone/rclone</code> by default).</p><h2 id="installation-with-ansible">Installation with Ansible</h2><p>This can be done with <a href="https://github.com/stefangweichinger/ansible-rclone">Stefan Weichinger’s ansible role</a>.</p><p>Instructions</p><ol type="1"><li><code>git clone https://github.com/stefangweichinger/ansible-rclone.git</code> into your local roles-directory</li><li>add the role to the hosts you want rclone installed to:</li></ol><pre><code>    - hosts: rclone-hosts      roles:          - rclone</code></pre><h2 id="configure">Configure</h2><p>First, you’ll need to configure rclone. As the object storage systems have quite complicated authentication these are kept in a config file. (See the <code>--config</code> entry for how to find the config file and choose its location.)</p><p>The easiest way to make the config is to run rclone with the config option:</p><pre><code>rclone config</code></pre><p>See the following for detailed instructions for</p><ul><li><a href="https://rclone.org/fichier/">1Fichier</a></li><li><a href="https://rclone.org/alias/">Alias</a></li><li><a href="https://rclone.org/amazonclouddrive/">Amazon Drive</a></li><li><a href="https://rclone.org/s3/">Amazon S3</a></li><li><a href="https://rclone.org/b2/">Backblaze B2</a></li><li><a href="https://rclone.org/box/">Box</a></li><li><a href="https://rclone.org/cache/">Cache</a></li><li><a href="https://rclone.org/chunker/">Chunker</a> - transparently splits large files for other remotes</li><li><a href="https://rclone.org/sharefile/">Citrix ShareFile</a></li><li><a href="https://rclone.org/crypt/">Crypt</a> - to encrypt other remotes</li><li><a href="https://rclone.org/s3/#digitalocean-spaces">DigitalOcean Spaces</a></li><li><a href="https://rclone.org/dropbox/">Dropbox</a></li><li><a href="https://rclone.org/ftp/">FTP</a></li><li><a href="https://rclone.org/googlecloudstorage/">Google Cloud Storage</a></li><li><a href="https://rclone.org/drive/">Google Drive</a></li><li><a href="https://rclone.org/googlephotos/">Google Photos</a></li><li><a href="https://rclone.org/http/">HTTP</a></li><li><a href="https://rclone.org/hubic/">Hubic</a></li><li><a href="https://rclone.org/jottacloud/">Jottacloud / GetSky.no</a></li><li><a href="https://rclone.org/koofr/">Koofr</a></li><li><a href="https://rclone.org/mailru/">Mail.ru Cloud</a></li><li><a href="https://rclone.org/mega/">Mega</a></li><li><a href="https://rclone.org/memory/">Memory</a></li><li><a href="https://rclone.org/azureblob/">Microsoft Azure Blob Storage</a></li><li><a href="https://rclone.org/onedrive/">Microsoft OneDrive</a></li><li><a href="https://rclone.org/swift/">OpenStack Swift / Rackspace Cloudfiles / Memset Memstore</a></li><li><a href="https://rclone.org/opendrive/">OpenDrive</a></li><li><a href="https://rclone.org/pcloud/">Pcloud</a></li><li><a href="https://rclone.org/premiumizeme/">premiumize.me</a></li><li><a href="https://rclone.org/putio/">put.io</a></li><li><a href="https://rclone.org/qingstor/">QingStor</a></li><li><a href="https://rclone.org/seafile/">Seafile</a></li><li><a href="https://rclone.org/sftp/">SFTP</a></li><li><a href="https://rclone.org/sugarsync/">SugarSync</a></li><li><a href="https://rclone.org/tardigrade/">Tardigrade</a></li><li><a href="https://rclone.org/union/">Union</a></li><li><a href="https://rclone.org/webdav/">WebDAV</a></li><li><a href="https://rclone.org/yandex/">Yandex Disk</a></li><li><a href="https://rclone.org/local/">The local filesystem</a></li></ul><h2 id="usage">Usage</h2><p>Rclone syncs a directory tree from one storage system to another.</p><p>Its syntax is like this</p><pre><code>Syntax: [options] subcommand &lt;parameters&gt; &lt;parameters...&gt;</code></pre><p>Source and destination paths are specified by the name you gave the storage system in the config file then the sub path, eg “drive:myfolder” to look at “myfolder” in Google drive.</p><p>You can define as many storage paths as you like in the config file.</p><h2 id="subcommands">Subcommands</h2><p>rclone uses a system of subcommands. For example</p><pre><code>rclone ls remote:path # lists a remoterclone copy /local/path remote:path # copies /local/path to the remoterclone sync /local/path remote:path # syncs /local/path to the remote</code></pre><h1 id="rclone-config">rclone config</h1><p>Enter an interactive configuration session.</p><h2 id="synopsis">Synopsis</h2><p>Enter an interactive configuration session where you can setup new remotes and manage existing ones. You may also set or remove a password to protect your configuration.</p><pre><code>rclone config [flags]</code></pre><h2 id="options">Options</h2><pre><code>  -h, --help   help for config</code></pre><p>See the <a href="https://rclone.org/flags/">global flags page</a> for global options not listed here.</p><h2 id="see-also">SEE ALSO</h2><ul><li><a href="https://rclone.org/commands/rclone/">rclone</a> - Show help for rclone commands, flags and backends.</li><li><a href="https://rclone.org/commands/rclone_config_create/">rclone config create</a> - Create a new remote with name, type and options.</li><li><a href="https://rclone.org/commands/rclone_config_delete/">rclone config delete</a> - Delete an existing remote <code>name</code>.</li><li><a href="https://rclone.org/commands/rclone_config_disconnect/">rclone config disconnect</a> - Disconnects user from remote</li><li><a href="https://rclone.org/commands/rclone_config_dump/">rclone config dump</a> - Dump the config file as JSON.</li><li><a href="https://rclone.org/commands/rclone_config_edit/">rclone config edit</a> - Enter an interactive configuration session.</li><li><a href="https://rclone.org/commands/rclone_config_file/">rclone config file</a> - Show path of configuration file in use.</li><li><a href="https://rclone.org/commands/rclone_config_password/">rclone config password</a> - Update password in an existing remote.</li><li><a href="https://rclone.org/commands/rclone_config_providers/">rclone config providers</a> - List in JSON format all the providers and options.</li><li><a href="https://rclone.org/commands/rclone_config_reconnect/">rclone config reconnect</a> - Re-authenticates user with remote.</li><li><a href="https://rclone.org/commands/rclone_config_show/">rclone config show</a> - Print (decrypted) config file, or the config for a single remote.</li><li><a href="https://rclone.org/commands/rclone_config_update/">rclone config update</a> - Update options in an existing remote.</li><li><a href="https://rclone.org/commands/rclone_config_userinfo/">rclone config userinfo</a> - Prints info about logged in user of remote.</li></ul><h1 id="rclone-copy">rclone copy</h1><p>Copy files from source to dest, skipping already copied</p><h2 id="synopsis-1">Synopsis</h2><p>Copy the source to the destination. Doesn’t transfer unchanged files, testing by size and modification time or MD5SUM. Doesn’t delete files from the destination.</p><p>Note that it is always the contents of the directory that is synced, not the directory so when source:path is a directory, it’s the contents of source:path that are copied, not the directory name and contents.</p><p>If dest:path doesn’t exist, it is created and the source:path contents go there.</p><p>For example</p><pre><code>rclone copy source:sourcepath dest:destpath</code></pre><p>Let’s say there are two files in sourcepath</p><pre><code>sourcepath/one.txtsourcepath/two.txt</code></pre><p>This copies them to</p><pre><code>destpath/one.txtdestpath/two.txt</code></pre><p>Not to</p><pre><code>destpath/sourcepath/one.txtdestpath/sourcepath/two.txt</code></pre><p>If you are familiar with <code>rsync</code>, rclone always works as if you had written a trailing / - meaning “copy the contents of this directory”. This applies to all commands and whether you are talking about the source or destination.</p><p>See the <a href="https://rclone.org/docs/#no-traverse">–no-traverse</a> option for controlling whether rclone lists the destination directory or not. Supplying this option when copying a small number of files into a large destination can speed transfers up greatly.</p><p>For example, if you have many files in /path/to/src but only a few of them change every day, you can copy all the files which have changed recently very efficiently like this:</p><pre><code>rclone copy --max-age 24h --no-traverse /path/to/src remote:</code></pre><p><strong>Note</strong>: Use the <code>-P</code>/<code>--progress</code> flag to view real-time transfer statistics</p><pre><code>rclone copy source:path dest:path [flags]</code></pre><h2 id="options-1">Options</h2><pre><code>      --create-empty-src-dirs   Create empty source dirs on destination after copy  -h, --help                    help for copy</code></pre><p>See the <a href="https://rclone.org/flags/">global flags page</a> for global options not listed here.</p><h2 id="see-also-1">SEE ALSO</h2><ul><li><a href="https://rclone.org/commands/rclone/">rclone</a> - Show help for rclone commands, flags and backends.</li></ul><h1 id="rclone-sync">rclone sync</h1><p>Make source and dest identical, modifying destination only.</p><h2 id="synopsis-2">Synopsis</h2><p>Sync the source to the destination, changing the destination only. Doesn’t transfer unchanged files, testing by size and modification time or MD5SUM. Destination is updated to match source, including deleting files if necessary.</p><p><strong>Important</strong>: Since this can cause data loss, test first with the <code>--dry-run</code> flag to see exactly what would be copied and deleted.</p><p>Note that files in the destination won’t be deleted if there were any errors at any point.</p><p>It is always the contents of the directory that is synced, not the directory so when source:path is a directory, it’s the contents of source:path that are copied, not the directory name and contents. See extended explanation in the <code>copy</code> command above if unsure.</p><p>If dest:path doesn’t exist, it is created and the source:path contents go there.</p><p><strong>Note</strong>: Use the <code>-P</code>/<code>--progress</code> flag to view real-time transfer statistics</p><pre><code>rclone sync source:path dest:path [flags]</code></pre><h2 id="options-2">Options</h2><pre><code>      --create-empty-src-dirs   Create empty source dirs on destination after sync  -h, --help                    help for sync</code></pre><p>See the <a href="https://rclone.org/flags/">global flags page</a> for global options not listed here.</p><h2 id="see-also-2">SEE ALSO</h2><ul><li><a href="https://rclone.org/commands/rclone/">rclone</a> - Show help for rclone commands, flags and backends.</li></ul><h1 id="rclone-move">rclone move</h1><p>Move files from source to dest.</p><h2 id="synopsis-3">Synopsis</h2><p>Moves the contents of the source directory to the destination directory. Rclone will error if the source and destination overlap and the remote does not support a server side directory move operation.</p><p>If no filters are in use and if possible this will server side move <code>source:path</code> into <code>dest:path</code>. After this <code>source:path</code> will no longer exist.</p><p>Otherwise for each file in <code>source:path</code> selected by the filters (if any) this will move it into <code>dest:path</code>. If possible a server side move will be used, otherwise it will copy it (server side if possible) into <code>dest:path</code> then delete the original (if no errors on copy) in <code>source:path</code>.</p><p>If you want to delete empty source directories after move, use the –delete-empty-src-dirs flag.</p><p>See the <a href="https://rclone.org/docs/#no-traverse">–no-traverse</a> option for controlling whether rclone lists the destination directory or not. Supplying this option when moving a small number of files into a large destination can speed transfers up greatly.</p><p><strong>Important</strong>: Since this can cause data loss, test first with the –dry-run flag.</p><p><strong>Note</strong>: Use the <code>-P</code>/<code>--progress</code> flag to view real-time transfer statistics.</p><pre><code>rclone move source:path dest:path [flags]</code></pre><h2 id="options-3">Options</h2><pre><code>      --create-empty-src-dirs   Create empty source dirs on destination after move      --delete-empty-src-dirs   Delete empty source dirs after move  -h, --help                    help for move</code></pre><p>See the <a href="https://rclone.org/flags/">global flags page</a> for global options not listed here.</p><h2 id="see-also-3">SEE ALSO</h2><ul><li><a href="https://rclone.org/commands/rclone/">rclone</a> - Show help for rclone commands, flags and backends.</li></ul><h1 id="rclone-delete">rclone delete</h1><p>Remove the contents of path.</p><h2 id="synopsis-4">Synopsis</h2><p>Remove the files in path. Unlike <code>purge</code> it obeys include/exclude filters so can be used to selectively delete files.</p><p><code>rclone delete</code> only deletes objects but leaves the directory structure alone. If you want to delete a directory and all of its contents use <code>rclone purge</code></p><p>If you supply the –rmdirs flag, it will remove all empty directories along with it.</p><p>Eg delete all files bigger than 100MBytes</p><p>Check what would be deleted first (use either)</p><pre><code>rclone --min-size 100M lsl remote:pathrclone --dry-run --min-size 100M delete remote:path</code></pre><p>Then delete</p><pre><code>rclone --min-size 100M delete remote:path</code></pre><p>That reads “delete everything with a minimum size of 100 MB”, hence delete all files bigger than 100MBytes.</p><pre><code>rclone delete remote:path [flags]</code></pre><h2 id="options-4">Options</h2><pre><code>  -h, --help     help for delete      --rmdirs   rmdirs removes empty directories but leaves root intact</code></pre><p>See the <a href="https://rclone.org/flags/">global flags page</a> for global options not listed here.</p><h2 id="see-also-4">SEE ALSO</h2><ul><li><a href="https://rclone.org/commands/rclone/">rclone</a> - Show help for rclone commands, flags and backends.</li></ul><h1 id="rclone-purge">rclone purge</h1><p>Remove the path and all of its contents.</p><h2 id="synopsis-5">Synopsis</h2><p>Remove the path and all of its contents. Note that this does not obey include/exclude filters - everything will be removed. Use <code>delete</code> if you want to selectively delete files.</p><pre><code>rclone purge remote:path [flags]</code></pre><h2 id="options-5">Options</h2><pre><code>  -h, --help   help for purge</code></pre><p>See the <a href="https://rclone.org/flags/">global flags page</a> for global options not listed here.</p><h2 id="see-also-5">SEE ALSO</h2><ul><li><a href="https://rclone.org/commands/rclone/">rclone</a> - Show help for rclone commands, flags and backends.</li></ul><h1 id="rclone-mkdir">rclone mkdir</h1><p>Make the path if it doesn’t already exist.</p><h2 id="synopsis-6">Synopsis</h2><p>Make the path if it doesn’t already exist.</p><pre><code>rclone mkdir remote:path [flags]</code></pre><h2 id="options-6">Options</h2><pre><code>  -h, --help   help for mkdir</code></pre><p>See the <a href="https://rclone.org/flags/">global flags page</a> for global options not listed here.</p><h2 id="see-also-6">SEE ALSO</h2><ul><li><a href="https://rclone.org/commands/rclone/">rclone</a> - Show help for rclone commands, flags and backends.</li></ul><h1 id="rclone-rmdir">rclone rmdir</h1><p>Remove the path if empty.</p><h2 id="synopsis-7">Synopsis</h2><p>Remove the path. Note that you can’t remove a path with objects in it, use purge for that.</p><pre><code>rclone rmdir remote:path [flags]</code></pre><h2 id="options-7">Options</h2><pre><code>  -h, --help   help for rmdir</code></pre><p>See the <a href="https://rclone.org/flags/">global flags page</a> for global options not listed here.</p><h2 id="see-also-7">SEE ALSO</h2><ul><li><a href="https://rclone.org/commands/rclone/">rclone</a> - Show help for rclone commands, flags and backends.</li></ul><h1 id="rclone-check">rclone check</h1><p>Checks the files in the source and destination match.</p><h2 id="synopsis-8">Synopsis</h2><p>Checks the files in the source and destination match. It compares sizes and hashes (MD5 or SHA1) and logs a report of files which don’t match. It doesn’t alter the source or destination.</p><p>If you supply the –size-only flag, it will only compare the sizes not the hashes as well. Use this for a quick check.</p><p>If you supply the –download flag, it will download the data from both remotes and check them against each other on the fly. This can be useful for remotes that don’t support hashes or if you really want to check all the data.</p><p>If you supply the –one-way flag, it will only check that files in source match the files in destination, not the other way around. Meaning extra files in destination that are not in the source will not trigger an error.</p><pre><code>rclone check source:path dest:path [flags]</code></pre><h2 id="options-8">Options</h2><pre><code>      --download   Check by downloading rather than with hash.  -h, --help       help for check      --one-way    Check one way only, source files must exist on remote</code></pre><p>See the <a href="https://rclone.org/flags/">global flags page</a> for global options not listed here.</p><h2 id="see-also-8">SEE ALSO</h2><ul><li><a href="https://rclone.org/commands/rclone/">rclone</a> - Show help for rclone commands, flags and backends.</li></ul><h1 id="rclone-ls">rclone ls</h1><p>List the objects in the path with size and path.</p><h2 id="synopsis-9">Synopsis</h2><p>Lists the objects in the source path to standard output in a human readable format with size and path. Recurses by default.</p><p>Eg</p><pre><code>$ rclone ls swift:bucket    60295 bevajer5jef    90613 canole    94467 diwogej7    37600 fubuwic</code></pre><p>Any of the filtering options can be applied to this command.</p><p>There are several related list commands</p><ul><li><code>ls</code> to list size and path of objects only</li><li><code>lsl</code> to list modification time, size and path of objects only</li><li><code>lsd</code> to list directories only</li><li><code>lsf</code> to list objects and directories in easy to parse format</li><li><code>lsjson</code> to list objects and directories in JSON format</li></ul><p><code>ls</code>,<code>lsl</code>,<code>lsd</code> are designed to be human readable. <code>lsf</code> is designed to be human and machine readable. <code>lsjson</code> is designed to be machine readable.</p><p>Note that <code>ls</code> and <code>lsl</code> recurse by default - use “–max-depth 1” to stop the recursion.</p><p>The other list commands <code>lsd</code>,<code>lsf</code>,<code>lsjson</code> do not recurse by default - use “-R” to make them recurse.</p><p>Listing a non existent directory will produce an error except for remotes which can’t have empty directories (eg s3, swift, gcs, etc - the bucket based remotes).</p><pre><code>rclone ls remote:path [flags]</code></pre><h2 id="options-9">Options</h2><pre><code>  -h, --help   help for ls</code></pre><p>See the <a href="https://rclone.org/flags/">global flags page</a> for global options not listed here.</p>

Lines 1–500 of 21281.