Sample Header Ad - 728x90

fstrim.service blocks trim of /home in Ubuntu/Mint v20, but not in v18

1 vote
1 answer
391 views
In troubleshooting why my /home partition (ext4, luks-encrypted) wasn't being trimmed by the weekly **fstrim** service, I discovered that Ubuntu made a major change in the service file: **On Ubuntu/Mint 18** [Unit] Description=Discard unused blocks ConditionVirtualization=!container [Service] Type=oneshot ExecStart=/sbin/fstrim -av **On Ubuntu/Mint 20** [Unit] Description=Discard unused blocks on filesystems from /etc/fstab Documentation=man:fstrim(8) ConditionVirtualization=!container [Service] Type=oneshot ExecStart=/sbin/fstrim --fstab --verbose --quiet ProtectSystem=strict ProtectHome=yes PrivateDevices=no PrivateNetwork=yes PrivateUsers=no ProtectKernelTunables=yes ProtectKernelModules=yes ProtectControlGroups=yes MemoryDenyWriteExecute=yes SystemCallFilter=@default @file-system @basic-io @system-service Can someone please explain why the change? I can, of course, manually change the ProtectHome=yes setting to ProtectHome=no. But why was this introduced in the latest Ubuntu? Is there a problem trimming /home?
Asked by ajgringo619 (3584 rep)
Jan 21, 2021, 05:08 PM
Last activity: Jan 21, 2021, 05:29 PM