← 返回命令列表

Linux command

hd-idle 命令

文件

复制后可按需替换文件名、目录或参数。

常用示例

Start

systemctl start hd-idle

Spin down

hd-idle -t [/dev/sdX]

Example

hd-idle -i 0 -a /dev/sda -i [300] -a /dev/sdb -i [1200]

Example

hd-idle -i 0 -a [/dev/sda] -i [600]

说明

hd-idle is a utility that spins down external hard disks after a period of idle time. It is particularly useful for USB or eSATA drives that don't support the hdparm -S command for automatic spin-down. The daemon monitors disk activity and issues spin-down commands when disks have been idle for the configured time. Different idle times can be set for different disks, allowing fine-grained control over power management.

参数

-a _DEVICE_
Apply the following idle time to the specified device
-i _SECONDS_
Set idle time in seconds (0 disables spin-down)
-t _DEVICE_
Spin down the specified disk immediately
-l _LOGFILE_
Log spin-down events to specified file
-d
Run in debug mode, do not daemonize

FAQ

What is the hd-idle command used for?

hd-idle is a utility that spins down external hard disks after a period of idle time. It is particularly useful for USB or eSATA drives that don't support the hdparm -S command for automatic spin-down. The daemon monitors disk activity and issues spin-down commands when disks have been idle for the configured time. Different idle times can be set for different disks, allowing fine-grained control over power management.

How do I run a basic hd-idle example?

Run `systemctl start hd-idle` in a terminal, then adjust file names, paths, flags, or remote targets for your system.

What does -a _DEVICE_ do in hd-idle?

Apply the following idle time to the specified device