# Rclone auto mount

**URL:** <https://forum.rclone.org/t/rclone-auto-mount/6353>\
**Category:** Help and Support\
**Created:** [August 2, 2018, 9:21pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353 "2018-08-02T21:21:11Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![Krider](https://forum.rclone.org/letter_avatar_proxy/v4/letter/k/7cd45c/32.png) [@Krider](https://forum.rclone.org/u/Krider)\
**Post date:** [August 2, 2018, 9:21pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/1 "2018-08-02T21:21:11Z")

</div>

Hi… Im having a problem with my auto mount.

My script.  
[Unit]  
Description=RClone Service  
After=network-online.target  
Wants=network-online.target

[Service]  
Type=notify  
ExecStart=/usr/sbin/rclone mount --allow-other --dir-cache-time 48h --vfs-read-chunk-size 16M --buffer-size 2G Googlecrypt: /home/plex  
ExecStop=/bin/fusermount -uz /home/plex  
Restart=on-abort

[Install]

WantedBy=default.target

The error message In systemctl status rclonemount.service

● rclonemount.service - RClone Service  
Loaded: loaded (/etc/systemd/system/rclonemount.service; enabled; vendor preset: enabled)  
Active: failed (Result: exit-code) since Thu 2018-08-02 23:18:44 CEST; 2min 48s ago  
Process: 31233 ExecStop=/bin/fusermount -uz /home/plex (code=exited, status=1/FAILURE)  
Process: 31231 ExecStart=/usr/sbin/rclone mount --allow-other --dir-cache-time 48h --vfs-read-chunk-size 16M --buffer-size 2G Googlecrypt:  
Main PID: 31231 (code=exited, status=203/EXEC)

Aug 02 23:18:44 Krider82.dk systemd[1]: Starting RClone Service…  
Aug 02 23:18:44 Krider82.dk systemd[1]: rclonemount.service: Main process exited, code=exited, status=203/EXEC  
Aug 02 23:18:44 Krider82.dk fusermount[31233]: /bin/fusermount: failed to unmount /home/plex: Invalid argument  
Aug 02 23:18:44 Krider82.dk systemd[1]: rclonemount.service: Control process exited, code=exited status=1  
Aug 02 23:18:44 Krider82.dk systemd[1]: Failed to start RClone Service.  
Aug 02 23:18:44 Krider82.dk systemd[1]: rclonemount.service: Unit entered failed state.  
Aug 02 23:18:44 Krider82.dk systemd[1]: rclonemount.service: Failed with result ‘exit-code’.

I just a noob so I can’t se whats wrong…Sorry for my bad English…

---

<div class="post-metadata">

**Author:** ![Animosity022](https://forum.rclone.org/user_avatar/forum.rclone.org/animosity022/32/451_2.png) [@Animosity022](https://forum.rclone.org/u/Animosity022)\
**Post date:** [August 2, 2018, 11:00pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/2 "2018-08-02T23:00:31Z")

</div>

What user are you trying to run it as?

If you run just the command line by itself does it work?

`/usr/sbin/rclone mount --allow-other --dir-cache-time 48h --vfs-read-chunk-size 16M --buffer-size 2G Googlecrypt: /home/plex`

---

<div class="post-metadata">

**Author:** ![Krider](https://forum.rclone.org/letter_avatar_proxy/v4/letter/k/7cd45c/32.png) [@Krider](https://forum.rclone.org/u/Krider)\
**Post date:** [August 2, 2018, 11:02pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/3 "2018-08-02T23:02:20Z")

</div>

Yes I works by itself… how do I run it as a user…

---

<div class="post-metadata">

**Author:** ![Animosity022](https://forum.rclone.org/user_avatar/forum.rclone.org/animosity022/32/451_2.png) [@Animosity022](https://forum.rclone.org/u/Animosity022)\
**Post date:** [August 2, 2018, 11:03pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/4 "2018-08-02T23:03:58Z")

</div>

The user you are trying to run it as is?

You can type ‘whoami’

and can you share the output of when you enter the full command in?

---

<div class="post-metadata">

**Author:** ![Krider](https://forum.rclone.org/letter_avatar_proxy/v4/letter/k/7cd45c/32.png) [@Krider](https://forum.rclone.org/u/Krider)\
**Post date:** [August 2, 2018, 11:06pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/5 "2018-08-02T23:06:32Z")

</div>

it says root. but when I log in by terminal I use another username

---

<div class="post-metadata">

**Author:** ![Animosity022](https://forum.rclone.org/user_avatar/forum.rclone.org/animosity022/32/451_2.png) [@Animosity022](https://forum.rclone.org/u/Animosity022)\
**Post date:** [August 2, 2018, 11:07pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/6 "2018-08-02T23:07:06Z")

</div>

Can you share the output of when you run it as root?

---

<div class="post-metadata">

**Author:** ![Krider](https://forum.rclone.org/letter_avatar_proxy/v4/letter/k/7cd45c/32.png) [@Krider](https://forum.rclone.org/u/Krider)\
**Post date:** [August 2, 2018, 11:13pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/7 "2018-08-02T23:13:28Z")

</div>

I think Im losing it in translation. do you want med to log out and then log in as root??  
if not can you dumb it down for me. Has only been using ssh and terminal for 10 days…

---

<div class="post-metadata">

**Author:** ![Animosity022](https://forum.rclone.org/user_avatar/forum.rclone.org/animosity022/32/451_2.png) [@Animosity022](https://forum.rclone.org/u/Animosity022)\
**Post date:** [August 2, 2018, 11:22pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/8 "2018-08-02T23:22:11Z")

</div>

If you login to your machine as whatever user you want to use, enter the mount command to validate it works so specifically type in:

`/usr/sbin/rclone mount --allow-other --dir-cache-time 48h --vfs-read-chunk-size 16M --buffer-size 2G Googlecrypt: /home/plex`

Copy and paste into here the entire output of that command like this:

```
felix@gemini:~$ /usr/sbin/rclone mount --allow-other --dir-cache-time 48h --vfs-read-chunk-size 16M --buffer-size 2G Googlecrypt: /home/plex
-bash: /usr/sbin/rclone: No such file or directory

```

For me the command doesn’t work because rclone is normally installed into /usr/bin/rclone which is why I’d like to replicate the commands exactly and see the output.

---

<div class="post-metadata">

**Author:** ![Krider](https://forum.rclone.org/letter_avatar_proxy/v4/letter/k/7cd45c/32.png) [@Krider](https://forum.rclone.org/u/Krider)\
**Post date:** [August 2, 2018, 11:32pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/9 "2018-08-02T23:32:47Z")

</div>

found the I don’t have a s in sbin

updated my script and I try running the script again…

Krider82:/etc/systemd/system# sudo systemctl start rclonemount.service  
Job for rclonemount.service failed because the control process exited with error code. See “systemctl status rclonemount.service” and “journalctl -xe” for details.  
Krider82:/etc/systemd/system#

---

<div class="post-metadata">

**Author:** ![Animosity022](https://forum.rclone.org/user_avatar/forum.rclone.org/animosity022/32/451_2.png) [@Animosity022](https://forum.rclone.org/u/Animosity022)\
**Post date:** [August 2, 2018, 11:34pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/10 "2018-08-02T23:34:40Z")

</div>

Instead of running the script, can you please type in the exact command you are running and include the output printed to the screen.

---

<div class="post-metadata">

**Author:** ![Krider](https://forum.rclone.org/letter_avatar_proxy/v4/letter/k/7cd45c/32.png) [@Krider](https://forum.rclone.org/u/Krider)\
**Post date:** [August 2, 2018, 11:38pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/11 "2018-08-02T23:38:00Z")

</div>

Krider82:/etc/systemd/system# rclone mount --allow-other --dir-cache-time 48h --vfs-read-chunk-size 16M --buffer-size 2G Googlecrypt: /home/plex  
just blank screen from that on.

and now the drive is accessible.

---

<div class="post-metadata">

**Author:** ![Animosity022](https://forum.rclone.org/user_avatar/forum.rclone.org/animosity022/32/451_2.png) [@Animosity022](https://forum.rclone.org/u/Animosity022)\
**Post date:** [August 2, 2018, 11:39pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/12 "2018-08-02T23:39:57Z")

</div>

Is that same window can you please type:

```
felix@gemini:~$ which rclone
/usr/bin/rclone
felix@gemini:~$ rclone config file
Configuration file is stored at:
/home/felix/.rclone.conf

```

And share the full output?

---

<div class="post-metadata">

**Author:** ![Krider](https://forum.rclone.org/letter_avatar_proxy/v4/letter/k/7cd45c/32.png) [@Krider](https://forum.rclone.org/u/Krider)\
**Post date:** [August 2, 2018, 11:43pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/13 "2018-08-02T23:43:06Z")

</div>

Krider82:/etc/systemd/system# which rclone  
rclone is /usr/bin/rclone  
rclone is /usr/bin/rclone  
Krider82:/etc/systemd/system# rclone config file  
Configuration file is stored at:  
/root/.config/rclone/rclone.conf

Here it is… I am really appreciating you helping me

---

<div class="post-metadata">

**Author:** ![Animosity022](https://forum.rclone.org/user_avatar/forum.rclone.org/animosity022/32/451_2.png) [@Animosity022](https://forum.rclone.org/u/Animosity022)\
**Post date:** [August 2, 2018, 11:47pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/14 "2018-08-02T23:47:32Z")

</div>

Cool. So you are running as the user ‘root’.

Your systemd file should be almost identical to what you had, but make sure the sbin changes to bin so:

```
[Unit]
Description=RClone Service
After=network-online.target
Wants=network-online.target

[Service]
Type=notify
ExecStart=/usr/bin/rclone mount --allow-other --dir-cache-time 48h --vfs-read-chunk-size 16M --buffer-size 2G Googlecrypt: /home/plex
ExecStop=/bin/fusermount -uz /home/plex
Restart=on-abort
User=
Group=

[Install]

WantedBy=default.target

```

Once you save the file, you need to basically load that into the system by doing:

`systemctl daemon-reload`

That won’t generate any output.

Next you can run:

`systemctl start rclonemount`

and check with

`systemctl status rclonemount`

You should only have 1 rclone process running so if it fails, it might be due to having multiple items going.

You can validate by:

`ps -ef | grep rclone`

and should see just 1 running. If there are more you can:

`pkill rclone`

and validate by the ps -ef command above to ensure nothing is running.

---

<div class="post-metadata">

**Author:** ![Krider](https://forum.rclone.org/letter_avatar_proxy/v4/letter/k/7cd45c/32.png) [@Krider](https://forum.rclone.org/u/Krider)\
**Post date:** [August 2, 2018, 11:52pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/15 "2018-08-02T23:52:51Z")

</div>

now it says  
Krider82:/etc/systemd/system# ps -ef | grep rclone  
root 25174 17838 0 01:53 pts/5 00:00:00 grep rclone  
Krider82:/etc/systemd/system# systemctl start rclonemount  
Job for rclonemount.service failed because the control process exited with error code. See “systemctl status rclonemount.service” and “journalctl -xe” for details.  
Krider82:/etc/systemd/system#

Rclone is also uploading from my Mac… Is that why I failing.

---

<div class="post-metadata">

**Author:** ![Animosity022](https://forum.rclone.org/user_avatar/forum.rclone.org/animosity022/32/451_2.png) [@Animosity022](https://forum.rclone.org/u/Animosity022)\
**Post date:** [August 2, 2018, 11:53pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/16 "2018-08-02T23:53:54Z")

</div>

Can you run either:

systemctl status rclonemount.service

or

journalctl -xe

and share the output?

---

<div class="post-metadata">

**Author:** ![Krider](https://forum.rclone.org/letter_avatar_proxy/v4/letter/k/7cd45c/32.png) [@Krider](https://forum.rclone.org/u/Krider)\
**Post date:** [August 2, 2018, 11:55pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/17 "2018-08-02T23:55:16Z")

</div>

its also running on my Mac… can that be why is failing…

but here is the answer back.  
● rclonemount.service - RClone Service  
Loaded: loaded (/etc/systemd/system/rclonemount.service; enabled; vendor preset: enabled)  
Active: failed (Result: exit-code) since Fri 2018-08-03 01:53:05 CEST; 2min 34s ago  
Process: 25541 ExecStop=/bin/fusermount -uz /home/plex (code=exited, status=1/FAILURE)  
Process: 25528 ExecStart=/usr/bin/rclone mount --allow-other --dir-cache-time 48h --vfs-read-chunk-size 16M --buffer-size 2G Googlecrypt: /home/ple  
Main PID: 25528 (code=exited, status=1/FAILURE)

Aug 03 01:53:05 Krider82.dk rclone[25528]: 2018/08/03 01:53:05 ERROR : Use --config flag to workaround.  
Aug 03 01:53:05 Krider82.dk rclone[25528]: 2018/08/03 01:53:05 ERROR : Error was: user: Current not implemented on linux/amd64  
Aug 03 01:53:05 Krider82.dk rclone[25528]: 2018/08/03 01:53:05 NOTICE: Config file “/.rclone.conf” not found - using defaults  
Aug 03 01:53:05 Krider82.dk rclone[25528]: 2018/08/03 01:53:05 Failed to create file system for “Googlecrypt:”: didn’t find section in config file  
Aug 03 01:53:05 Krider82.dk systemd[1]: rclonemount.service: Main process exited, code=exited, status=1/FAILURE  
Aug 03 01:53:05 Krider82.dk fusermount[25541]: /bin/fusermount: failed to unmount /home/plex: Invalid argument  
Aug 03 01:53:05 Krider82.dk systemd[1]: rclonemount.service: Control process exited, code=exited status=1  
Aug 03 01:53:05 Krider82.dk systemd[1]: Failed to start RClone Service.  
Aug 03 01:53:05 Krider82.dk systemd[1]: rclonemount.service: Unit entered failed state.  
Aug 03 01:53:05 Krider82.dk systemd[1]: rclonemount.service: Failed with result ‘exit-code’.

---

<div class="post-metadata">

**Author:** ![Animosity022](https://forum.rclone.org/user_avatar/forum.rclone.org/animosity022/32/451_2.png) [@Animosity022](https://forum.rclone.org/u/Animosity022)\
**Post date:** [August 2, 2018, 11:58pm UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/18 "2018-08-02T23:58:26Z")

</div>

> [@Krider](#):
>
> Process: 25528 ExecStart=/usr/bin/rclone mount --allow-other --dir-cache-time 48h --vfs-read-chunk-size 16M --buffer-size 2G Googlecrypt: /home/ple

You have a typo as the 'x' on the end of plex is missing.

---

<div class="post-metadata">

**Author:** ![Krider](https://forum.rclone.org/letter_avatar_proxy/v4/letter/k/7cd45c/32.png) [@Krider](https://forum.rclone.org/u/Krider)\
**Post date:** [August 3, 2018, 12:02am UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/19 "2018-08-03T00:02:38Z")

</div>

my terminal window was not big enough.  
here we go again.

● rclonemount.service - RClone Service  
Loaded: loaded (/etc/systemd/system/rclonemount.service; enabled; vendor preset: enabled)  
Active: failed (Result: exit-code) since Fri 2018-08-03 02:01:35 CEST; 7s ago  
Process: 2506 ExecStop=/bin/fusermount -uz /home/plex (code=exited, status=1/FAILURE)  
Process: 2495 ExecStart=/usr/bin/rclone mount --allow-other --dir-cache-time 48h --vfs-read-chunk-size 16M --buffer-size 2G Googlecrypt: /home/plex (code=exited, status=1/FAILURE)  
Main PID: 2495 (code=exited, status=1/FAILURE)

Aug 03 02:01:35 Krider82.dk rclone[2495]: 2018/08/03 02:01:35 ERROR : Use --config flag to workaround.  
Aug 03 02:01:35 Krider82.dk rclone[2495]: 2018/08/03 02:01:35 ERROR : Error was: user: Current not implemented on linux/amd64  
Aug 03 02:01:35 Krider82.dk rclone[2495]: 2018/08/03 02:01:35 NOTICE: Config file “/.rclone.conf” not found - using defaults  
Aug 03 02:01:35 Krider82.dk rclone[2495]: 2018/08/03 02:01:35 Failed to create file system for “Googlecrypt:”: didn’t find section in config file  
Aug 03 02:01:35 Krider82.dk systemd[1]: rclonemount.service: Main process exited, code=exited, status=1/FAILURE  
Aug 03 02:01:35 Krider82.dk fusermount[2506]: /bin/fusermount: failed to unmount /home/plex: Invalid argument  
Aug 03 02:01:35 Krider82.dk systemd[1]: rclonemount.service: Control process exited, code=exited status=1  
Aug 03 02:01:35 Krider82.dk systemd[1]: Failed to start RClone Service.  
Aug 03 02:01:35 Krider82.dk systemd[1]: rclonemount.service: Unit entered failed state.  
Aug 03 02:01:35 Krider82.dk systemd[1]: rclonemount.service: Failed with result ‘exit-code’.

---

<div class="post-metadata">

**Author:** ![Animosity022](https://forum.rclone.org/user_avatar/forum.rclone.org/animosity022/32/451_2.png) [@Animosity022](https://forum.rclone.org/u/Animosity022)\
**Post date:** [August 3, 2018, 12:07am UTC](https://forum.rclone.org/t/rclone-auto-mount/6353/20 "2018-08-03T00:07:12Z")

</div>

So don’t paste in any passwords or keys or anything, but this shows output?

rclone config file

and if you type

rclone config show

This produces output from the file?

You can also try to add this to your mount line:

–config /root/.config/rclone/rclone.conf

[Next page](https://forum.rclone.org/t/rclone-auto-mount/6353.md?page=2)
