Wake on LAN

sizeonsizeon Member Posts: 321
Does anybody here use a software that powers on a pc in a domain if it's off?

Comments

  • QordQord Senior Member Member Posts: 632 ■■■■□□□□□□
    I've had mixed results with wol.exe, powershell, and the wake on lan utility from solarwinds.
  • techfiendtechfiend Member Posts: 1,481 ■■■■□□□□□□
    WakeMeOnLan has worked well for me, the gui looks like it's from the 90's but the cli is pretty powerful yet simple.
    2018 AWS Solutions Architect - Associate (Apr) 2017 VCAP6-DCV Deploy (Oct) 2016 Storage+ (Jan)
    2015 Start WGU (Feb) Net+ (Feb) Sec+ (Mar) Project+ (Apr) Other WGU (Jun) CCENT (Jul) CCNA (Aug) CCNA Security (Aug) MCP 2012 (Sep) MCSA 2012 (Oct) Linux+ (Nov) Capstone/BS (Nov) VCP6-DCV (Dec) ITILF (Dec)
  • Vask3nVask3n Member Posts: 517
    sizeon wrote: »
    Does anybody here use a software that powers on a pc in a domain if it's off?

    I don't think it matters whether the machine is in a domain or not, basically these WoL scripts run by sending magic packets to a MAC address, so they are link-local. I used to have 3 scripts, one per subnet, that would iterate through every MAC in the subnet and wake them up, then repeat for the other subnets.

    Of course its kind of a chicken/egg problem because you first need to inventory every MAC address and also make sure WoL is enabled in the BIOS and/or Windows (there is a WoL setting under your network adapter), which means you are basically visiting every machine at least once to get the whole process set up to begin with.

    For what it's worth I used Vitaly Evseenko's script, wherever it's hosted nowadays.
    Working on MS-ISA at Western Governor's University
  • techfiendtechfiend Member Posts: 1,481 ■■■■□□□□□□
    That sounds like a lot of work Vask3n. How about turning off all machines, using 1 command to wake all or enter an ip range and troubleshoot the ones that don't come up? I realize this isn't possible with mc-wol.
    2018 AWS Solutions Architect - Associate (Apr) 2017 VCAP6-DCV Deploy (Oct) 2016 Storage+ (Jan)
    2015 Start WGU (Feb) Net+ (Feb) Sec+ (Mar) Project+ (Apr) Other WGU (Jun) CCENT (Jul) CCNA (Aug) CCNA Security (Aug) MCP 2012 (Sep) MCSA 2012 (Oct) Linux+ (Nov) Capstone/BS (Nov) VCP6-DCV (Dec) ITILF (Dec)
  • Vask3nVask3n Member Posts: 517
    techfiend wrote: »
    That sounds like a lot of work Vask3n. How about turning off all machines, using 1 command to wake all or enter an ip range and troubleshoot the ones that don't come up? I realize this isn't possible with mc-wol.

    That is actually the process I followed, I didn't really elaborate on it above. Here is a more detailed explanation of my process:

    Bear in mind I used this with a tool that only accepts MACs as input.

    Use a for loop to ping all hosts on the local subnet from some host already on it ( you could also ping broadcast I guess in some setups)
    Doing so builds up your ARP cache with entries for every host on the subnet
    For each entry in the ARP cache, add that to our list of MACs to wake up with WoL
    For every missing IP see which machine it belongs to, enable WoL if disabled, and repeat the above until you have all MACs

    If your tool accepts IP address or CIDR ranges as input, it's even easier (and you already wrote the process)

    Turn off all machines
    Issue WoL on the range
    For any that did not wake, enable WoL and repeat above until all hosts can wake
    Working on MS-ISA at Western Governor's University
  • techfiendtechfiend Member Posts: 1,481 ■■■■□□□□□□
    Did you do this on a lot of machines and did you automate it? Seems like a mildly fun scripting project.
    2018 AWS Solutions Architect - Associate (Apr) 2017 VCAP6-DCV Deploy (Oct) 2016 Storage+ (Jan)
    2015 Start WGU (Feb) Net+ (Feb) Sec+ (Mar) Project+ (Apr) Other WGU (Jun) CCENT (Jul) CCNA (Aug) CCNA Security (Aug) MCP 2012 (Sep) MCSA 2012 (Oct) Linux+ (Nov) Capstone/BS (Nov) VCP6-DCV (Dec) ITILF (Dec)
  • Vask3nVask3n Member Posts: 517
    techfiend wrote: »
    Did you do this on a lot of machines and did you automate it? Seems like a mildly fun scripting project.

    Yep, that process of pinging/building the ARP cache, then sending out WoL packets to the MACs was all in a Powershell script.

    Looking back now I would probably write it in something like Perl instead since I don't particularly care for Powershell
    Working on MS-ISA at Western Governor's University
  • techfiendtechfiend Member Posts: 1,481 ■■■■□□□□□□
    I share your thoughts on powershell. It seems like something that could be done with a batch file in a few lines. That's what I'm most comfortable with. Although it's text parsing isn't that good and perl shines in that area.
    2018 AWS Solutions Architect - Associate (Apr) 2017 VCAP6-DCV Deploy (Oct) 2016 Storage+ (Jan)
    2015 Start WGU (Feb) Net+ (Feb) Sec+ (Mar) Project+ (Apr) Other WGU (Jun) CCENT (Jul) CCNA (Aug) CCNA Security (Aug) MCP 2012 (Sep) MCSA 2012 (Oct) Linux+ (Nov) Capstone/BS (Nov) VCP6-DCV (Dec) ITILF (Dec)
Sign In or Register to comment.