Hello,
I use Artix OpenRC XFCE on Ext4 for office, graphics, multimedia use :
neofetch --off
jp@jp-artix
-----------
OS: Artix Linux x86_64
Kernel: 6.1.56-1-lts
Uptime: 17 mins
Packages: 1491 (pacman)
Shell: bash 5.1.16
Resolution: 1920x1080
DE: Xfce
WM: Xfwm4
WM Theme: Daloa
Theme: Adwaita [GTK2/3]
Icons: oxygen [GTK2], matefaenzadark [GTK3]
Terminal: xfce4-terminal
Terminal Font: Roboto Mono 12
CPU: AMD Ryzen 5 3600 (12) @ 3.600GHz
GPU: AMD ATI Radeon 540/540X/550/550X / RX 540X/550/550X
Memory: 2474MiB / 15901MiB
Is it useful to add the discard option in /etc/fstab for my SSD drives (which support TRIM) ?
# <file system> <mount point> <type> <options> <dump> <pass>
UUID=2A96-FBFC /boot/efi vfat umask=0077 0 2
UUID=be477200-ee5e-41f8-9ec9-eae0d69aad3c / ext4 defaults,noatime 0 1
UUID=3dfe4cce-a8f2-44ec-8f1d-3479072db5de swap swap defaults,noatime 0 2
tmpfs /tmp tmpfs defaults,noatime,nosuid,noexec,nodev,mode=1777 0 0
UUID=ffd5ad02-5b4e-4a75-ac92-0fbff99bff58 /media/77 ext4 defaults,noatime 0 0
UUID=46def76f-7649-4a0c-86cf-03c894365602 /media/M2-500 ext4 defaults,noatime 0 0
UUID=fa493986-d548-4243-b5ff-87649dc957f9 /media/WD ext4 defaults,noatime 0 0
Some serious sites recommend against it.
discard
If set, causes discard/TRIM commands to be issued to the block device when blocks are freed. This is useful for
SSD devices and sparse/thinly-provisioned LUNs.
https://wiki.archlinux.org/title/Solid_state_drive#TRIM
basically,
why not periodic trim?
if it's a new SSD it should be fine to use continuous trim
I use discard. I've never thought about it much but from a quick read of the linked wiki page section, and the links from that, it seems performance is better with periodic trim IF you have have an over-provisioned or no where near full SSD. If you have a very active (writes) and pretty full SSD discard is better?
I'll just stick with discard for now but might look into it further at some point.
Thank you LemonPie and gripped for your opinions and conclusions.
I have SSDs on several PCs; some are well filled, others not.
I just ran sudo hdparm -t --direct /dev/sda on an SSD 80% full before and after removing the discard option from /etc/fstab : I didn't see any noticeable difference in the results.
This disk worked for years with this option and I had never launched fstrim.
Just so you know the most noob friendly way of knowing whether the ssd does garbage collection, if you delete something big like 5+gb and the LED will stay on for a second or two. Then you won't need to check trim and discard, at least on common usage.