Rclone

From Pulsed Media Wiki
Revision as of 13:44, 21 April 2025 by Gallogeta (talk | contribs) (Created page with "== Rclone == '''Rclone''' is a free and open-source command-line program used to manage, sync, and transfer files across various cloud storage providers, local storage, and r...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Rclone

Rclone is a free and open-source command-line program used to manage, sync, and transfer files across various cloud storage providers, local storage, and remote servers. Often described as “rsync for cloud storage,” Rclone supports over 50 different backends including Google Drive, Dropbox, OneDrive, Amazon S3, Box, FTP, SFTP, and many more.

Rclone is widely used for backing up data, automating cloud syncs, managing seedboxes, and performing encrypted, high-performance file operations.

Key Features

  • **Sync files** – Between cloud, local, or remote storage
  • **Mount cloud storage** – As a virtual drive on your local system
  • **Copy/move operations** – With filters and advanced flags
  • **Encryption support** – Encrypt filenames, file content, and metadata
  • **Transfer optimization** – Multi-threaded uploads/downloads, chunked transfers
  • **Scheduling & automation** – Cron-friendly CLI tool for scripts and backups
  • **Cross-platform** – Available for Linux, Windows, macOS, BSD, Android, and Docker

Supported Storage Backends

  • Cloud: Google Drive, OneDrive, Dropbox, Box, Mega, pCloud
  • Object Storage: Amazon S3, Wasabi, Backblaze B2, DigitalOcean Spaces
  • WebDAV-compatible: Nextcloud, ownCloud, seedboxes
  • FTP/SFTP/HTTP remote servers
  • Local file systems

See the full list: rclone.org/overview

Installation

On Debian/Ubuntu:

<syntaxhighlight lang="bash"> sudo apt install rclone </syntaxhighlight>

Or use the official install script:

<syntaxhighlight lang="bash"> curl https://rclone.org/install.sh | sudo bash </syntaxhighlight>

Configuration

To add a remote backend:

<syntaxhighlight lang="bash"> rclone config </syntaxhighlight>

Follow the interactive prompts to:

  • Create a new remote
  • Select storage type (e.g., Google Drive, WebDAV)
  • Authorize access using OAuth or credentials

Example configuration name: `gdrive`, `seedbox`, `dropbox`

Basic Commands

Copy a local folder to Google Drive:

<syntaxhighlight lang="bash"> rclone copy /local/folder gdrive:/remote/folder </syntaxhighlight>

Sync two directories (deletes extra files):

<syntaxhighlight lang="bash"> rclone sync /local/folder remote:/folder </syntaxhighlight>

Mount remote storage as a filesystem:

<syntaxhighlight lang="bash"> rclone mount gdrive:/ ~/mnt/gdrive </syntaxhighlight>

List files in a remote directory:

<syntaxhighlight lang="bash"> rclone ls remote:/path </syntaxhighlight>

Encrypt a remote:

Use `rclone config` to create an encrypted remote layered on top of an existing remote.

Scheduling and Automation

Rclone is ideal for use in:

  • Shell scripts
  • Cron jobs for daily backups
  • Seedbox automation
  • Server-to-cloud file migrations

Example cron entry for daily sync:

<syntaxhighlight lang="bash"> 0 2 * * * /usr/bin/rclone sync /data remote:/backup </syntaxhighlight>

Use Cases

  • Sync media from a seedbox to cloud storage
  • Backup server files to Google Drive or Dropbox
  • Mount remote drives for live access
  • Transfer between two cloud providers directly
  • Encrypt data before uploading to untrusted storage

Rclone GUI Tools

While Rclone is primarily CLI-based, GUI options include:

  • **Rclone Web UI** – Built-in, browser-based dashboard (`rclone rcd --rc-web-gui`)
  • **RcloneBrowser** – Community-developed graphical frontend

Security and Privacy

  • Offers optional **encryption** for file content, names, and directory structure
  • Uses OAuth 2.0 or direct credentials (depending on backend)
  • Supports `--delete-excluded`, `--dry-run`, `--backup-dir`, and more for safe sync

Comparison with rsync

Feature Rclone rsync
Cloud backend support Yes No SSH/local support Yes Yes Encryption (built-in) Yes No Mount remote drive Yes No Bandwidth throttling Yes Limited GUI options Yes (via Web UI) No Delta syncing No (uploads entire changed file) Yes Scripting support Excellent Excellent

Related Tools and Concepts

See Also