Rclone OneDrive on Debian
Mounting OneDrive in Debian 12 Using rclone
Introduction
Looking to seamlessly integrate your OneDrive with Debian? With the help of rclone, accessing and managing your OneDrive files becomes a breeze. This tutorial will walk you through the steps required to set up and mount your OneDrive storage on Debian. Say goodbye to cumbersome file transfers - let’s streamline your cloud storage experience!
To mount OneDrive in Debian using rclone
, follow these steps:
Create OneDrive Directory:
Create a directory namedOneDrive
in your home directory.1
mkdir OneDrive
Install rclone:
Installrclone
using the package manager.1
sudo apt install rclone
Configure rclone:
Run the configuration forrclone
.1
rclone config
- Set Up OneDrive Remote:
- Press
n
for a new remote. - Enter the name for the remote (e.g., “OneDrive”).
- Select the number corresponding to the remote type for OneDrive.
- Authenticate using your Microsoft account:
- No client ID or client secret is required.
- Choose the Microsoft Cloud Global (1).
- Advanced config editing can be skipped (n).
- Use a web browser to authenticate (y).
- Log in to your Microsoft account in the browser.
- Choose OneDrive personal or business (1).
- Select OneDrive type (personal) and confirm (y).
- Confirm the found drive root type (y).
- Keep this OneDrive remote (y).
- Quit and close the configuration (q).
- Press
Automatically Mount OneDrive on Login:
Edit your.profile
file1
nano ~/.profile
Append the following command at the end:
1
/usr/bin/rclone --vfs-cache-mode writes mount OneDrive: ~/OneDrive &
Save the file, log out, and log back in to automatically mount OneDrive upon login.
Sometimes, the mount command might execute before the system is fully ready. Try adding a delay before mounting in the .profile file:
1
(sleep 10 && /usr/bin/rclone --vfs-cache-mode writes mount OneDrive: ~/OneDrive &)
Now, your OneDrive should be mounted automatically whenever you log in to your Debian system.