Power Management on SPD8020?

Power Management on SPD8020?

Postby such_und_find » Sun Aug 26, 2012 11:58 am

Hi, and first of all big Thanks for the new firmware that keeps the NAS very much up to date and adds functions you really need!
One question I always have been struggling with: Does the Philips NAS have any kind of Power Managaement (Scheduling, Wake on Lan or other auto-spin down options)? I never have managed to find anything in any of the interfaces, but maybe I am overlooking something . Pointer to where this can be set would be welcome (I am using 12.1).
In case not there (yet), can this function be implemented somehow in the next release? I really dont think a home NAS should be spinning all day and burning power without a need....

Thanks!

Such_und_Find
such_und_find
 
Posts: 6
Joined: Sat Aug 25, 2012 4:11 pm

Re: Power Management on SPD8020?

Postby fvdw » Sun Aug 26, 2012 12:08 pm

There is a daemon running that watches disk activity. it will pu the HDD on standby after 15 minutes when there is no request to do something (read/write to disk). It also caches write requests to a certain extend to delay that the disk spins up.
Media servers like twonky are quite busy dependent on how you set it up, it and can prevent the disk form spinning down. Same with the torrent client

As the spd8020 has very small system memory it can not store much in memory so cache is limited.
fvdw
Site Admin - expert
 
Posts: 13245
Joined: Tue Apr 12, 2011 2:30 pm
Location: Netherlands

Re: Power Management on SPD8020?

Postby such_und_find » Mon Aug 27, 2012 6:49 pm

Thanks, explains it!
Thanks againg for all these nice features.

Greets
:applause
such_und_find
 
Posts: 6
Joined: Sat Aug 25, 2012 4:11 pm

Re: Power Management on SPD8020?

Postby tom2005 » Mon Sep 03, 2012 8:26 am

Hi and many thanks for the huge effort with the NAS support. I have never missed any new SW update since the beginning and I have never had problems with my NAS.
The only thing I miss is to swich off the SPD8020 via network request before to switch off the power via Homecontrol.
At the moment I have had no faults doing power off switching, but the there is a bad feeling left.
Due to the information above regarding the Stby mode can you implement/activate an additional timer for power off after additional 15 min in Stby? A little checkbox can make it or not.
Thank you again for your work.

Greetings

tom2005

:please
tom2005
 

Re: Power Management on SPD8020?

Postby fvdw » Mon Sep 03, 2012 6:37 pm

why don't you use the task scheduler to switch it to standby at a certain hour every day

The command to execute to switch the spd to standby is
Code: Select all
/sbin/standbyd-spd


of course you need to set cron enabled at boot

for example this setup will switch it off every day at 19:35 h (nas time)
ps not that "nas time" is not corrected for summertime so 19:35 is on this moment actually 20:35
You do not have the required permissions to view the files attached to this post.
fvdw
Site Admin - expert
 
Posts: 13245
Joined: Tue Apr 12, 2011 2:30 pm
Location: Netherlands

Re: Power Management on SPD8020?

Postby wd9895 » Sat Sep 08, 2012 9:40 am

/sbin/standbyd-spd react very similar as /sbin/poweroff . Power goes off, no WOL possible.
How can I use a WOL command to wake it up if required ? or better... how can I send the NAS to WOL mode ?

The WOL mode works properly on my Lacie and SPD. This is tested.
wd9895
Donator Supporter
Donator Supporter
 
Posts: 255
Joined: Fri Jun 10, 2011 1:49 pm
Location: Hamburg, Germany

Re: Power Management on SPD8020?

Postby fvdw » Sat Sep 08, 2012 10:37 am

on the standbyd-spd function first
wd9895 wrote:/sbin/standbyd-spd react very similar as /sbin/poweroff . Power goes off, no WOL possible.
How can I use a WOL command to wake it up if required ? or better... how can I send the NAS to WOL mode ?

The WOL mode works properly on my Lacie and SPD. This is tested.



you mean sent it to standby with WOL enabled using cron task scheduler ?

In that case create a the file /etc/wolenable
Code: Select all
touch /etc/wolenable

and perform
Code: Select all
/sbin/rebootd-spd

When this file is found during reboot the reboot is halted until a magic packet is received or when you pull the power connection and restore it. The /etc/wolenable file is removed automatically at each reboot. So you need to recreate it every time
This is safety measure if for whatever reason the WOL command doesn't work then just unplugging the NAs en connecting the power again will let it reboot.

To wake it up you will need to send a magic packet to the mac address of spd8020 from a PC in your network

ps Be aware the WOL mode as implemented doesn't save much power as the ethernet card and usb are still under power and the cpu is running. Only HDD is switch off and the fan and no other programs are running. This is because the Network interface Card of the lacies's and spd8020 doesn't support a real WOL mode and we need to simulate it. (Also Lacie firmware uses this fake WOL mode)
The spd8020 and lacies will still consume about 6 watt when in WOL mode. Benefits of this mode are that nobody can use it when it is in this mode until it is wake up again. Also WOL mode will prevent unnecessary disk spin ups in a period that the NAS is not used which might be caused by programs running on your nas (like mediaservers or network activity). This will save energy and lifetime of your HDD. When HDD is running power consumption will be around 15 watts
fvdw
Site Admin - expert
 
Posts: 13245
Joined: Tue Apr 12, 2011 2:30 pm
Location: Netherlands

Re: Power Management on SPD8020?

Postby tom2005 » Sun Sep 09, 2012 12:32 pm

Hi fvdw thank you for your explanation, but the con job does not fit to my requirements.

I'm running WIN7 with the IP-Symcon Server (works under Windows only) for the homecontrol.
All the commands are written / included in PHP.

If it is not possible to shut down the NAS completely and restart it when power ON, so I would like to send the same command like on the system_reset.htm "function ShutDown()".
I have seen the use of the button sends the NAS to Stby and this is good before to power OFF it finaly.
How can I do this with my setup?

Thank you again.

tom2005
tom2005
 

Re: Power Management on SPD8020?

Postby fvdw » Sun Sep 09, 2012 3:21 pm

Hi Tom2005

the only way to switch it off without using the power buttons is execution the /sbin/standbyd-spd command
This is also what the shutdown button is doing.

If you are able to make a ssh connection tot the spd8020 using a script on your win7 computer and then execute this command it would do the job
See for instance here how to do it with Putty http://fixunix.com/ssh/253629-how-pass- ... ecute.html

Another possibility could be using a cron job on the spd8020 that runs in the background that switches it off when it finds a certain file in a one of the shared folders on the sp8020.
To do this cron job could execute a command file lets say every hour that is looking if a file with a certain name is present in a share and if it is found executes switching off the nas and before doing that remove the file, this to prevent that after powering on again it switches off again. This file triggering shuttdown you could write from your win7 PC to a share on the spd8020.
When the spd8020 is switched to standby and power is removed and later restored then it will automatically boot.

Below an example command script that will remove the file and executes the /sbin/standbyd-spd command when it finds a file with name "shuttdown-now" (without the quotes) in the share with name "public". You could define a cron job to execute this script every hour or more frequent if you like.

Code: Select all
#!/bin/sh
if [ -f /share/1000/public/shuttdown-now ]
then
rm -f /share/1000/public/shuttdown-now
/sbin/standbyd-spd
fi


ps when writing a command shell script for linux, be sure you use unix syntax (meaning only <LF> at the end of each line and not DOS syntax using <LF><CR>, command files in dos syntax won't execute the commands...)
I attached the file of the example script
You do not have the required permissions to view the files attached to this post.
fvdw
Site Admin - expert
 
Posts: 13245
Joined: Tue Apr 12, 2011 2:30 pm
Location: Netherlands

Re: Power Management on SPD8020?

Postby peetn » Wed Feb 06, 2013 9:32 pm

for me it works to shut down like this:
http://[username]:[password]@[ipaddress]/global/system_reset.xml?status=shutdown

example
http://test:test@192.168.0.1/global/sys ... s=shutdown

works on mobile phone too
but not with disk name, only with IP address


i'm interested in wake on lan or another way to boot remotely (similar to behaviour when plugging power but preferably via url).
peetn
Donator VIP
Donator VIP
 
Posts: 24
Joined: Wed Feb 06, 2013 5:26 pm

Next

Return to Philips SPD8020

Who is online

Users browsing this forum: No registered users and 6 guests

cron