How to configure rclone for the first time, for beginners with images.

Rclone is a powerful tool for synchronizing files between local devices and various cloud storage services like Google Drive, Dropbox, OneDrive, and many others. If you frequently work with cloud storage on Linux, Rclone is the best choice for managing and transferring data. In this article, we will guide you through the configuration of Rclone on Linux, so you can start syncing your files right away.

rclone

What is Rclone?

Rclone is an open-source tool that allows users to manage multiple cloud storage services in a simple and efficient way. With Rclone, you can upload, download, sync, and even encrypt files on cloud storage platforms.

Now, let’s move on to the core of this operation. Make sure you have an active Google account ready to sync. Here’s how you configure Google Drive as a new remote in Rclone:

Step 1: Initial Setup for Google Drive on Rclone

Run the configuration command:

bash
rclone config
terminal

Choose n to create a new remote:

When prompted, type n and hit Enter. Rclone will ask you to name this remote. Let’s name it something simple like Gdrive.

select you want

Select the storage type:

Rclone will display a list of cloud services. Type 19 to select Google Drive and move forward. Please note that Google Drive and Google Cloud are different.

bash
client_id>
client_secret>

Let it be empty

select 1

To gain full access to Google Drive, select option 1.

bash
service_account_file >

Let it be empty

terminal 1

Authenticate your Google account:

Here’s the interesting part. You’ll be asked if you want to authenticate manually or automatically. Choose y for automatic authentication, which will open a browser to link your Google account. If you’re on a headless server, choose n and paste the URL into a browser on another device.

Grant Rclone access to your Google Drive: Once authenticated, allow Rclone to access your Google Drive. You may see a few security prompts from Google. Just click Allow to proceed.

success
It’s been successful!

Save the configuration: After successful authentication, return to the terminal and allow the configuration to be saved by typing y. And that’s it! Your Google Drive remote is now configured.

Step 2: Test Your Remote

Don’t stop at just the configuration. Let’s validate that everything is working as it should. Try listing the files and folders in your Google Drive with the following command:

bash
rclone ls Gdrive:
terminal

If you see a list of files and folders, congratulations! The sync is working.

Step 3: Sync Files and Folders

Now comes the real power of Rclone—synchronization. You can easily transfer files from your local machine to Google Drive with a simple command:

bash
rclone copy /path/to/local_folder Gdrive:/destination_folder

Syncing rules: If a file already exists in Google Drive, Rclone won’t duplicate it. This saves both time and bandwidth. For two-way syncing, you can use:

bash
rclone sync /path/to/local_folder Gdrive:/destination_folder

Step 4: Mount Google Drive as a Local Folder

Want to access your Google Drive as if it were a local folder? You can mount Google Drive using Rclone with the following command:

bash
rclone mount mygdrive: ~/mnt/gdrive

Don’t forget, to use this command, you might need to have FUSE installed on your system. FUSE is a kernel module that allows user-space file systems.


This is only temporary; when your computer shuts down or restarts, the mount folder will disappear. To make it permanent, a special method is required. You can follow this article for guidance.
https://www.conslinux.com/rclone-mount-googledrive-onedrive-permanent/

Conclusion

Configuring Rclone on Linux is quick and easy if you follow the steps above. With this tool, you can efficiently manage multiple cloud storage services for file synchronization, backup, or data transfer between cloud providers. Rclone is an excellent solution for Linux users working with several cloud services.

Be sure to check out our website syslinuxdev.web.id for the latest Linux and tech tutorials!

Tirsasaki
Tirsasaki

I’m a Linux enthusiast who loves sharing knowledge about technology and open-source software. As a writer for Conslinux.com, I create easy-to-follow tutorials, tips for troubleshooting, and helpful guides to make your computing experience better. I enjoy exploring different Linux distributions and am excited to share my insights with the community!

Articles: 215

Leave a Reply

Your email address will not be published. Required fields are marked *