Mount Crashes at night and Systemd catches an ABRT

What is the problem you are having with rclone?

Mount crashes every night, though not sure on the time. It only happens with the games mount, which is a carbon copy of the other mounts with the location and mount changed. The only fixes I've found thus far is to stop the service, fusermount -zu the mount location, restart the service, and redo mount -a.

TLDR: Mount crashes. Mount is rclone + mergerfs and crypted.

What is your rclone version (output from rclone version)

v1.52.2

Which OS you are using and how many bits (eg Windows 7, 64 bit)

Ubuntu 18.04

Which cloud storage system are you using? (eg Google Drive)

Google Drive

The command you were trying to run (eg rclone copy /tmp remote:tmp)

[Unit]
Description=RClone Service
PartOf=gmedia.service

[Service]
Type=notify

ExecStart=/usr/bin/rclone mount GGamesCrypt: /******/Games \
--allow-other \
--dir-cache-time 160h \
--fuse-flag sync_read \
--tpslimit 10 \
--tpslimit-burst 10 \
--buffer-size=1G \
--attr-timeout=1s \
--vfs-read-chunk-size=256M \
--vfs-cache-max-age=5m \
--vfs-cache-mode=writes \
--vfs-read-chunk-size-limit=off \
--log-level DEBUG \
--log-file /var/log/rclone-ggames.log \
--timeout 1h \
--umask 002 

ExecStop=/bin/fusermount -uz /******/Games
RestartSec=10
Restart=on-failure
User=s0n1cm0nk3y
Group=users

[Install]
WantedBy=gmedia.service

from there I have the mount mergerfs'd via fstab just like all the other mounts which are running fine:

/*****/Games* /*****/****/Games fuse.mergerfs direct_io,defaults,allow_other,nonempty,minfreespace=50G,fsname=mergerfs 0 0

The rclone config contents with secrets removed.

[GGames]
type = drive
client_id = *****.googleusercontent.com
client_secret = j*****
scope = drive
service_account_file = /home/*****.json
team_drive = 0*********

[GGamesCrypt]
type = crypt
remote = GGames:
filename_encryption = standard
password = f***********

A log from the command with the -vv flag

I had some messages in the logs, but nothing that seemed to correlate to crashing. The file got to 230G so I wiped and decided to see if the size of the log file was the issue. I'll report back with the updates tomorrow if it crashes. Besides crashing the only error I get looks like this:


Broadcast message from systemd-journal@blitzcollective.org (Thu 2020-07-16 03:41:41 CEST):

systemd[30081]: Caught <ABRT>, dumped core as pid 30088.

Broadcast message from systemd-journal@blitzcollective.org (Thu 2020-07-16 03:41:41 CEST):

systemd[30081]: freezing execution.

You are most likely running out of memory.

That would show in the debug log.

It just crashed recently. Log says:
2020/07/19 17:55:27 DEBUG : rclone: Version "v1.52.2" starting with parameters ["/usr/bin/rclone" "mount" "GGamesCrypt:" "/***/Games" "--allow-other" "--dir-cache-time" "160h" "--fuse-flag" "sync_read" "--tpslimit" "10" "--tpslimit-burst" "10" "--buffer-size=1G" "--attr-timeout=1s" "--vfs-read-chunk-size=256M" "--vfs-cache-max-age=5m" "--vfs-cache-mode=writes" "--vfs-read-chunk-size-limit=off" "--log-level" "DEBUG" "--log-file" "/var/log/rclone-ggames.log" "--timeout" "1h" "--umask" "002"]
2020/07/19 17:55:27 DEBUG : Using config file from "/home/s0n1cm0nk3y/.config/rclone/rclone.conf"
2020/07/19 17:55:27 INFO : Starting HTTP transaction limiter: max 10 transactions/s with burst 10
2020/07/19 17:55:27 Fatal error: Can not open: /---/Games: open /----/Games: transport endpoint is not connected

Current HTOP load:
Capture

You haven't show anything that rclone is crashing.

If you have a log of the issue, that would be great.

What does your journalctl -u servicename show?

Jul 19 18:10:27 blitzcollective.org systemd[1]: Stopped RClone Service.
Jul 19 18:10:27 blitzcollective.org systemd[1]: Starting RClone Service...
Jul 19 18:10:28 blitzcollective.org systemd[1]: rclone-ggames.service: Main process exited, code=exited, status=1/FAILURE
Jul 19 18:10:28 blitzcollective.org systemd[1]: rclone-ggames.service: Failed with result 'exit-code'.
Jul 19 18:10:28 blitzcollective.org systemd[1]: Failed to start RClone Service.
Jul 19 18:10:38 blitzcollective.org systemd[1]: rclone-ggames.service: Service hold-off time over, scheduling restart.
Jul 19 18:10:38 blitzcollective.org systemd[1]: rclone-ggames.service: Scheduled restart job, restart counter is at 2619.
Jul 19 18:10:38 blitzcollective.org systemd[1]: Stopped RClone Service.
Jul 19 18:10:38 blitzcollective.org systemd[1]: Starting RClone Service...
Jul 19 18:10:38 blitzcollective.org systemd[1]: rclone-ggames.service: Main process exited, code=exited, status=1/FAILURE
Jul 19 18:10:38 blitzcollective.org systemd[1]: rclone-ggames.service: Failed with result 'exit-code'.
Jul 19 18:10:38 blitzcollective.org systemd[1]: Failed to start RClone Service.
Jul 19 18:10:48 blitzcollective.org systemd[1]: rclone-ggames.service: Service hold-off time over, scheduling restart.
Jul 19 18:10:48 blitzcollective.org systemd[1]: rclone-ggames.service: Scheduled restart job, restart counter is at 2620.
Jul 19 18:10:48 blitzcollective.org systemd[1]: Stopped RClone Service.
Jul 19 18:10:48 blitzcollective.org systemd[1]: Starting RClone Service...
Jul 19 18:10:48 blitzcollective.org systemd[1]: rclone-ggames.service: Main process exited, code=exited, status=1/FAILURE
Jul 19 18:10:48 blitzcollective.org systemd[1]: rclone-ggames.service: Failed with result 'exit-code'.
Jul 19 18:10:48 blitzcollective.org systemd[1]: Failed to start RClone Service.
Jul 19 18:10:58 blitzcollective.org systemd[1]: rclone-ggames.service: Service hold-off time over, scheduling restart.
Jul 19 18:10:58 blitzcollective.org systemd[1]: rclone-ggames.service: Scheduled restart job, restart counter is at 2621.
Jul 19 18:10:58 blitzcollective.org systemd[1]: Stopped RClone Service.
Jul 19 18:10:58 blitzcollective.org systemd[1]: Starting RClone Service...
Jul 19 18:10:58 blitzcollective.org systemd[1]: rclone-ggames.service: Main process exited, code=exited, status=1/FAILURE
Jul 19 18:10:58 blitzcollective.org systemd[1]: rclone-ggames.service: Failed with result 'exit-code'.
Jul 19 18:10:58 blitzcollective.org systemd[1]: Failed to start RClone Service.
Jul 19 18:11:08 blitzcollective.org systemd[1]: rclone-ggames.service: Service hold-off time over, scheduling restart.
Jul 19 18:11:08 blitzcollective.org systemd[1]: rclone-ggames.service: Scheduled restart job, restart counter is at 2622.
Jul 19 18:11:08 blitzcollective.org systemd[1]: Stopped RClone Service.
Jul 19 18:11:08 blitzcollective.org systemd[1]: Starting RClone Service...
Jul 19 18:11:08 blitzcollective.org systemd[1]: rclone-ggames.service: Main process exited, code=exited, status=1/FAILURE
Jul 19 18:11:08 blitzcollective.org systemd[1]: rclone-ggames.service: Failed with result 'exit-code'.
Jul 19 18:11:08 blitzcollective.org systemd[1]: Failed to start RClone Service.
Jul 19 18:11:19 blitzcollective.org systemd[1]: rclone-ggames.service: Service hold-off time over, scheduling restart.
Jul 19 18:11:19 blitzcollective.org systemd[1]: rclone-ggames.service: Scheduled restart job, restart counter is at 2623.
Jul 19 18:11:19 blitzcollective.org systemd[1]: Stopped RClone Service.
Jul 19 18:11:19 blitzcollective.org systemd[1]: Starting RClone Service...
Jul 19 18:11:19 blitzcollective.org systemd[1]: rclone-ggames.service: Main process exited, code=exited, status=1/FAILURE
Jul 19 18:11:19 blitzcollective.org systemd[1]: rclone-ggames.service: Failed with result 'exit-code'.
Jul 19 18:11:19 blitzcollective.org systemd[1]: Failed to start RClone Service.
Jul 19 18:11:29 blitzcollective.org systemd[1]: rclone-ggames.service: Service hold-off time over, scheduling restart.
Jul 19 18:11:29 blitzcollective.org systemd[1]: rclone-ggames.service: Scheduled restart job, restart counter is at 2624.
Jul 19 18:11:29 blitzcollective.org systemd[1]: Stopped RClone Service.
Jul 19 18:11:29 blitzcollective.org systemd[1]: Starting RClone Service...
Jul 19 18:11:29 blitzcollective.org systemd[1]: rclone-ggames.service: Main process exited, code=exited, status=1/FAILURE
Jul 19 18:11:29 blitzcollective.org systemd[1]: rclone-ggames.service: Failed with result 'exit-code'.
Jul 19 18:11:29 blitzcollective.org systemd[1]: Failed to start RClone Service.

Edit: Bigger pastebin. Same but more:
https://pastebin.com/sRshWMTN

You really want:

KillMode=none

In the service part as if systemd stops rclone and kills it, you get the issue you are describing.

The mount usually can't be stopped if things are accessing it by systemd as it'll kill the process majority of the time leaving it in a hung state.

Do I just throw that into the mount command? Sorry I'm not familiar with kill mode.

In the systemd service:

[Service]
Type=notify
Environment=RCLONE_CONFIG=/opt/rclone/rclone.conf
KillMode=none
RestartSec=5
ExecStart=/usr/bin/rclone mount gcrypt: /GD \
--allow-other \
--dir-cache-time 1000h \

that's part of mine.

Updated. I'll report back if it drops again.

Down it went :frowning: . https://pastebin.com/RLx6hZ7W

Unfortunately, that log still doesn't show rclone crashing as it's just systemd restarting it over and over again.

I'd change

Restart=on-failure

to

Restart=no

As I mentioned many posts ago, having a 1G buffer is also not a good idea as each file uses 1GB of memory as your case is most likely running out of memory.

No worries. I also noticed my update to 18.04 modified the permissions for folders in root. The folder that holds all my mergerfs folders (and some rclone mounts including games) had the root priveledges changed. I swapped it back to the user as that is the one the permissions are set for within the service.

What would you suggest is a good buffer? Technically short of Movies and TVShows nothing really needs a buffer as its just upload and go from there.

Specs: I7-4770 w/ 32GB DDR3

I just run the defaults for many things, including the buffer.

With the new cache mode coming soon, it tends to be better to use a default unless you have a reason to change something.

Wheres the default value for buffer-size?

You can just remove the parameter and it'll use the default value.

--buffer-size SizeSuffix               In memory buffer size when reading files for each --transfer. (default 16M)

https://rclone.org/flags/

So no buffer changes, but it seems the permissions changes might be working. Hasn't dropped yet.

Priviledge changes fixed it! Thanks @Animosity022

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.