I build myself a NAS using my raspberry pi model b with an external power hub with 2 connected hdd's. Instead of leaving everything always running, I want it to only run while it has to. So I need some mechanism that allows me to send the raspberry pi as well as the hdd's to sleep. Another problem I ran into is: After the wake up command, how will the raspberry pi and the hdd's 'fall asleep' again? I hope you got any hint for me I can work with.

Additional informations: I am using samba for filesharing. Raspian is my OS.

2 Answers 2


I need some mechanism that allows me to send the raspberry pi as well as the hdd's to sleep

You cannot. Pi's do not have any form of power management or sleep capabilities. You might, if you want to compile your own kernel, be able to get them to hiberate to a swap partition, but I have not tried this and am not promising it will work. Unless you are maintaining a customized kernel for other reasons, it does not seem a worthwhile pursuit since you still need the same physical mechanism for restarting or resetting them as you would if you just shut them down.

You can use the RUN pins (on B+/2 models these are by the DSI cable connector, on the 3 between the 40-pin breakout and the USB jacks) to reset the Pi after it has been shutdown but:

  1. If you want to do that remotely, you'll need a whole other gadget powered on and waiting to receive the signal to do so.

  2. While they use less power once the operating system has been shutdown, they still use power, so if this is about power, it is not ideal.

You could mitigate #2 by using a separate gadget that controls the power supply, so you could shut a pi down, then kill the power, turn the power back on to reboot.

  • Have you heard about etherwake?
    – Chris311
    Commented May 1, 2017 at 14:05
  • Yes. Although the controller supports it, I do not believe it can be used -- but I have not tried. Some observations from others: raspberrypi.stackexchange.com/q/126/5538
    – goldilocks
    Commented May 1, 2017 at 18:27

Some external HDDs have their own sleep modes that engage after a period of inactivity. This will cut down on power consumption from the disk; the Pi on its own will have moderately low consumption. My (admittedly ancient) Western Digital My Book Essentials (model WDG1U2500N) has this feature.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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