How to determine disc spindown time

Solution 1:

There does not seem to be a way to query that value with hdparm, however you can see if the drive is in a standby or active state...

> sudo hdparm -C /dev/sdb

/dev/sdb:
 drive state is:  standby

> sudo hdparm -C /dev/sda

/dev/sda:
 drive state is:  active/idle

Solution 2:

The option -B 128 inhibits spindown, so your -S option is useless. Have a look at man hdparm. Spindown is only possible with -B parameters of 127 and less.


Solution 3:

If you have a Seagate disk which support Extended Power Controls (EPC), I assume mostly enterprise class, you can use the tool SeaChest
First get the Seagate disk handle:

 SeaChest_PowerControl -v 0 --scan --scanFlags sgtosd

Result:

 Vendor   Handle       Model Number            Serial      Number          FwRev
 ATA      sg0<->sda    ST1000LM049-2GH172      WN90H8BT               SDM1
 ATA      sg1<->sdb    ST1000LM049-2GH172      WN90HACK               SDM1
 ATA      sg2<->sdc    ST1000LM049-2GH172      WGS3M35X               SDM1
 ATA      sg3<->sdd    ST1000LM049-2GH172      WGS65M4X               SDM1
 ATA      sg4<->sde    ST1000NX0303            S470WNPT               NN02
 NVMe     /dev/nvme0n1 Force MP510             184282050001276960F1   ECFM11.0

Then get the standby time:

 SeaChest_PowerControl -v 0 -d /dev/sg4 --showEPCSettings

Result:

 ===EPC Settings===
    * = timer is enabled
    C column = Changeable
    S column = Saveable
    All times are in 100 milliseconds

 Name       Current Timer Default Timer Saved Timer   Recovery Time C S
 Idle A     *200          *10           *200          150           Y Y
 Idle B      1200         *2400          1200         650           Y Y
 Idle C      1300          6000          1300         4000          Y Y
 Standby Z  *1200          36000        *1200         15000         Y Y

(Don't mind my experimental Idle_C and Standby_Z values which is very low)

You can get the tool from Seagate

The above example is from a Seagate Enterprise Capacity 2.5" 1TB SATA (ST1000NX0343). Tried the same on a Seagate BarraCuda Pro 2.5" 1TB SATA (ST1000LM049) and it didn't work, as it apparently doesn't support EPC.