PC Deployment with SCCM and MDT

Latest News

  • USMTGUI migrates user profiles to Azure AAD
  • SCCM – Installing intrusive Applications…
  • Remove keyboard layout from Windows 10
  • WSUS fail – Reset defunct WSUS
  • network connection check with Powershell
  • Home
  • SCCM Pages
  • Videos
  • Self-study Guides
  • All Posts
  • Tips & tricks
  • About US

Using WSUS when building MDT reference images.

Oct 29, 2014 Thomas Ehler Uncategorized 2


Setting up WSUS with MDT and using Specific WSUS Targetgroup!

In this guide we will not only set up MDT to use our WSUS but also use specific Targetgroups. In this case the targetgroup “Test”

WsusTargetGroup
With MDT  it’s not possible by default to specify the WSUS target group. However You CAN fix this by adding an extra TS Variable..

 

 

 

 

First we setup the Variable in the customsettings.ini file \”mdtshare”\Control\customsettings.ini
In the “Settings” section the Variable is defined and in the “Default Section we define the Variable Type!!

-----------
[Settings] 
Priority=Default
Properties=TargetGroup
[Default]
TargetGroup=Terminal Servers
WSUSServer=http://"url to internal wsus server"
----------- 

(Also remember to insert URL to your WSUS server!)

Now We need to edit the Windows update script \”mdtshare”\Scripts\ZTIWindowsUpdate.wsf.
(We’re going to set up the specific target group in registry)

Go to the Section “Configure Windows Update settings” and insert the following “If” statement:

            If oEnvironment.Item("TargetGroup") <> "" then
                  oShell.RegWrite "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\TargetGroup", oEnvironment.Item("TargetGroup"), "REG_SZ"
                  oShell.RegWrite "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\TargetGroupEnabled", 00000001, "REG_DWORD"
            End if

 

– at the bottom of the “WsusServer” “If” Statement:

        '//----------------------------------------------------------------------------
        '//  Configure Windows Update settings
        '//----------------------------------------------------------------------------

        If oEnvironment.Item("WsusServer") <> "" then

            ' Configure the WSUS server in the registry.  This needs to be a URL (e.g. http://myserver).

            oLogging.CreateEntry "Configuring client to use WSUS server " & oEnvironment.Item("WsusServer"), LogTypeInfo

            oShell.RegWrite "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\WUServer", oEnvironment.Item("WsusServer"), "REG_SZ"
            oShell.RegWrite "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\WUStatusServer", oEnvironment.Item("WsusServer"), "REG_SZ"

            If oEnvironment.Item("TargetGroup") <> "" then
                  oShell.RegWrite "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\TargetGroup", oEnvironment.Item("TargetGroup"), "REG_SZ"
                  oShell.RegWrite "HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\TargetGroupEnabled", 00000001, "REG_DWORD"
            End if

        End if

 

Now all we need is to add the variable to our Task Sequence: WsusTargetGroup

In the Task Sequence, select the top of the “State Restore” group

and select “add>”, “General>”,  “Set Task Sequence Variable”

 

And you’re good to go!

If everything is set up right, after deploying an image you will see a new nonedomain entity in your selected Target group on the WSUS server. 🙂

 

 

 


SCCM 2012 R2 BSOD 0x0000004f Office 2010/2013. How to Include all Updates

Thomas Ehler

Related articles
  • USMTGUI migrates user profiles to Azure AAD
    USMTGUI migrates user profiles to Azure...

    Jun 11, 2020 0

  • SCCM – Installing intrusive Applications…
    SCCM – Installing intrusive...

    May 29, 2019 0

  • Remove keyboard layout from Windows 10
    Remove keyboard layout from Windows 10

    Apr 09, 2019 0

  • WSUS fail – Reset defunct WSUS
    WSUS fail – Reset defunct WSUS

    Aug 09, 2018 0

More in this category
  • USMTGUI migrates user profiles to Azure AAD
    USMTGUI migrates user profiles to Azure...

    Jun 11, 2020 0

  • SCCM – Installing intrusive Applications…
    SCCM – Installing intrusive...

    May 29, 2019 0

  • Remove keyboard layout from Windows 10
    Remove keyboard layout from Windows 10

    Apr 09, 2019 0

  • WSUS fail – Reset defunct WSUS
    WSUS fail – Reset defunct WSUS

    Aug 09, 2018 0


2 thoughts on “Using WSUS when building MDT reference images.”

  1. Feroze Khan December 20, 2015 at 18:17

    Where do I insert the URL to the WSUS server? Could you please email me the complete settings for using WSUS (server 2012) during Reference Image creation in MDT. My reference image creation works just fine, however doesn’t pick up anything from my WSUS server.

    These are the steps that I ran through to complete the WSUS Install:

    1. Installed WSUS role using the Windows Internal DB.

    2. Set the classifications and Product and Synced it up over the internet with Microsoft Updates.

    3. Set the automatic approval rule settings. Also Approved all the wanted updates for all Computers including unassigned computers.

    3. Enabled the WSUSServer property reference in the custom settings file.

    Please help. Thanks in advance.

    Reply ↓
    1. Thomas Ehler Post authorFebruary 1, 2016 at 12:40

      You must set
      WSUSServer=http:// “Your WSUS servers FQDN”
      AND enable Windows update in the MDT Task sequence,

      That is all I did…

      Reply ↓

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Recent Posts

  • USMTGUI migrates user profiles to Azure AAD
  • SCCM – Installing intrusive Applications…
  • Remove keyboard layout from Windows 10
  • WSUS fail – Reset defunct WSUS
  • network connection check with Powershell
  • SCCM State Migration Point Creation
  • USMT XML files improved and updated for USMT 10 and Windows 10
  • USMT migration of Edge favourites and Sticky Notes
  • SCCM Task Sequence Reinstall User warning.
  • ConfigMgr-SQL-recommendations.xlsx

Recent Videos

  • Building the Perfect Windows 8.1 Image

    Building the Perfect Windows 8.1 Image

    Mar 13, 2014
  • Master ConfigMgr 2012 R2 with a Limited Budget

    Master ConfigMgr 2012 R2 with a Limited Budget

    Mar 13, 2014
  • #3 SCCM2012 Application Management Part 1

    #3 SCCM2012 Application Management Part 1

    Mar 10, 2014
  • #2 SCCM 2012 Infrastructure Technical Overview

    #2 SCCM 2012 Infrastructure Technical Overview

    Mar 10, 2014
  • #1 SCCM 2012 Technical Overview

    #1 SCCM 2012 Technical Overview

    Mar 10, 2014

Recent comments

  • User State Migration Tool (USMT) Troubleshooting - EhlerTech on USMT – User State Migration Tool Errors
  • Mark H on Upgrade to Windows 10 with SCCM
  • SCCM Deploy – SCCM 2012 Comprehensive guides by Prajwal Desai on Post 1. Setting up VMware AD and SCCM 1511
  • SCCM Deploy – Post 1. Setting up VMware AD and SCCM 1511 on Post 4. Setup SCCM 2012 1511
  • SCCM Deploy – Post 3. DC – Setup DHCP and if needed KMS on Post 4. Setup SCCM 2012 1511
Copyright 2014 / All rights reserved