Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Spindown Precleared Disks

Featured Replies

If you preclear a disk and have it unassigned on the unRAID server - it will never spin down.

 

I would like to have a way to spin down non-array disks.

If you preclear a disk and have it unassigned on the unRAID server - it will never spin down.

 

I would like to have a way to spin down non-array disks.

It is built into unMENU, but you can easily do it with a line or two in the "go" script.  

 

To set the spin-down timer on a disk, and have it do it on its own after an hour, type:

hdparm -S 242 /dev/sdX

 

From the hdparm manual page:

-S

   Set the standby (spindown) timeout for the drive. This value is used by the drive to determine how long to wait (with no disk activity) before turning off the spindle motor to save power. Under such circumstances, the drive may take as long as 30 seconds to respond to a subsequent disk access, though most drives are much quicker. The encoding of the timeout value is somewhat peculiar. A value of zero means "timeouts are disabled": the device will not automatically enter standby mode. Values from 1 to 240 specify multiples of 5 seconds, yielding timeouts from 5 seconds to 20 minutes. Values from 241 to 251 specify from 1 to 11 units of 30 minutes, yielding timeouts from 30 minutes to 5.5 hours. A value of 252 signifies a timeout of 21 minutes. A value of 253 sets a vendor-defined timeout period between 8 and 12 hours, and the value 254 is reserved. 255 is interpreted as 21 minutes plus 15 seconds. Note that some older drives may have very different interpretations of these values.

 

Add a line to your "go" script for each of the un-assigned drives.

  • Author

I figured since the hdparm spindown option (-y) wouldn't work, that hdparm wasn't going to work.  Didn't think to try -S.

 

That worked!

 

Thanks Joe L!

Wouldn't be nice to add an option to the pre_clear script to automatically spin down a disk after successful preclearing? Would be great and save some heat/power.

  • 1 year later...

It is built into unMENU, but you can easily do it with a line or two in the "go" script. 

 

To set the spin-down timer on a disk, and have it do it on its own after an hour, type:

hdparm -S 242 /dev/sdX

 

From the hdparm manual page:

-S

    Set the standby (spindown) timeout for the drive. This value is used by the drive to determine how long to wait (with no disk activity) before turning off the spindle motor to save power. Under such circumstances, the drive may take as long as 30 seconds to respond to a subsequent disk access, though most drives are much quicker. The encoding of the timeout value is somewhat peculiar. A value of zero means "timeouts are disabled": the device will not automatically enter standby mode. Values from 1 to 240 specify multiples of 5 seconds, yielding timeouts from 5 seconds to 20 minutes. Values from 241 to 251 specify from 1 to 11 units of 30 minutes, yielding timeouts from 30 minutes to 5.5 hours. A value of 252 signifies a timeout of 21 minutes. A value of 253 sets a vendor-defined timeout period between 8 and 12 hours, and the value 254 is reserved. 255 is interpreted as 21 minutes plus 15 seconds. Note that some older drives may have very different interpretations of these values.

 

Add a line to your "go" script for each of the un-assigned drives.

Where exactly in UnMenu can I set the spin down time of a pre-cleared disk that is not assigned to the array?
  • 2 weeks later...

It is built into unMENU, but you can easily do it with a line or two in the "go" script. 

 

To set the spin-down timer on a disk, and have it do it on its own after an hour, type:

hdparm -S 242 /dev/sdX

 

From the hdparm manual page:

-S

    Set the standby (spindown) timeout for the drive. This value is used by the drive to determine how long to wait (with no disk activity) before turning off the spindle motor to save power. Under such circumstances, the drive may take as long as 30 seconds to respond to a subsequent disk access, though most drives are much quicker. The encoding of the timeout value is somewhat peculiar. A value of zero means "timeouts are disabled": the device will not automatically enter standby mode. Values from 1 to 240 specify multiples of 5 seconds, yielding timeouts from 5 seconds to 20 minutes. Values from 241 to 251 specify from 1 to 11 units of 30 minutes, yielding timeouts from 30 minutes to 5.5 hours. A value of 252 signifies a timeout of 21 minutes. A value of 253 sets a vendor-defined timeout period between 8 and 12 hours, and the value 254 is reserved. 255 is interpreted as 21 minutes plus 15 seconds. Note that some older drives may have very different interpretations of these values.

 

Add a line to your "go" script for each of the un-assigned drives.

Where exactly in UnMenu can I set the spin down time of a pre-cleared disk that is not assigned to the array?

nowhere. (is that exact enough?  ;))

 

The hdparm command described above can be typed on the command line.    I don't know of any unMENU plugin that will invoke it on an unassigned drive.

 

Joe

 

 

Wouldn't be nice to add an option to the pre_clear script to automatically spin down a disk after successful preclearing? Would be great and save some heat/power.

 

Joe L, This would be a nice option to add to the preclear options.

 

Perhaps a -y on the command line to trigger an hdparm -t on the device that was just precleared.

or if there is a -S(value) then use that to the hdparm line after the preclear.

Trying to spin down through unmenu didn't work for me, and for some reason my disk was ignoring the hdparm -S timer, I added the following to my /boot/config/go script:

 

# spin down disks not in array

echo "/boot/scripts/spin_down.sh /dev/sda" | at 19:00

 

Some unmenu pages can actually spin up disks outside the array which is why I added the daily job, and it's probably not 100% reliable that my unassigned disk will always remain /dev/sda, but it has through a couple reboots so far.

spin_down.zip

Archived

This topic is now archived and is closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.