Re: weekly fstrim (still) necessary?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun 2020-06-21 (17:57), Chris Murphy wrote:

> > > util-linux provides fstrim.service and fstrim.timer for a while now.
> > > fstrim.timer runs on Monday at 00:00 local time. The upstream default
> > > is disabled, some distributions enable it by default.
> >
> > On Ubuntu 18.04 and RHEL 7.8 "systemctl is-enabled fstrim" returns
> > "static"
> 
> You need to check fstrim.timer, which in turn triggers fstrim.service.

root@fex:~# cat /lib/systemd/system/fstrim.timer
[Unit]
Description=Discard unused blocks once a week
Documentation=man:fstrim
ConditionVirtualization=!container

[Timer]
OnCalendar=weekly
AccuracySec=1h
Persistent=true

[Install]
WantedBy=timers.target


root@fex:~# cat /lib/systemd/system/fstrim.service 
[Unit]
Description=Discard unused blocks
ConditionVirtualization=!container

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



-- 
Ullrich Horlacher              Server und Virtualisierung
Rechenzentrum TIK         
Universitaet Stuttgart         E-Mail: horlacher@xxxxxxxxxxxxxxxxxxxx
Allmandring 30a                Tel:    ++49-711-68565868
70569 Stuttgart (Germany)      WWW:    http://www.tik.uni-stuttgart.de/
REF:<CAJCQCtQmrc5m=H6d6xZiGvuzRrxBhf=wgf8bAMXZ_4p8F3AJFw@xxxxxxxxxxxxxx>



[Index of Archives]     [Linux Filesystem Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux