Closed Lax4ever closed 1 year ago
On a raspberry pi running Raspbian 10 wakeonlan works for me if the user is a member of the netdev group. This is on a raspberry pi model 4 using the built-in ethernet. It is not working for me when I use a USB ethernet interface. This is true even when I specify the ip address of the target and that would have to be routed out the USB interface. (I see that there is a pull request that enables specifying the NIC, but haven't tried it yet). Note that the etherwake command from the etherwake package does work. It requires that the command be run with root privileges. I handled that by taking away read and execute permissions from other, changing the group to netdev, and making the command setuid root
chmod o= /usr/sbin/etherwake
chgrp netdev /usr/sbin/etherwake
chmod u+s /usr/sbin/etherwake
(The order of the commands matters because chgrp resets the setuid bit.) Then users in the netdev group can wake things using etherwake. From what I understand, on Linux this is not a big security issue, but it could be on other systems).
@Lax4ever does that answer your question?
I’m closing this issue, as it’s not actionable for this repository.
Trying to utilize a Raspberry Pi 4 as a wake on lan hub for other devices on my network. The following script works via Windows and via Ubuntu Server 18.04 but not via Raspian Buster.
When used on Raspbian, a permissions error occurs:
As you can see this is running via Python 3, I have tried running the script with
sudo
with the same results. Running it through an elevated Python 3 shell produces no error but also no result.I am not sure how to resolve since it works on Ubuntu Server and Windows. Any advice would be appreciated.