Guys, how do I find out if TRIM is currently working in openwrt?
I connect my HDD BOX with an SSD drive to the usb port of the Beeline SmartBox GIGA router.
I checked the ssd parameters using hdparm and it reported that TRIM is supported.
hdparm -I /dev/sda1 |grep -i trim
* Data Set Management TRIM supported (limit 8 blocks)
After that, I formatted it into the f2fs file system and it looks like mkfs also says that trim is involved. Is that enough?
mkfs.f2fs /dev/sda1 F2FS-tools: mkfs.f2fs Ver: 1.14.0 (2020-08-24) Info: Disable heap-based policy Info: Debug level = 0 Info: Trim is enabled Info: [/dev/sda1] Disk Model: USB 3.1 Storage Info: Segments per section = 1 Info: Sections per zone = 1 Info: sector size = 512 Info: total sectors = 250067599 (122103 MB) Info: zone aligned segment0 blkaddr: 512 Info: format version with "Linux version 5.10.146 (builder@buildhost) (mipsel-openwrt-linux-musl-gcc (OpenWrt GCC 11.2.0 r19803-9a599fee93) 11.2.0, GNU ld (GNU Binutils) 2.37) #0 SMP Fri Oct 14 22:44:41 2022" Info: [/dev/sda1] Discarding device Info: This device doesn't support BLKSECDISCARD Info: This device doesn't support BLKDISCARD Info: Overprovision ratio = 0.570% Info: Overprovision segments = 702 (GC reserved = 358) Info: format successful