truenas-spindown-timer icon indicating copy to clipboard operation
truenas-spindown-timer copied to clipboard

Fix nvme part cropping / Add Option to skip non-rotational-drives

Open handfrog opened this issue 5 months ago • 0 comments

https://github.com/ngandrass/truenas-spindown-timer/blob/9cc859c399f0a7e9e4b07898a50b4ecaf5e42a77/spindown_timer.sh#L224

I came up with this idea to fix part-cropping for both "normal hda, sda, ..." and nvme:

local dev=$(basename -- "$(readlink -f "${row}")" | sed -e "s/[0-9]\+$//" -e "s/\(nvme[0-9n]\+\)p/\1/")

And I also introduced an option -n to skip all non-rotational drives: Add ft: ignore non-rotational disks

As I need SmartCTL instead of hdparm on TrueNAS Scale 24.0.4.2 I forked baegopooh:master, perhaps you can help to contribute to your repo or merge #38?

handfrog avatar Sep 03 '24 21:09 handfrog