[Plugin] [CLOSED] WOL-PowerManager | Page 14

Discussion in 'MediaPortal 1 Plugins' started by jojo1411, November 12, 2010.

Thread Status:
Not open for further replies.
  1. Guzzi
    • Premium Supporter

    Guzzi Retired Team Member

    Joined:
    August 20, 2007
    Messages:
    2,161
    Likes Received:
    704
    Ratings:
    +922 / 0
    Well, WOL sould always be done with an IP address, not depending on a DNS name.
    Anyway, maybe you can ask Seppi via PM if he is still supporting ths plugin - if not, I'd suggest to e.g. commit the code to MP-Plugin repository, so it is available to the community - but best would be of course, if Seppi updates the current Repo and republishes an updated version ...


     
  2. Google AdSense Guest Advertisement



    to hide all adverts.
  3. Lehmden
    • Premium Supporter

    Lehmden Retired Team Member

    Joined:
    December 17, 2010
    Messages:
    11,946
    Likes Received:
    2,152
    Gender:
    Male
    Location:
    Lehmden
    Ratings:
    +3,636 / 28
    Home Country:
    Germany Germany
    Show System Specs
    Hi.
    I think Seppi is on vacation atm...
     
  4. GJC

    GJC Portal Pro

    Joined:
    March 10, 2012
    Messages:
    97
    Likes Received:
    11
    Gender:
    Male
    Ratings:
    +11 / 0
    Home Country:
    Canada Canada
    Sorry for the delay getting back to this problem, but it's been crazy at work these days.

    I don't see why any entry in the hosts file would be necessary if you have the "Use IP instead DNS name" option checked. All the hosts file does is convert the server name to an IP address locally, like a local lookup table, removing the need for DNS.

    I believe that the problem occurred because the broadcast address that was being used was 255.255.255.255, which, as I understand, requires the router to route the packet based on entries in the router's ARP table. If you have dd-wrt then you can add permanent entries to the ARP table to work around the problem, but that's not really the best solution.

    The fix that I provided uses the subnet mask to include the subnet in the broadcast IP. This way the broadcast doesn't need routing (which is why it works for wireless access points). As it is a broadcast to the entire subnet, there's no need to have the server's IP in any ARP table.

    I removed the entry in my hosts file and found that WOL still works fine with the new plug-in (where it used to be necessary). I'm surprised that your testing still shows it to be an issue. Did you have the "Use IP instead DNS name" option checked? You should leave this checked always IMO, why force a DNS lookup when you don't need to?

    As I can't reproduce the issue anymore, I'm afraid that I can't be of much further help. If you have anything you'd like me to try, then please let me know.
     
  5. Lehmden
    • Premium Supporter

    Lehmden Retired Team Member

    Joined:
    December 17, 2010
    Messages:
    11,946
    Likes Received:
    2,152
    Gender:
    Male
    Location:
    Lehmden
    Ratings:
    +3,636 / 28
    Home Country:
    Germany Germany
    Show System Specs
    Hi.
    For me there is no difference between "Use IP instead DNS name" option checked or not, as long as I don't have those entries in hosts. I always get this:
    wol-1.jpg

    BTW "Spock" is the name of my server. All my PC are named after Star Trek characters and my workgroup is called "Sternenflotte" (German for "Star Fleet")...
    No firewall is active, no AV software or something like that (only windows defender is there, but this should not do any harm).
    Here is my config:
    wol-2.jpg
    wol-3.jpg

    I've tried different ports for ping, did not help... The HTPC (Pille) is on IP 192.168.1.55 so it's in the same subnet, the same workgroup, the same router,...
    And ping is working from command prompt without any issues. Same is for WOL with WOLCMD.exe

    As soon as I modify the hosts all went well. So I definitely can live with this, as the modification don't do any harm at all. V0.3 has worked without the hosts modifications but I don't understand what's different...
     
  6. GJC

    GJC Portal Pro

    Joined:
    March 10, 2012
    Messages:
    97
    Likes Received:
    11
    Gender:
    Male
    Ratings:
    +11 / 0
    Home Country:
    Canada Canada
    Thanks for the feedback Lehmden.

    Ping won'twork if your server is asleep, so it's clearly not waking up. Can you please double-check the subnet on your router using ipconfig?

    Did you assign the server a static IP at the router (using the router configuration pages)? Leave your server TCP/IP configuration at DHCP, but go into your router setup and reserve IP 192.168.1.99 for the server. Set the WOL PowerManager back to port 7, check the "WOL on MediaPortal Startup" box then try again.
     
  7. Lehmden
    • Premium Supporter

    Lehmden Retired Team Member

    Joined:
    December 17, 2010
    Messages:
    11,946
    Likes Received:
    2,152
    Gender:
    Male
    Location:
    Lehmden
    Ratings:
    +3,636 / 28
    Home Country:
    Germany Germany
    Show System Specs
    Hi.
    It is definitely the same subnet with mask 255.255.255.0. All used IP addresses are starting with 192.168.1,xxx

    I always have static IP addresses. Fix on all PC and! all reserved in Router. DHCP normally is only for Smartphone (not able to give a fixed IP here) or guests. And DHCP IP Range starts at .101 so it can't collide with my fixed IP Addresses between .2 and .99. The router itself has .1

    I've done this at first. I've tried Port 0 only because it's the default Ping Port, but this did not change anything. If I had modified the hosts, Port 0 did work the same as Port 7, if I don't have modified the hosts Port 0 or 7, both did not work..
     
  8. GJC

    GJC Portal Pro

    Joined:
    March 10, 2012
    Messages:
    97
    Likes Received:
    11
    Gender:
    Male
    Ratings:
    +11 / 0
    Home Country:
    Canada Canada
    You can try turning on Debug level logging for MP and then look in the log for the word "broadcast". You can then verify that the broadcast address being used is 192.168.1.255.

    I don't have the 0.3 source code, so I can't compare sources to see what has changed. If WOLCMD successfully wakes the computer, then we are still probably doing something not quite correctly.

    I'm afraid that I'm at a bit of a loss at this point. If you have the source for 0.3, then please send it to me so that I can do a quick comparison.
     
  9. Lehmden
    • Premium Supporter

    Lehmden Retired Team Member

    Joined:
    December 17, 2010
    Messages:
    11,946
    Likes Received:
    2,152
    Gender:
    Male
    Location:
    Lehmden
    Ratings:
    +3,636 / 28
    Home Country:
    Germany Germany
    Show System Specs
    Hi.
    That could make things a lot easier, but I never have seen the source..

    Thank you very much for your work. Without this we couldn't use WolPowerManager on MP1.3 at all..
     
  10. GJC

    GJC Portal Pro

    Joined:
    March 10, 2012
    Messages:
    97
    Likes Received:
    11
    Gender:
    Male
    Ratings:
    +11 / 0
    Home Country:
    Canada Canada
    Hi Lehmden,

    Can you please reproduce the issue again with MP set to Debug log level and attach the MP logs? I revisited the code and there's a log message that may shed some light on this. It looks like the plug-in is trying to send a ping before attempting to wake the machine and the ping throws an exception, so the wake-up packet is never sent. I'm not sure why a ping is attempted before waking the server, but I'd like a bit more detail on the exception before I implement a fix.
     
  11. GJC

    GJC Portal Pro

    Joined:
    March 10, 2012
    Messages:
    97
    Likes Received:
    11
    Gender:
    Male
    Ratings:
    +11 / 0
    Home Country:
    Canada Canada
    Hi again Lehmden,

    Please give this version a try and let me know if it fixes the ping problem.[DOUBLEPOST=1345520591][/DOUBLEPOST]PS: This installer only installs the dll file, no xml configuration file. I think this should be ok as the configuration should display defaults for a new installation and create the xml file once the user saves the configuration.
     

    Attached Files:

Loading...
Thread Status:
Not open for further replies.

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!