Hi,
what is the best way to sync a folder at my raspberry with google drive?
Within my home network syncthing should sync my google drive between my PC/Notebook and my raspberry.
Kind regards.
Google drive sync/mount? And Syncthing...
Google drive sync/mount? And Syncthing...
Last edited by AnBad on Sat Mar 27, 2021 5:11 pm, edited 1 time in total.
Re: Google drive sync?
Let me guess, its impossible to sync a google account on a DietPi system?
- ravenclaw900
- Posts: 12
- Joined: Sat Jan 09, 2021 4:05 pm
Re: Google drive sync?
No, there are many methods. You could use https://github.com/vitalif/grive2, or
rclone
like https://medium.com/@artur.klauser/mount ... 002c7095c2.Google drive sync/mount? And Syncthing...
I have installed rclone. In addition I had to install the package: apt-get install fuse. Furthermore I had to add an test user (my email Adresse) at the Goolge Cloud Plattform/OAuth consent screen so that rclone could be certified by google and get access.
Two things I couldn't manage to run:
Two things I couldn't manage to run:
- The autostart with systemd. I got stuck at the point where to create a link. I even didn't find the the folder: $HOME/.config/systemd/user which is needed as the tutoriol says. So I tried the folder "/etc/systemd/system". This folder I already know as a noob and would prefer therefor. But did not succeed. systemctl --user enable rclone@gdrive is giving the error: Failed to connect to bus: No such file or directory. Nonetheless the idea behind the tutorial to work with systemd templates is a very good one which I would like to get running. Has anybody an idea how to solve this?
- Therefor I started rclone manually to give it a test. Everything mounts perfect. I can list all files and so on. But I gave syncthing a try. I didn't work out, because of some permission issue. Is it even possible with Syncthing? What to do about the permissions?
2021-03-27 16:48:10: Loading ignores: lstat /mnt/gdrive/.stignore: permission denied
2021-03-27 16:48:10: Failed to create folder root directory stat /mnt/gdrive: permission denied
2021-03-27 16:48:10: Error on folder "gdrive" (wrgj5-dfhfj): stat /mnt/gdrive: permission denied
Re: Google drive sync/mount? And Syncthing...
if you followed the guide and created the
To have the service running on boot, it would need to be enabled. This will create the sym link automatically
Syncthing is executed as user
rclone@.service
service file, you should be able to start the service likeCode: Select all
systemctl --user start rclone@gdrive
Code: Select all
systemctl --user enable rclone@gdrive
Syncthing is executed as user
dietpi
. Therefore you would need to allow r/w access to this user to /mnt/gdrive/
Pls let us know if a solution is working. This could help others if they hit by similar situation. Your DietPi Team