I use manjaro with xfce. I was trying to automount google drive and onedrive on startup using the following commands:
sh -c "rclone --vfs-cache-mode writes mount googledrive: ~/my_files/GoogleDrive"
sh -c "rclone --vfs-cache-mode writes mount onedrive: ~/my_files/OneDrive"
but only the first command for googledrive gets executed while onedrive is not mounted. I guess this is because rclone is busy executing the first command for mounting googledrive. When I run these commands from the terminal I can use two separate tabs to run both commands simultaneously. Is there a way to do run both these commands automatically on startup?
My rClone version is rclone v1.51.0. I don't get any error message, just that onedrive doesn't get mounted. I am very new to linux so i am not familiar with systemd. I was trying to run those commands with XFCE4's "application autostart", the idea was to mount these drives when I login.
Scripts like this aren't the best way to do this "right" on Linux. But you can just add a '&' in the end of the commands and they will both run.
sleep 30
sh -c "rclone --vfs-cache-mode writes mount googledrive: ~/my_files/GoogleDrive &"
sh -c "rclone --vfs-cache-mode writes mount onedrive: ~/my_files/OneDrive &"
The Right way to do it is through systemd or similar. That's how Linux runs startup services correctly.
Thank you for your response. I tried that but I still face the same issue. I guess I'll start cracking on the systemd thing to do this properly. For now I am just using two different clients for the drives.