btrfs-trim and fstrim.timer

**systemctl list-timers**
shows I have the active fstrim.timer.

/usr/lib/systemd/system/fstrim.timer
/usr/lib/systemd/system/fstrim.service

I also found
/etc/cron.weekly/btrfs-trim
and disabled it in
/etc/sysconfig/btrfsmaintenance
by
BTRFS_TRIM_PERIOD=“none”

I just ran
**systemctl restart btrfsmaintenance-refresh**
which seemingly deleted
/etc/cron.weekly/btrfs-trim

**systemctl status fstrim.timer**
shows it’s still active.

So what I’m wondering is:

  • Are there two different things trying to trim once a week?
  • Do I simply **systemctl disable fstrim.timer** to get rid of it?

My goal is to manually run these maintenance operations.

I see
/usr/lib/systemd/system/fstrim.timer
and
https://github.com/kdave/btrfsmaintenance/blob/master/btrfs-trim.timer
are the same.

However,
/usr/lib/systemd/system/fstrim.service
and
https://github.com/kdave/btrfsmaintenance/blob/master/btrfs-trim.service
are not the same.

[Unit]
Description=Discard unused blocks

[Service]
Type=oneshot
ExecStart=/usr/sbin/fstrim -av

Where the version on github has
“Conflicts=fstrim.service”
and the openSUSE fstrim.service isn’t calling btrfs-trim.

So if
/usr/lib/cron/run-crons
[FONT=arial]calls
[FONT=courier new]/etc/cron.weekly/btrfs-trim
and
[/FONT][/FONT]/usr/lib/systemd/system/fstrim.service
[FONT=arial]calls [/FONT]
/usr/sbin/fstrim
[FONT=arial]then it seems like two things are trying to trim once a week.
[/FONT]

This is apparently fixed in Leap 15 (my default is BTRFS_TRIM_PERIOD=“none”).

https://bugzilla.opensuse.org/show_bug.cgi?id=1017268

And for the other:
**systemctl disable fstrim.timer **does permanently disable it;
although, **systemctl stop fstrim.timer **is also needed for the current session.