Page 1 of 1
Different spindown times
Posted: 01 Dec 2013 15:34
by chrisf4lc0n
What I want to achieve is to have all the drives spinning all the time during the day, so there is no delay in accessing the files and all of them spun down during the night when I am not using them.
I am trying to work out how to set different spindown times for the hdds in a given pool at night and during the day.
I could probably use "camcontrol sleep" and "camcontrol standby" with crontab.
My questions are:
1. Would that clash with the webGUI settings?
2. Which command does spin the disks down is it sleep or standby?
Re: Different spindown times
Posted: 01 Dec 2013 15:49
by chrisf4lc0n
My crontab:
Code: Select all
0 6 * * * root camcontrol standby ada1 -t 3600
0 6 * * * root camcontrol standby ada2 -t 3600
0 6 * * * root camcontrol standby ada3 -t 3600
0 6 * * * root camcontrol standby ada4 -t 3600
0 6 * * * root camcontrol standby ada5 -t 3600
0 6 * * * root camcontrol standby ada6 -t 3600
0 23 * * * root camcontrol standby ada1 -t 600
0 23 * * * root camcontrol standby ada2 -t 600
0 23 * * * root camcontrol standby ada3 -t 600
0 23 * * * root camcontrol standby ada4 -t 600
0 23 * * * root camcontrol standby ada5 -t 600
0 23 * * * root camcontrol standby ada6 -t 600
That should spindown the disks after 1h of idle between 06:00hrs and 23:00hrs and 10 minutes between 23:00hrs and 06:00hrs.
Re: Different spindown times
Posted: 02 Dec 2013 09:55
by chrisf4lc0n
It seems to be working...
The disks definitely spin down, still have to test if they are staying on for the period of time stated in crontab

Re: Different spindown times
Posted: 16 Dec 2013 16:34
by chrisf4lc0n
For anyone interested, these is how to test if the drives are still spinning, look at the last 2 digits of the output if they are "00" drives are not spinning if they are "FF" the drives are running:
My main pool:
Code: Select all
nas4free: ~ # camcontrol cmd ada1 -a "E5 00 00 00 00 00 00 00 00 00 00 00" -r -
50 00 00 00 00 00 00 00 00 00 00
nas4free: ~ # camcontrol cmd ada2 -a "E5 00 00 00 00 00 00 00 00 00 00 00" -r -
50 00 00 00 00 00 00 00 00 00 00
nas4free: ~ # camcontrol cmd ada3 -a "E5 00 00 00 00 00 00 00 00 00 00 00" -r -
50 00 00 78 00 00 00 00 00 00 00
nas4free: ~ # camcontrol cmd ada4 -a "E5 00 00 00 00 00 00 00 00 00 00 00" -r -
50 00 00 78 00 00 00 00 00 00 00
nas4free: ~ # camcontrol cmd ada5 -a "E5 00 00 00 00 00 00 00 00 00 00 00" -r -
50 00 00 00 00 00 00 00 00 00 00
nas4free: ~ # camcontrol cmd ada6 -a "E5 00 00 00 00 00 00 00 00 00 00 00" -r -
50 00 00 00 00 40 00 00 00 00 00
nas4free: ~ #
HDD on which the Transmission is running 24/7:
Code: Select all
nas4free: ~ # camcontrol cmd ada0 -a "E5 00 00 00 00 00 00 00 00 00 00 00" -r -
50 00 80 00 00 00 00 00 00 FF 00
Re: Different spindown times
Posted: 16 Dec 2013 16:36
by chrisf4lc0n
Oh, and one more thing, all the changes in the "crontab" need to be done via WebGUI as if you simply edit the "crontab" from the shell all the changes will be lost

I am obviously talking about the full installation of the N4F...
I hope that this simple guide will help someone

Re: Different spindown times
Posted: 28 Apr 2016 16:37
by mrjacobrussell
how would you add this to cron tab ??
is the 3600 seconds ?