How to Shutdown Mint for WOL

Questions about Wi-Fi and other network devices, file sharing, firewalls, connection sharing etc
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
BernysPeur
Level 1
Level 1
Posts: 18
Joined: Wed Nov 07, 2012 3:27 pm

How to Shutdown Mint for WOL

Post by BernysPeur »

Hello,

I have dual boot system Mint 13 / Win7
I've managed to configure my PC for wake-on-lan and it works when the PC has been shut down by WIN7.

When it's been shut down with Mint the PC will not wake up with Magic packet.

I have read a lot about ethtool and I thought I've done everything to properly configure the LAN board.

Here is what "sudo ethtool eth0" gives :

Code: Select all

Settings for eth0:
	Supported ports: [ TP MII ]
	Supported link modes:   10baseT/Half 10baseT/Full 
	                        100baseT/Half 100baseT/Full 
	Supported pause frame use: No
	Supports auto-negotiation: Yes
	Advertised link modes:  10baseT/Half 10baseT/Full 
	                        100baseT/Half 100baseT/Full 
	Advertised pause frame use: Symmetric Receive-only
	Advertised auto-negotiation: Yes
	Link partner advertised link modes:  10baseT/Half 10baseT/Full 
	                                     100baseT/Half 100baseT/Full 
	Link partner advertised pause frame use: Symmetric
	Link partner advertised auto-negotiation: Yes
	Speed: 100Mb/s
	Duplex: Full
	Port: MII
	PHYAD: 0
	Transceiver: internal
	Auto-negotiation: on
	Supports Wake-on: pumbg
	Wake-on: g
	Current message level: 0x00000033 (51)
			       drv probe ifdown ifup
	Link detected: yes
So if I understand, WOL is supported because of Supports Wake-on: pumbg
and WOL is enabled because of Wake-on: g

But still I does not wake up. Thought It does when I've shut down with Win7.

What am I doing wrong?
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
martywd
Level 3
Level 3
Posts: 147
Joined: Sun May 08, 2011 10:35 am
Location: TX

Re: How to Shutdown Mint for WOL

Post by martywd »

BernysPeur wrote:Hello,

I have dual boot system Mint 13 / Win7
I've managed to configure my PC for wake-on-lan and it works when the PC has been shut down by WIN7.

When it's been shut down with Mint the PC will not wake up with Magic packet.

I have read a lot about ethtool and I thought I've done everything to properly configure the LAN board.

....

But still I does not wake up. Thought It does when I've shut down with Win7.

What am I doing wrong?
I have a dual boot machine (now) running LM 13 Maya MATE (32-bit) and Win 7. Like your situation WOL worked in Windows but not when booted into *nix.

To get WOL to work on this particular machine I had to edit the:==> '/etc/network/interfaces' file. The line I added was:==> ethtool -s eth0 wol g

Speciifically the contents of my '/etc/network/interfaces' on that particular machine looks like this:

Code: Select all

auto lo
iface lo inet loopback

ethtool -s eth0 wol g

Editing must be done as 'root' or using the 'sudo ...' or 'gksu ...' command with your preferred text editor, of course.
After edit, REBOOT into Mint to see if this fixes your issue.

FWIW, I have found that some machines seem to require this edit to work, others _do_not_. I guess it depends on the motherboard?

.
BernysPeur
Level 1
Level 1
Posts: 18
Joined: Wed Nov 07, 2012 3:27 pm

Re: How to Shutdown Mint for WOL

Post by BernysPeur »

I already tried this, but it did not help.
As far as I understand, you have to execute

Code: Select all

ethtool -s eth0 wol g
when "sudo ethtool eth0" returns

Code: Select all

...
Wake-on: d
...
But I think I do not have to because ethtool already return

Code: Select all

...
Wake-on: g
...
User avatar
martywd
Level 3
Level 3
Posts: 147
Joined: Sun May 08, 2011 10:35 am
Location: TX

Re: How to Shutdown Mint for WOL

Post by martywd »

BernysPeur wrote:I already tried this, but it did not help.
It's unfortunate that you failed to mentioned this detail in your original post. It would have saved me some typing. ;-)
when "sudo ethtool eth0" returns

Code: Select all

    ...
    Wake-on: d
    ...
WHAT? That result indicates that your NIC's WOL functionality is Disabled! That's not good. And would explain why WOl is not working for you.
But I think I do not have to because ethtool already return

Code: Select all

    ...
    Wake-on: g
...
You can 'think' that if you like? But if when booted into Mint, you run 'sudo ethtool eth0' and get result:

Code: Select all

Wake-on: d
Then something is changing your NIC's WOL state to 'Disable'? What's causing this change?

I suggest you spend some time reading over the man for 'ethtool'

Code: Select all

man ethtool
.
BernysPeur
Level 1
Level 1
Posts: 18
Joined: Wed Nov 07, 2012 3:27 pm

Re: How to Shutdown Mint for WOL

Post by BernysPeur »

Ok, so it seems I was not clear enough in my second post.

So I retype :

I already tried this, but it did not help.
As far as I understand, you have to execute "ethtool -s eth0 wol g" when "sudo ethtool eth0" returns "Wake-on: d".
But this is not my case, so I think I do not have to execute "ethtool -s eth0 wol g" because "sudo ethtool eth0" already returns "Wake-on: g"


Is it more understandable? :)
Anyway in my first post you can see what "sudo ethtool eth0" returns for me.
Any other suggestion?

Thanks
User avatar
martywd
Level 3
Level 3
Posts: 147
Joined: Sun May 08, 2011 10:35 am
Location: TX

Re: How to Shutdown Mint for WOL

Post by martywd »

BernysPeur wrote:As far as I understand, you have to execute "ethtool -s eth0 wol g" when "sudo ethtool eth0" returns "Wake-on: d".
No! Not necessarily! It is entirely possible that 'ethtool eth0' gives output that 'looks' right but still exhibits disabled WOL NIC functionality.

Try this on the machine you want to 'wake up' remotely. Open a 'Terminal' window and run:

Code: Select all

sudo ethtool -s eth0 wol g
Next put that machine in 'suspend' mode. Then from another machine on the same LAN (and preferably the same subnet) run a WOL client.

Be absolutely sure the MAC address used by your WOL client app corresponds to the MAC address on the NIC in the machine you are attempting to wake up!

For example. On a second *nix machine on my LAN, the WOL client command I use looks like this:

Code: Select all

wakeonlan 6C:62:6D:C3:B2:A9
With that command my suspended machine with MAC address: 6C:62:6D:C3:B2:A9 , 'wakes up'.

Let me know your results?

.
BernysPeur
Level 1
Level 1
Posts: 18
Joined: Wed Nov 07, 2012 3:27 pm

Re: How to Shutdown Mint for WOL

Post by BernysPeur »

Ok,

I have tried what you suggested:

first "sudo ethtool -s eth0 wol g"
then put computer in suspend mode

Then send a WOL magic packet from another computer in the same LAN and in the same subnet. (computer to wake up is 192.168.0.105 and computer sending magic packet is 192.168.0.115)

The computer did not exit the suspend mode (did not wake up).

Then I've tried with Windows 7 (just to verify I used the right MAC address) : just shutdown the computer in a normal way with Win7,
then send the magic packet with exactly the same procedure => Then the computer woke up (then started in bios, then grub, then booted OS)

So it seems Windows 7 is shutting down the computer in a way that it can be wake up with a WOL magic packet and Mint Does not, even if I execute "sudo ethtool -s eth0 wol g" before putting in suspend mode or shutting down with Mint.

Another idea?
Thanks anyway for your help :)
User avatar
martywd
Level 3
Level 3
Posts: 147
Joined: Sun May 08, 2011 10:35 am
Location: TX

Re: How to Shutdown Mint for WOL

Post by martywd »

BernysPeur wrote:So it seems Windows 7 is shutting down the computer in a way that it can be wake up with a WOL magic packet and Mint Does not, even if I execute "sudo ethtool -s eth0 wol g" before putting in suspend mode or shutting down with Mint.
Interesing that you would type that because wtih regard to the NIC issues on my dual-boot machine I've noticed that Windows 7 seems to shutdown the power to the NIC, even when rebooting?

Now obviously in your Mint build the NIC is powered since you have networking(!) so any pondering as to whether or not Windows 7 is the cause of your lack off WOL in *nix would be purely speculitive at this point.

Is this a hardware issue or a software issue for you? Or both? Unfortunately, I am at at a loss to say?

I've search through my bookmarks for any WOL help I might have found when originally researching my WOL issues. Although what I've found seems to be ground already covered here? But take a look anyway:

==> https://help.ubuntu.com/community/WakeOnLan
==> http://ubuntuforums.org/showthread.php? ... hlight=wol

Sorry I couldn't solve this issue for you. :-(

.
BernysPeur
Level 1
Level 1
Posts: 18
Joined: Wed Nov 07, 2012 3:27 pm

Re: How to Shutdown Mint for WOL

Post by BernysPeur »

Does anyone have a solution to my problem?
teigaff

Re: How to Shutdown Mint for WOL

Post by teigaff »

On my VIA Epia EN-1500G I've the same network chip.
When computer is going off, the nic would first turned off. Than computer will power off. You have to be sure, your NIC would not turn off.
Doing this just edit your /etc/init.d/halt and add these lines:

NETDOWN=no


ip link set eth0 up
# The next two lines followes after the command above. Now you know, where to insert the line.
log_action_msg "Will now halt"
halt -d -f $netdown $poweroff $hddown
goog64

Re: How to Shutdown Mint for WOL

Post by goog64 »

teigaff wrote:On my VIA Epia EN-1500G I've the same network chip.
When computer is going off, the nic would first turned off. Than computer will power off. You have to be sure, your NIC would not turn off.
Doing this just edit your /etc/init.d/halt and add these lines:

NETDOWN=no


ip link set eth0 up
# The next two lines followes after the command above. Now you know, where to insert the line.
log_action_msg "Will now halt"
halt -d -f $netdown $poweroff $hddown
Did this help?
My problem is my laptop will only wake on lan during the first few minutes after being suspended. Any longer than that and it won't wake up. What could be happening?
Locked

Return to “Networking”