Sledgehammer - Windows 10 Update Control

Discussion in 'MDL Projects and Applications' started by pf100, Nov 28, 2016.

  1. Homer712

    Homer712 MDL Member

    Oct 22, 2018
    118
    45
    10
    Everything seemed to be working well. Defender updates were being installed with regularity and no unwanted updates were being installed. MS released the latest update to 1809 a couple of days ago. No matter how many times I ran the script only Defender updates showed up. Finally this morning, I uninstalled the script, went to the Updates and Security setting and clicked "check for updates." The 1809 CU showed up immediately, downloaded and installed.

    Not sure if it's something with my install, but I think that after a couple of days the script should have picked up the update.
     
  2. pf100

    pf100 Duct Tape Coder

    Oct 22, 2010
    2,069
    3,447
    90
    I could be wrong, but considering yours is the only report of a problem with the WDU task, and is the only report of a problem showing the 1809 CU, I have a feeling it is something with your install. I installed the latest CU for 1809 yesterday with the script on two different machines; one with a clean install of LTSC 1809, the other with an updated over the years 1809 Pro.
     
  3. pf100

    pf100 Duct Tape Coder

    Oct 22, 2010
    2,069
    3,447
    90
  4. yatopp

    yatopp MDL Novice

    Jul 17, 2011
    41
    12
    0
    Is this a better solution than what I have been doing on LTSC?
    Disable update tasks (windows update, update orchestrator etc), using nsudo to force ones that are protected
    Disable update services
    Go through group policies and disable/enable all relevant ones.

    Using wireshark, I haven't seen any leaks and I can update manually when I want.
    The wrapper script certainly looks like good work, but changing permissions and getting SFC errors is a little off putting. Maybe the wrapper script is the only way to go for versions other than enterprise, but is what i'm doing enough/ok on LTSC?
     
  5. rpo

    rpo MDL Expert

    Jan 3, 2010
    1,443
    1,421
    60
    #1185 rpo, Apr 12, 2019
    Last edited: Apr 12, 2019
    1. Move also wumt_lang.ini to the bin folder.
    2. I suppose line 134 :
    Code:
    rem echo "`r`nPlease wait...`r`n"
    should be :
    Code:
    echo # "`r`nPlease wait...`r`n"
     
  6. pf100

    pf100 Duct Tape Coder

    Oct 22, 2010
    2,069
    3,447
    90
    #1186 pf100, Apr 12, 2019
    Last edited: Apr 12, 2019
    (OP)
    I don't force disable protected tasks, especially update orchestrator tasks, I only try normally and fail if protected, because I got locked out of task manager once in a vm doing that in version 18xxx and have heard of others having problems doing that. I disable the tasks that allow me to disable them normally, but I focus on disabling what the tasks try to run instead. I could actually remove all the task disabling code out of the script and it would still work.

    I don't trust the same group policies to work 6 months from now. This probably is never going to be an issue with LTSC, but I don't trust Microsoft. They keep randomly breaking GPO options from one version to the next.

    SFC errors are less off-putting than unexpected updates or driver installs. The SFC error problem goes away when you run the uninstaller.

    If what you're doing works to control updates and unwanted driver installs, then that's great and I'd stick with it.
     
  7. Carlos Detweiller

    Carlos Detweiller Emperor of Ice-Cream

    Dec 21, 2012
    6,324
    7,042
    210
    @pf100 Will there be an installer like for 2.5.5, eventually?
     
  8. pf100

    pf100 Duct Tape Coder

    Oct 22, 2010
    2,069
    3,447
    90
    Yes, this is just pre-release testing.
     
  9. Diggity

    Diggity MDL Novice

    Oct 1, 2011
    1
    4
    0
    Such an awesome tool.

    I actually forgot I had installed it a few months ago and was trying to use the Horrid Microsoft Store to calibrate my color with an android app & store app combo (I use 55" Curved Oled for monitor). So I tried to activate service. Access Denied. I went thru registry and changed permissions, values, etc etc. Nope. I go to DOS net start etc nope even d/l a MS toolfix for update - nada.

    Then it dawned on me, ran script used store then put it all back the way it was. Point is, even I couldn't screw it up!
     
  10. Carlos Detweiller

    Carlos Detweiller Emperor of Ice-Cream

    Dec 21, 2012
    6,324
    7,042
    210
    I have a question regarding WuMgr integration within the script: Currently it allows me to start a search for updates directly from the Configurator, however, only the normal online search is supported. Would it be possible to also start an offline search, the same way? Right now I need to use "E" and do it manually. :(
     
  11. pf100

    pf100 Duct Tape Coder

    Oct 22, 2010
    2,069
    3,447
    90
    To make WuMgr act like it does normally without script manipulation:
    In script 2.5.5, on line 486, (or for any recent version just look for this line near the bottom and change it)
    From this:
    Code:
    Start "" wumgr.exe -update -online 7971f918-a847-4430-9279-4a52d1efe18d -provisioned -onclose close.cmd
    to this:
    Code:
    Start "" wumgr.exe 7971f918-a847-4430-9279-4a52d1efe18d -onclose close.cmd
    That way WuMgr will sit there waiting for you to do something, but will still disable the windows update service when you close it.
    If you don't want to register Microsoft Update (I have never seen a reason not to, but several reasons where you should) then change the line to this instead:
    Code:
    Start "" wumgr.exe -onclose close.cmd
    ========================================
    Script v2.6.0 uses this line:
    Code:
    set check_updates=.\bin\wumgr.exe -update -online 7971f918-a847-4430-9279-4a52d1efe18d -provisioned -onclose close.cmd)
    and you would change it to this:
    Code:
    set check_updates=.\bin\wumgr.exe  7971f918-a847-4430-9279-4a52d1efe18d -onclose close.cmd)
    or this (no Microsoft Update registration):
    Code:
    set check_updates=.\bin\wumgr.exe -onclose close.cmd)
     
  12. Carlos Detweiller

    Carlos Detweiller Emperor of Ice-Cream

    Dec 21, 2012
    6,324
    7,042
    210
    Maybe a small checkbox on the Installer "Use WuMgr in Expert mode with unlocked controls". Unchecked - all locked, as it is now. Otherwise, I'd have to modify each and every OS' script after install (and new version).

    Alternative: Convince @DavidXanatos to not lock that one specific control (online/offline). After the immediate online check, there's no harm in allowing one to search offline afterwards.
     
  13. Whistler4

    Whistler4 MDL Member

    Jul 30, 2015
    204
    192
    10
    #1194 Whistler4, Apr 14, 2019
    Last edited: Apr 14, 2019
    I, too, prefer to use the installer version of the script, and I think flexibility for WuMgr to search offline would be nice. @pf100, could the script be modified to make online/offline check selectable, or would that require a modification of the -provisioned switch by @DavidXanatos?

    Can the -offline and -provisioned switches be used together? If so, I like the idea of a choice in the configurator as described above. But, unless you can implement an offline checkbox for selection "1", it would probably either clutter the choices in your third screen (go from 3 to 4 numerical choices) or require another decision screen after WuMgr is selected.

    I understand any reluctance to have the script run WuMgr without being provisioned at all, since that was needed for Wrapper Script adoption of WuMgr, basically to make it foolproof for most users. "Expert mode" implies that you ought to know what you're doing, so that might be sufficient warning.
     
  14. pf100

    pf100 Duct Tape Coder

    Oct 22, 2010
    2,069
    3,447
    90
    I agree. I still might be able to fit all options in the Configurator, I have to see. But... if I removed WUMT from the script and did some edits, the Configurator would be slightly less cluttered, maybe enough to help add all options. Is there anything WUMT can do that WuMgr can't? I'm trying to figure out why WUMT is even needed any more. I know people want it, but I don't know why. So far, I can make WuMgr do anything I want it to do. WUMT, yeah, but not really. 1) I can't hide the WUMT options in the script, 2) it's closed source, and 3) it's not supported any more, and WuMgr has none of those issues, which all together gives WUMT a big black eye for me. My end-game goal here is for the script to be eventually all open source. I would have already gotten rid of "wub.exe" since I know exactly what it does and can do the same thing in the script, but if I did that someone couldn't just run wub.exe to enable wuauserv any time they want. Maybe include it with the script, but not use it in the script? Or, have a separate script that does exactly what wub.exe does that would replace it entirely?
    Good idea. Now I just have to sleep on it and figure out the best way to present the options. Editing the script is fairly easy. Getting a command prompt screen with options that look as good as possible is not. It's graphical design without the graphics and is time consuming. I sound like I'm complaining but I'm not. I want the script to be the best it can be. If I didn't, I would just left-justify the info screens instead of centering them, which I could edit in 5 minutes and call it a day. Any other sane person would probably left-justify it since it works just as well either way, but I like graphics design, especially if there are actual graphics to be designed, which in this case there are not.
    What's taking so long to release 2.6.0 is that every time I think it's nearing completion, another idea comes up that improves the script. It's no big deal since if I died tomorrow, 2.5.5 would be "good enough", and I already posted a workable version of 2.6.0 just a few posts above this one, but 2.6.0 is going to be so far improved I maybe should make it version 3.0.0. So many decisions and variables to ponder. I can't even come up with a catchy name for the script yet. But that's the price of progress...
     
  15. Whistler4

    Whistler4 MDL Member

    Jul 30, 2015
    204
    192
    10
    (I bet Version 3.0.0, when you get there, will be the first one without WUMT -- Special Windows Update Script, Windows Update Controller Script, or whatever moniker you decide to give it.)

    You may want to wait a bit longer to keep using WUMT, at least until WuMgr is promoted to v1.0. And there may be some users that are still more comfortable with WUMT. But I see your point: If you build a new additional screen now, you may need to move those choices back to the current WuMgr/WUMT screen when you drop WUMT. If you drop WUMT now, less work. Dilemma. If you're taking a poll, I only select WUMT to see what the difference is in what WuMgr and WUMT are saying. (Basically, none.)

    Kudos to your screen esthetics (and script performance). Your attention to detail keeps it polished.

    Are you still expecting Sordum to modify WUB to your expectations? (I hope that includes minimizing to tray.) If so, that might be a good reason to keep it in the script. If you pull it, I think it would be good to still distribute it -- it can provide a convenient way to check on update service status or tool for staying safe between versions of the script or when not using the script for other reasons (alternative to disabling the network connection).
     
  16. pf100

    pf100 Duct Tape Coder

    Oct 22, 2010
    2,069
    3,447
    90
    Nope. They might someday, but I'm not waiting for it. I did all I could, I let them know a way to improve it. Either they implement my suggestions, or they don't. Oh well, at least they replied.
    To be fair, if I was the author of WUB, I would say, "this program is useless any more by itself. Screw this thing." I know that's what they're thinking, because that's the reality of the situation.
    The only reason they would update it is either 1) to implement my suggestions to improve only my script, or 2) take it all the way to a full-scale standalone solution, which would be incredibly hard to do. I give it about a 10% chance that WUB will ever be updated again.
     
  17. thefly42

    thefly42 MDL Novice

    Jan 30, 2016
    14
    5
    0
    If I had to vote again to keep WUMT, I would change my vote to No. As you say WuMgr does everything and more.
    So add that to your contemplations.
    Cheers,
    The Fly.

    P.S. Version 2.6.0v9 works well on two of my systems. Although on one it timed out after 10 seconds and asked me to run it again the first time. Everything has been smooth after that.