[User Help Wanted] - Wake On Lan support for MP2

Discussion in 'Testing Area' started by Brownard, January 23, 2017.

  1. Brownard
    • Team MediaPortal

    Brownard Development Group

    Joined:
    March 21, 2007
    Messages:
    1,911
    Likes Received:
    786
    Gender:
    Male
    Ratings:
    +1,318 / 1
    Home Country:
    United Kingdom United Kingdom
    Show System Specs
    What is this?
    A plugin to allow MP2 Clients to wake the MP2 Server machine automatically when a client starts/resumes from standby. Pending user feedback and testing it's planned to include this plugin in a future MP2 release.



    What are the prerequisites?
    1. You must be running the latest available version of MP2 (MP2.1 Pre-Release)
    2. The computer running the server must be able to be woken by WakeOnLan (WOL), this may require adjusting your network adapter settings and/or bios settings.
    3. The client must be located on a different computer to the server, the plugin deliberately has no effect if the client and server are located on the same computer
    How do I install it?
    1. Close the client
    2. Download and extract the attached WakeOnLanPlugin.zip
    3. Copy the extracted WakeOnLan.Client directory to the plugins directory of the client(s) (C:\Program Files (x86)\Team MediaPortal\MP2-Client\Plugins)
    4. Restart the client(s)


    How do I configure it?

    Configuration should be fully automatic, all that is required is that the client and server are connected at least once after the plugin has been installed, i.e.
    1. Start the client and server and ensure they are attached/connected. Wait a few seconds for the settings to sync ("WakeOnLanClient: Updating server hardware address for IP address..." should be logged by the client)
    2. Client should now wake the server during startup and when resuming if the server is asleep
    How do I test it?

    After installation and the configuration steps above have been completed, ensure that the client wakes the server from sleep/standby appropriately and that no other issues are present. Particular testing is needed in IPv6 network environments and ensuring that clients are automatically configured correctly.

    Branch
    JIRA

    Changelog v5 - 11/03/17 (open)

    • Remove server plugin, clients can now directly resolve the server hardware address
    • Wait for the network connection to become available before sending the WOL packet, default timeout is 20 seconds.

    Changelog v6 - 17/05/17 (open)

    • Fix choosing incorrect entry from IPNET table

    Changelog v7 - 30/05/17 (open)

    • Send WOL packet on all available interfaces
     

    Attached Files:

    Last edited: May 30, 2017
    • Like Like x 3
  2. Google AdSense Guest Advertisement



    to hide all adverts.
  3. BlueMax1916
    • Super User

    BlueMax1916 Super User

    Joined:
    January 29, 2007
    Messages:
    687
    Likes Received:
    60
    Ratings:
    +122 / 1
    Home Country:
    Germany Germany
    Show System Specs
    Hi @Brownard,

    I have installed the plugins on the server and on one client as described above. Log level set to ALL. I could not test the wake up function as the server is still alive but for a first impression here the log entries from the client's log:




    From the server's log:


    Cheers

    Blue Max
     
    • Like Like x 1
  4. BlueMax1916
    • Super User

    BlueMax1916 Super User

    Joined:
    January 29, 2007
    Messages:
    687
    Likes Received:
    60
    Ratings:
    +122 / 1
    Home Country:
    Germany Germany
    Show System Specs
    Hi @Brownard,

    unfortunately the WOL feature in an IPv4 network does not work for me. This morning was the first time where I had the cance to try tius and where the server was asleep and I fired up MP2.1 on the client. But the server would not respond. See attached logs of the client.

    My MP1 clients can wake up the server as the WOL feature there is working for it.


    Cheers

    Blue Max
     
  5. Brownard
    • Team MediaPortal

    Brownard Development Group

    Joined:
    March 21, 2007
    Messages:
    1,911
    Likes Received:
    786
    Gender:
    Male
    Ratings:
    +1,318 / 1
    Home Country:
    United Kingdom United Kingdom
    Show System Specs
    Thanks, I can see that it at least tries to wake the server which means it thinks its configured correctly
    Can you have a look in 'C:\ProgramData\Team MediaPortal\MP2-Client\Config\WakeOnLan.Client.Settings.WakeOnLanSettings.xml' and verify that the saved MAC address is correct? It's base64 encoded so you'd need to decode it first, you can do that online here.
    Otherwise there's a couple of changes I can try like using the same port as MP1 and sending the packet directly to the IP address, like MP1 does.
     
  6. BlueMax1916
    • Super User

    BlueMax1916 Super User

    Joined:
    January 29, 2007
    Messages:
    687
    Likes Received:
    60
    Ratings:
    +122 / 1
    Home Country:
    Germany Germany
    Show System Specs
    Hi @Brownard,

    the MAC address is garbage after decoding from Base64 into anything. For example a decode into ISO-8859-1 has this result:

    Code (Text):
    1. ¼_ôÇÕ
    But the Base64 encoded value also looks weird:
    Code (Text):
    1. vF/0x9UW
    But the IP address is the right one.


    Cheers

    Blue Max
     
  7. Brownard
    • Team MediaPortal

    Brownard Development Group

    Joined:
    March 21, 2007
    Messages:
    1,911
    Likes Received:
    786
    Gender:
    Male
    Ratings:
    +1,318 / 1
    Home Country:
    United Kingdom United Kingdom
    Show System Specs
    Thanks, that does actually look correct, the site I linked to was just a bit rubbish ;)
     
  8. Brownard
    • Team MediaPortal

    Brownard Development Group

    Joined:
    March 21, 2007
    Messages:
    1,911
    Likes Received:
    786
    Gender:
    Male
    Ratings:
    +1,318 / 1
    Home Country:
    United Kingdom United Kingdom
    Show System Specs
    @BlueMax1916 I've added a new build to first post, main change is that resends the WOL packet a couple of times if the server doesn't wake. In terms of the waking method it's pretty much identical to MP1 now.
     
  9. BlueMax1916
    • Super User

    BlueMax1916 Super User

    Joined:
    January 29, 2007
    Messages:
    687
    Likes Received:
    60
    Ratings:
    +122 / 1
    Home Country:
    Germany Germany
    Show System Specs
    Thanks, @Brownard, I have installed the new client and server plugin and will report how it works.

    Cheers

    Blue Max
     
  10. DomCash

    DomCash Portal Member

    Joined:
    January 10, 2010
    Messages:
    8
    Likes Received:
    3
    Ratings:
    +3 / 0
    Hello everybody!

    I would also like to jump into testing the new WOL feature. But first I've got one question regarding my foremost requirement for that feature: If you set the client asleep directly from MP2, then my server will also go into sleep mode a couple of minutes later.
    When you then rewake the client, MP2 is still open and doesn't necessarily recognize that the client just woke up. The server will be offline at that time.
    Will the WOL feature in this scenario also try to wake the server, even it is not a "fresh" start of MP2?

    Kind regards,
    DomCash
     
  11. HTPCSourcer
    • Team MediaPortal
    • Administrator

    HTPCSourcer MP2 Product Manager

    Joined:
    May 16, 2008
    Messages:
    10,584
    Likes Received:
    1,110
    Gender:
    Male
    Ratings:
    +2,384 / 21
    Home Country:
    Germany Germany
    Show System Specs
    Yes, it will.
     
Loading...

Users Viewing Thread (Users: 0, Guests: 0)

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice
  • About The Project

    The vision of the MediaPortal project is to create a free open source media centre application, which supports all advanced media centre functions, and is accessible to all Windows users.

    In reaching this goal we are working every day to make sure our software is one of the best.

             

  • Support MediaPortal!

    The team works very hard to make sure the community is running the best HTPC-software. We give away MediaPortal for free but hosting and software is not for us.

    Care to support our work with a few bucks? We'd really appreciate it!