Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Cron for WOL

    Scheduled Pinned Locked Moved General pfSense Questions
    24 Posts 7 Posters 6.1k Views 5 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • GertjanG Offline
      Gertjan @Bob.Dig
      last edited by Gertjan

      @bob-dig

      If your "device without IP" ( serious ?? see below ) is some windows device, try this :

      https://www.depicus.com/wake-on-lan/wake-on-lan-monitor

      b5d92fac-bb97-4596-928d-944c68793f6e-image.png

      I had to indicate a port number like "40000" on both side so the command line works :

      wol -i 192.168.1.2 00:4e:01:ac:ca:9c -p 4000
      Waking up 00:4e:01:ac:ca:9c...
      

      The tool on the device, my PC, that it received the special pachet (5 times the device MAC as the data payload)

      See also the FreeBSD mn page for wol https://www.freebsd.org/cgi/man.cgi?query=wol&manpath=ports&sektion=1

      edit : a device in lower power mode doesn't have - use an IP(v4 or v6).
      It just listens to the incoming data stream, and knows how to detect if it's won MAC is present 5 times in a row. No processor power is needed.

      wol needs a IP or host just to so it can find out on what interface to use if it is "multi homed", like our pfSense. The actual IP shouldn't matter ......
      But .....
      I think © that our switches play an important role here. Switches are not hubs, so traffic isn't broadcasted any more.
      When I use the broadcast IP of my LAN, like :

      wol -i 192.168.1.255 -p 4000 00:4e:01:ac:ca:9c
      

      it worked, the Wake On Lan monitor on my PC showed the incoming magic packet.

      No "help me" PM's please. Use the forum, the community will thank you.
      Edit : and where are the logs ??

      Bob.DigB 1 Reply Last reply Reply Quote 2
      • Bob.DigB Offline
        Bob.Dig LAYER 8 @Gertjan
        last edited by Bob.Dig

        @gertjan I want to use wol (not pattern match?) for this. I ended up using wol.exe on another Windows host together with windows tasksheduler to achieve what pfSense couldn't do for me. 🙂

        GertjanG 1 Reply Last reply Reply Quote 0
        • GertjanG Offline
          Gertjan @Bob.Dig
          last edited by

          @bob-dig I edited - see above.

          No "help me" PM's please. Use the forum, the community will thank you.
          Edit : and where are the logs ??

          Bob.DigB 1 Reply Last reply Reply Quote 1
          • Bob.DigB Offline
            Bob.Dig LAYER 8 @Gertjan
            last edited by Bob.Dig

            @gertjan So this time I tried in putty:

            /usr/local/bin/wol -v -i 192.168.1.255 d0:50:99:92:11:e7
            
            

            And it did work. Then I tried cron, also does work!

            So the key is to use .255 at the end.

            I still wonder why the web-GUI-thingy works with the MAC only, but on the other hand, when I first added the host to the Wake-on-LAN Devices list, it had an IP-address, so it might have saved it there.

            Thank you @Gertjan !!

            1 Reply Last reply Reply Quote 0
            • First post
              Last post
            Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.