13

I am able to set both APM and spindown times using the command:

hdparm -S 246 -B 128 /dev/sda

Unfortunately I can only find the APM value in the information output:

hdparm -I /dev/sda | grep Advanced

How can I see the spindown time value? I suspect my disc it is ignoring my value. I would like to see it. Tried smartctl but with no luck, help.

Update: It turned out tuned is very aggressive. When I turned it down, my discs does not spin down. It was setting something there.

8

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
0
7

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.

3
  • 1
    Yes. But additionally on my Samsung drive "-B 127" did a spin down before the with -S configured time of 15 minutes. This means you might want to set it even higher to allow the spin down time setting to work. I also found this information here askubuntu.com/a/733242/397064 which suggest a setting of "-B 150" which works for me too. The disc will then spin down after the specified time. Apr 15 '16 at 19:16
  • 2
    This answer is wrong. The Standby timer (-S) and APM (-B) can coexist. Even if APM is 128, the Standby timer may still spin down the HDD. For more information, please read the actual technical standard, ATA/ATAPI Command Set - 2 (ACS-2), see page 19, "If both APM and the Standby timer are set, then the device shall go to the Standby state when the timer expires or the device’s APM algorithm indicates that the Standby state should be entered." Dec 24 '20 at 14:06
  • @BenjaminPeter You're totally right. Dec 24 '20 at 14:33
2

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.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.