Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

[PLUGIN] WOL for Services

Featured Replies

EDIT: PLEASE IGNORE - ALL SEEMS TO BE WORKING NOW!

 

I'm trying to get this to work on a couple of Win 11 VMs that I have, but have been unable to wake the VMs from my Win 10 PC. I use a WOL utility that works fine with other physical PCs and I can "see" the VMs on it, just can't wake them. Is there anything I need to set up on the VM side?

 

If it's relevant, for the VMs, Network Source is br0 and Network Model is e1000. When I look inside the VMs at the network adapter (comes up as Intel PRO/1000 MT) properties, there doesn't seem to be an option for Wake on Magic Packet and the "Allow this device to wake the computer" option is greyed out. Perhaps I'm totally misunderstanding how WOL works for VMs.

 

I read about a libvirt WOL option, but it looks like that was a plug-in that is now no longer available on the app store.

 

Diagnostics are attached in case they're helpful.

t2-diagnostics-20240709-0925.zip

Edited by sonofdbn
WOL is working now

  • 2 weeks later...
  • Replies 66
  • Views 16.3k
  • Created
  • Last Reply

Top Posters In This Topic

Most Popular Posts

  • Open terminal.   cd /boot/extra if does not exist mkdir /boot/extra then cd to it. Once it is downloaded into extra will be loaded each reboot   root@computenode:/boot/extra# wget

  • Unraid uses the php api. I can look at managed save as a option which is hibernate to disk   libvirt_domain_suspend libvirt_domain_suspend($res) [Since version 0.4.1(-1)] Func

  • Hi I did a quick test on my test server. I dont use HA except for testing this is what i have added to my yaml.   wake_on_lan: switch: - platform: wake_on_lan mac: 52:54:00:DA:18:68

Posted Images

Just wanted to say thanks for this plugin! It works perfectly for my simple use case of starting a VM with a WOL packet from my phone.

 

I was using dmacias wake-on-lan plugin that required an additional pyton2 plugin to run on newer unraid versions. But after the upgrade to unraid 6.12.11 the python plugin did not install anymore and the WOL plugin stopped working.

  • 2 weeks later...

How can i get this to work?

 

i did try to add the Yaml to my HA automation. but when i add the code im getting error

Message malformed: required key not provided @ data['trigger'][0]['platform']

I took  from 1 of the posted here and eddited the mac and name

 

Quote

    alias: WOL_Win10VM
    description: ""
    trigger:
      - platform: state
        entity_id:
          - input_button.win10vm_boot
    condition: []
    action:
      - service: wake_on_lan.send_magic_packet
        metadata: {}
        data:
          broadcast_port: 9
          mac: 52:54:00:78:32:c0
    mode: single

 

6 hours ago, KoNeko said:

How can i get this to work?

 

i did try to add the Yaml to my HA automation. but when i add the code im getting error

Message malformed:

i would suggest to ask these questions in the proper places, like HA Forums, or at least the HA docker thread, not related to this plugin here ...

  • 2 weeks later...

Hello,

 

I got this Plugin to work with homeassistant's WOL function for turning ON an Ubuntu VM.  

 

However, I could not get the shutdown function to work.  Is there any trick to this?  In general, I am not familiar with how WOL does a shutdown....

  • Author
1 hour ago, chilman408 said:

Hello,

 

I got this Plugin to work with homeassistant's WOL function for turning ON an Ubuntu VM.  

 

However, I could not get the shutdown function to work.  Is there any trick to this?  In general, I am not familiar with how WOL does a shutdown....

Have you enabled in the settings and then set the vm from enabled to the shutdown enabled option?

 

image.pngimage.png

Yes, in the settings, I have enabled Yes on the "Enable Shutdown / Suspend Action".  Do I need to copy the "Suspend Command" setting as well? I didn't do that part.

  • Author
Just now, chilman408 said:

Yes, in the settings, I have enabled Yes on the "Enable Shutdown / Suspend Action".  Do I need to copy the "Suspend Command" setting as well? I didn't do that part.

No if using shutdown. But also goto tools->Wol 4 services and set the shutdown option against the vm. Will only be enabled by default. Needs to. be set to enabled and shutdown.

Thx for the quick reply!

 

Yes, I have set the setting under Tools as well to have "Enable and Shutdown".  Then I created a switch in HA.  Turning on this switch turns the VM on and switching off the switch does not do anything.

  • Author
5 minutes ago, chilman408 said:

Thx for the quick reply!

 

Yes, I have set the setting under Tools as well to have "Enable and Shutdown".  Then I created a switch in HA.  Turning on this switch turns the VM on and switching off the switch does not do anything.

What messages do you see in the log?

Good question, when I switch off the HA switch, nothing.

 

Switch On shows this:

Aug 14 14:11:54 UNRAID-R7-98TB Unraidwold[3458011]: 2024/08/14 14:11:54 Found 52:xx:xx:xx:xx:xx VM HomeLab
Aug 14 14:11:56 UNRAID-R7-98TB kernel: br0: port 3(vnet6) entered learning state
Aug 14 14:11:58 UNRAID-R7-98TB kernel: br0: port 3(vnet6) entered forwarding state
Aug 14 14:11:58 UNRAID-R7-98TB kernel: br0: topology change detected, propagating

 

  • Author
14 minutes ago, chilman408 said:

Good question, when I switch off the HA switch, nothing.

 

Switch On shows this:

Aug 14 14:11:54 UNRAID-R7-98TB Unraidwold[3458011]: 2024/08/14 14:11:54 Found 52:xx:xx:xx:xx:xx VM HomeLab
Aug 14 14:11:56 UNRAID-R7-98TB kernel: br0: port 3(vnet6) entered learning state
Aug 14 14:11:58 UNRAID-R7-98TB kernel: br0: port 3(vnet6) entered forwarding state
Aug 14 14:11:58 UNRAID-R7-98TB kernel: br0: topology change detected, propagating

 

So looks like switch does not send wol packet when it is turned off. I am mot an HA expert so not sure how to fix that.

 

https://www.home-assistant.io/integrations/wake_on_lan/

Yes, you are right.  Sending another WOL packet via some other means trigger the shutdown.

  • 4 weeks later...

is there an executable binary to WOL by script or do we use WOLrun.php and WOL.php?

 

Thanks,

JD

  • Author
19 minutes ago, JudasD said:

is there an executable binary to WOL by script or do we use WOLrun.php and WOL.php?

 

Thanks,

JD

This plugin listerns for magic packets to start dockers lxc or vms. What are you looking to do?

14 minutes ago, SimonF said:

This plugin listerns for magic packets to start dockers lxc or vms. What are you looking to do?

 

I am looking to send the actual magic packets.  I was using etherwake for my magic packets, which was installed by the previous WOL plug-in (now deprecated).   However, etherwake gets removed when the plug-in is uninstalled.  Is is possible for WOL4services to generate the magic packet?

 

Thanks,

JD

  • Author
12 minutes ago, JudasD said:

 

I am looking to send the actual magic packets.  I was using etherwake for my magic packets, which was installed by the previous WOL plug-in (now deprecated).   However, etherwake gets removed when the plug-in is uninstalled.  Is is possible for WOL4services to generate the magic packet?

 

Thanks,

JD

No. Will look to see if I can find a package

  • Author
3 minutes ago, SimonF said:

No. Will look to see if I can find a package

Open terminal.

 

cd /boot/extra if does not exist mkdir /boot/extra then cd to it. Once it is downloaded into extra will be loaded each reboot

 

root@computenode:/boot/extra# wget https://raw.githubusercontent.com/dmacias72/unRAID-WOL/master/packages/etherwake-1.09-x86_64-5cf.txz
--2024-09-09 20:30:49-- https://raw.githubusercontent.com/dmacias72/unRAID-WOL/master/packages/etherwake-1.09-x86_64-5cf.txz
Resolving raw.githubusercontent.com (raw.githubusercontent.com)... 185.199.108.133, 185.199.110.133, 185.199.109.133, ...
Connecting to raw.githubusercontent.com (raw.githubusercontent.com)|185.199.108.133|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 7956 (7.8K) [application/octet-stream]
Saving to: ‘etherwake-1.09-x86_64-5cf.txz’

etherwake-1.09-x86_64-5cf.txz                 100%[================================================================================================>]   7.77K  --.-KB/s    in 0.001s  

2024-09-09 20:30:49 (8.07 MB/s) - ‘etherwake-1.09-x86_64-5cf.txz’ saved [7956/7956]

root@computenode:/boot/extra# installpkg etherwake-1.09-x86_64-5cf.txz 
Verifying package etherwake-1.09-x86_64-5cf.txz.
Installing package etherwake-1.09-x86_64-5cf.txz:
PACKAGE DESCRIPTION:
# etherwake
#
# You can wake up WOL compliant Computers which have been powered down
# to sleep mode or start WOL compliant Computers with a BIOS feature.
# WOL is an abbreviation for Wake-on-LAN. It is a standard that allows
# you to turn on a computer from another location over a network 
# connection. etherwake also supports WOL passwords. 
#
Package etherwake-1.09-x86_64-5cf.txz installed.
root@computenode:/boot/extra# etherwake
Specify the Ethernet address as 00:11:22:33:44:55.
root@computenode:/boot/extra# 

8 minutes ago, SimonF said:

Open terminal.

 

cd /boot/extra if does not exist mkdir /boot/extra then cd to it. Once it is downloaded into extra will be loaded each reboot

 

root@computenode:/boot/extra# wget https://raw.githubusercontent.com/dmacias72/unRAID-WOL/master/packages/etherwake-1.09-x86_64-5cf.txz
--2024-09-09 20:30:49-- https://raw.githubusercontent.com/dmacias72/unRAID-WOL/master/packages/etherwake-1.09-x86_64-5cf.txz
Resolving raw.githubusercontent.com (raw.githubusercontent.com)... 185.199.108.133, 185.199.110.133, 185.199.109.133, ...
Connecting to raw.githubusercontent.com (raw.githubusercontent.com)|185.199.108.133|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 7956 (7.8K) [application/octet-stream]
Saving to: ‘etherwake-1.09-x86_64-5cf.txz’

etherwake-1.09-x86_64-5cf.txz                 100%[================================================================================================>]   7.77K  --.-KB/s    in 0.001s  

2024-09-09 20:30:49 (8.07 MB/s) - ‘etherwake-1.09-x86_64-5cf.txz’ saved [7956/7956]

root@computenode:/boot/extra# installpkg etherwake-1.09-x86_64-5cf.txz 
Verifying package etherwake-1.09-x86_64-5cf.txz.
Installing package etherwake-1.09-x86_64-5cf.txz:
PACKAGE DESCRIPTION:
# etherwake
#
# You can wake up WOL compliant Computers which have been powered down
# to sleep mode or start WOL compliant Computers with a BIOS feature.
# WOL is an abbreviation for Wake-on-LAN. It is a standard that allows
# you to turn on a computer from another location over a network 
# connection. etherwake also supports WOL passwords. 
#
Package etherwake-1.09-x86_64-5cf.txz installed.
root@computenode:/boot/extra# etherwake
Specify the Ethernet address as 00:11:22:33:44:55.
root@computenode:/boot/extra# 

 

Thank you so much, this worked perfectly!

 

JD

 

  • 3 weeks later...

Would it be possible to have a restart option in addition to shutdown and suspend?

  • Author
12 hours ago, dexn said:

Would it be possible to have a restart option in addition to shutdown and suspend?

Will look at adding an option.

  • Author
On 9/28/2024 at 10:38 PM, dexn said:

Would it be possible to have a restart option in addition to shutdown and suspend?

Restart added. 2024.09.30

  • 1 month later...

Hi,

 

Thank you very much for your work.

The plugin works as it should. I am almost only connected to my server via VPN, so the question is whether the plugin could be extended so that it can listen to other interfaces?

Like wireguard (wg0), for example.

Would it be possible to simply adjust the wol.cfg to achieve this?

The service probably needs to be restarted via the CLI?

  • Author
3 minutes ago, Orkopaede said:

Hi,

 

Thank you very much for your work.

The plugin works as it should. I am almost only connected to my server via VPN, so the question is whether the plugin could be extended so that it can listen to other interfaces?

Like wireguard (wg0), for example.

Would it be possible to simply adjust the wol.cfg to achieve this?

The service probably needs to be restarted via the CLI?

So you want to have both wg0 and eth0 for example?

10 minutes ago, SimonF said:

So you want to have both wg0 and eth0 for example?

Not necessarily, but if there was a choice, it would make things even more convenient. For my specific case, wg0 or, more precisely, wg1 would be enough.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.