Proxmox HDD not going to sleep
List disks fdisk -l
Check disk status hdparm -C /dev/sdX
example:
[email protected]:~# hdparm -C /dev/sdc
/dev/sdc:
drive state is: active/idle
Edit /etc/lvm/lvm.conf
by adding "r|/dev/sdd.*|"
to global_filter
example: (Alternative "r|/dev/disk/by-id/ata-WDC_WD40EZAZ-00SF3B0_WD-WX32DA0HYCR7.*|"
)
...
# Do not scan ZFS zvols (to avoid problems on ZFS zvols snapshots)
# Also do not scan LVM disks from guests on both VGs named & not named 'pve'
global_filter = [ "r|/dev/zd.*|", "r|/dev/mapper/pve-.*|" "r|/dev/mapper/.*-(vm|base)--[0-9]+--disk--[0-9]+|" , "r|/dev/sdc.*|", "r|/dev/sdd.*|"]
# Example
# Accept every block device:
...
To save the changes use update-initramfs -u
and reboot the system
Set spindown time hdparm -S 25 /dev/sdX
where 25 is 25*5 seconds example:
[email protected]:~# hdparm -S 60 /dev/sdc
/dev/sdc:
setting standby to 60 (5 minutes)
Spin down immediately with -y
paramater example:
Don't use -Y
use -y
[email protected]:~# hdparm -y /dev/sdc
/dev/sdc:
issuing standby command
get disk UUID ls -l /dev/disk/by-id/
[email protected]:~# ls -l /dev/disk/by-id/ | grep sd[a-z]$
lrwxrwxrwx 1 root root 9 Jan 15 17:13 ata-HGST_HTS5xxxxxx680_JA1009xxxxD3P -> ../../sde
lrwxrwxrwx 1 root root 9 Jan 15 17:13 ata-ST4000VN008-2DR166_ZGY9xxxx -> ../../sdc
lrwxrwxrwx 1 root root 9 Jan 15 17:13 ata-ST4000VN008-2DR166_ZGY9xxxx -> ../../sdb
lrwxrwxrwx 1 root root 9 Jan 15 17:13 ata-ST4000VN008-2DR166_ZGY9xxxx -> ../../sdd
lrwxrwxrwx 1 root root 9 Jan 15 17:13 ata-ST4000VN008-2DR166_ZGY9xxxx -> ../../sda
lrwxrwxrwx 1 root root 9 Jan 15 17:13 wwn-0x5000c500dxxxxxxx -> ../../sdb
lrwxrwxrwx 1 root root 9 Jan 15 17:13 wwn-0x5000c500dxxxxxxx -> ../../sdc
lrwxrwxrwx 1 root root 9 Jan 15 17:13 wwn-0x5000c500dxxxxxxx -> ../../sda
lrwxrwxrwx 1 root root 9 Jan 15 17:13 wwn-0x5000c500dxxxxxxx -> ../../sdd
lrwxrwxrwx 1 root root 9 Jan 15 17:13 wwn-0x5000c500dxxxxxxx -> ../../sde
edit /etc/hdparam.conf
to make it permanent
/dev/disk/by-id/ata-ST4000VN008-2DR166_ZGY9xxxx {
spindown_time = 45
}