Remotely (re)starting my system via a smart power switch?
Colin Law
clanlaw at gmail.com
Thu Jun 30 08:08:36 UTC 2022
On Wed, 29 Jun 2022 at 23:11, Bo Berglund <bo.berglund at gmail.com> wrote:
>
> What I meant is that since the laptop has a battery it is not possible to remove
> power and reapply it by switching off/on power to the power supply unit of the
> laptop....
Yes it is, that will remove the power from the laptop. If the BIOS
has a setting to start on power up then that should work. The BIOS
can still see whether there is power applied even though it has a
battery. Not for example that you can change the screen blanking
based on whether it is on power or not.
> Question 1:
> -----------
>
> Is all I need to do the following:
You also need to enable it on the server, something like
sudo ethtool -s enp0s25 wol g
and to check it has taken
sudo ethtool enp0s25
which should show
wake-on: g
This has to be done on every boot, see this link for a good way to do that
https://askubuntu.com/questions/764158/how-to-enable-wake-on-lan-wol-in-ubuntu-16-04
You might also need to enable it in the BIOS.
> Question 2:
> -----------
>
> What is the difference between
> etherwake and wakeonlan
No idea. I have used etherwake and powerwake. I tested it initially
using another PC to
wake the server, but then realised I could install it in my router,
which is OpenWRT and do it from there. I have it set up on a cron
task to wake the server every five minutes so that if ever it stops
(after a power fail for example) it will automatically restart. The
WOL does no harm if it is already on.
Colin
More information about the ubuntu-users
mailing list