Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I was wondering if it were posible to make my server go to sleep after a set period of time, but still be listening for lan requests. I use my server as a media server that might get used 3 or 4 hours a day and it is really a waste of power to have it running all the time. However I don't want to run up to the second floor to switch it on when we want to watch a movie. I saw a few posts about stopping this from happening but how do you enable it?

share|improve this question
add comment

1 Answer

up vote 2 down vote accepted

Wake on LAN is a BIOS and NIC feature, not an OS feature, that is, you need a supporting BIOS and NIC to do it.

Once you've enabled it in your BIOS (if you can), you can check if your NIC has WOL support enabled by checking the output of ethtool [interface].

If the value of Supports Wake-on contains g, your NIC supports WOL magic packets.

To check if it is actually enabled, take a look at the value of Wake-on. If it contains g, your NIC has magic packet support enabled.

If it isn't enabled, run the following:

ethtool -s [interface] wol g

You'll have to issue this command every time your system starts, so add it to the appropriate place. In Ubuntu, perhaps the best place would be as an up rule in /etc/network/interfaces, or the equivalent for your network manager.

share|improve this answer
    
thanks for the answer! but by "every time your system starts" do you mean wake, reboot, or both? –  Craig Smith Nov 19 '12 at 20:10
    
@CraigSmith That would depend on your NIC, but likely only on boot. –  Chris Down Nov 19 '12 at 20:17
    
thanks for the info, lots of help~! –  Craig Smith Nov 19 '12 at 20:34
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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