network icon indicating copy to clipboard operation
network copied to clipboard

RFE: Support wake on lan options

Open pcfe opened this issue 5 years ago • 3 comments

Wanting to switch from editing /etc/sysconfig/network-scripts/ifcfg-… I am wondering what the clean way to get

ETHTOOL_OPTS="wol g"

configured with linux-system-roles / network

The current README.md does not seem to contain either the string wol or the string wake.

Since enabling wake on LAN (p|u|m|b|a|g|s|f|d) is a rather common procedure, it would be nice if this was covered in the documentation of the module.

pcfe avatar Jan 25 '20 17:01 pcfe

I suspect it is not supported, support for some ethtool options was added in #115, but WOL does not seem to be among them. Documentation for those that are supported was added in that PR.

pcahyna avatar Jan 25 '20 18:01 pcahyna

yeah saw that and was surprised that WOL did not show up :-(

for now my workaround is

    # enable WOL manually until https://github.com/linux-system-roles/network/issues/150 is fixed
    - name: "ensure Wake On LAN is enable for the upper network card"
      lineinfile:
        path:         /etc/sysconfig/network-scripts/ifcfg-enp2s0
        create:       false
        regexp:       '^ETHTOOL_OPTS= '
        insertafter:  '^TYPE=Ethernet'
        line:         'ETHTOOL_OPTS="wol g"'

not pretty but it does the job.

pcfe avatar Jan 25 '20 19:01 pcfe

Yes, it is not supported. @pcfe are you interested in working on a patch?

tyll avatar Jan 25 '20 19:01 tyll