stapelberg / zkj-nas-tools

NAS (Network Attached Storage) related tools
Other
53 stars 4 forks source link

qcontrol wakeonlan -> qcontrol wol #2

Closed hartkopp closed 9 years ago

hartkopp commented 9 years ago

Hi Michael,

thanks for your great information, mainline commits and scripts to tune up the QNAP wake-on-lan handling!

I'm running a Debian Jessie with Linux 3.16 on my TS-219 P II with qcontrol 0.5.4 and tried your wol-shutdown.service with it. Obviously qcontrol changed its command line parameter for wake-on-lan:

wol-shutdown.service - Enable Wake on LAN on shutdown Loaded: loaded (/etc/systemd/system/wol-shutdown.service; enabled) Active: failed (Result: exit-code) since Do 2015-03-26 19:10:49 CET; 7s ago Process: 956 ExecStart=/usr/sbin/qcontrol wakeonlan off (code=exited, status=255) Process: 955 ExecStart=/sbin/ethtool -s eth0 wol d (code=exited, status=0/SUCCESS) Main PID: 956 (code=exited, status=255)

Mär 26 19:10:49 hostname qcontrol[956]: Command not found

It was just renaming 'wakeonlan' to 'wol' in that script to make it work.

wol-shutdown.service - Enable Wake on LAN on shutdown Loaded: loaded (/etc/systemd/system/wol-shutdown.service; enabled) Active: active (exited) since Do 2015-03-26 19:11:44 CET; 3s ago Process: 980 ExecStart=/usr/sbin/qcontrol wol off (code=exited, status=0/SUCCESS) Process: 979 ExecStart=/sbin/ethtool -s eth0 wol d (code=exited, status=0/SUCCESS) Main PID: 980 (code=exited, status=0/SUCCESS)

So maybe you can change that or provide two scripts or do some magic version detection :-)

Best regards, Oliver

stapelberg commented 9 years ago

Sorry for the late reply, I wasn’t watching this repository on GitHub accidentally :(.

Thanks for the hint, I’ll push a fix.