Hi there Guys,
I am very new to all this stuff and I have been running a WOLServer on my Raspian Pi Build but then, I stumbled across DietPi which seems to be brilliant!!! (But as I said I am new and know nothing literally) I have followed the exact same setup instructions for setting up the WOL Server on my DietPi build and it all seems to have gone smoothly however it doesn’t work in that I can access the WOL Servers web UI but when i enter my details it doesn’t send the magic packet to wake any of my PC / Servers 
Here is the article that i followed and it has been working perfectly on my Raspian Built Raspberry Pi,
https://github.com/sciguy14/Remote-Wake-Sleep-On-LAN-Server/wiki/Installation
The only thing I had to change to get this to install and work on my previous build was to install a newer version of PHP from 5 to 7.0
Can anyone help me figure this out or is there something within DietPi that would stop this working?
Many Many thanks in advance Jurgen 
I’ve been using this method for years and it works with DietPi (at least on v159 which I never upgraded as it is very stable).
https://www.jeremyblum.com/2013/07/14/rpi-wol-server/
John
Hi there Johnvick
That is exactly the one that I have been using and now I have set it up on the dietpi installation and it can get to the WOL Server website and can tell me which machines are asleep and awake but when trying to put a machine to sleep or wake it never seems to send the WOL command to the requested PC
I have no idea why as it has worked perfectly on my other build 
I think it may be a firewall thing but I cannot remember what I had to enable before? do you know of anything yourself?
Many thanks Jurgen
Hi there John,
Scrub my last reply as I reverted everything back to how it was as far as Firewall and adapter settings etc as it did work on my previous Raspian Pi Build and nothing has changed there at all, so to prove this I re-inserted my Raspian build with the same WOL Server on it and it worked perfectly, so the issue seems to lay with how the Dietpi is messing something up all be it the SSL is working as I can get to the WOL Server web page and I can query any 1 of the 3x PC’s I have on my network and I can see if they are awake or asleep and I can now seem to put them to sleep however I cannot wake them up
so anymore thought that you or anyone else may have on this subject would be greatly appreciated 
Maybe someone from DietPi themselves could take a look as the version is now v6.2 and the version that Johnvick is suggesting is v159?
Kind regards Jurgen.

Jurgiebaby
Okay lets check:
- With the same remote and network setup, just a Raspbian Lite machine as WOL server (using the exact same setup steps) works fine?
- Can you give some more details which setup steps you did? I ended up at https://github.com/sciguy14/Remote-Wake-Sleep-On-LAN-Server/wiki/Installation, but most of the steps are not required and would conflict other dietpi-software-based installs. It also messes quite much with default Debian installs, e.g. putting SSL and non-SSL vhost in a single config file and overwriting/editing a bunch other default Apache configs that have nothing to do with WOL, very intrusive. I will try to identify the essential settings required to get this running.
Hi there MichaIng
that is the exact article that i have followed on my old Raspian Based Pi Install as well as the new DietPi install so I have completed all of the steps mentioned in that post and as I mentioned on an earlier reply it works perfectly on my older Raspian Built Pi and on the Diet Pi I seem to be able to sleep a PC but cannot wake any PC from this WOL Server.
Thank you very much for your help it’s really appreciated for sure as I am rubbish with this stuff especially when it goe’s wrong lol
I am looking forward to hearing back from you regards this issue MichaIng
Jurgen.
Hi there MichaIng
Have you had a chance to look at this issue as yet? I tried a fresh new build of dietpi last night on a new SD Card and only installed this WOL Server and it did the same again, it’s so strange as the website works perfectly but it only has an issue with sending the WOL Command to wake the PCs up 
I will try and do some more testing tonight as well 
Many thanks.
Sorry had much to do on GitHub, always distracted by other things. To have this closer to my view I opened up an GitHub issue: https://github.com/MichaIng/DietPi/issues/2596
Jurgiebaby
Is the topic still valid for you and did you follow the discussion on GitHub?
To sum it up:
- WOL generally seems to require an Ethernet connection on both ends.
- wakeonlan requires netbase to be installed, so run once: G_AGI netbase
- If for whatever reason wakeonlan does still not work on your system (on ours it does), try the following the override the wakeonlan command with etherwake:
echo -e '#!bin/dash\nsudo etherwake $@' > /usr/local/bin/wakeonlan
chmod +x /usr/local/bin/wakeonlan
echo 'www-data ALL=NOPASSWD: ALL' > /etc/sudoers.d/www-data
- “sudo” is required since etherwake (other then wakeonlan) requires root permission to be executed. The basic command argument for both is the MAC address. RWSOLS web UI does not execute “wakeonlan” with any additional argument, so this should work.