Friday, July 5, 2013

Create Application Deployment for .msu

Deploy .msu as an Application in ConfigMgr 2012

Problem

I have had a few scenarios that caused some grief when needing to create an application in ConfigMgr 2012 to install an .msu like the Microsoft RSAT tools.  These can be tricky because you do not always know what kind of detection method to use as you do not always know where it installs or what files to detect.

Solution

Below is the steps to import an .msu.  In this example we will import the RSAT tools and then create a custom detection method using vb script.  The vb script will query WMI for the KB article number and if it finds that it is installed it will Echo a response.  After finding how to use the custom script solution it really makes things easy if you know how to use/write/modify vb scripts because as long as you place an Echo in your script for when it should detect something ConfigMgr thinks it was found.  The Echo is what ConfigMgr looks for when an item is detected and does not matter what the Echo response is.

Prerequisites

1.       WMIScriptMicrosoftUpdatesDetectionMethod.vbs

a.       Copy this so you can import it via ConfigMgr or just copy and paste the code when needed below

2.       Microsoft RSAT Tools

a.       Windows 7

b.      Windows 8

Process

Setup Application

1.       Open ConfigMgr 2012 console

2.       Select Software Library

3.       Expand Application Management

4.       Expand Applications

a.       Click Create Application from the Ribbon

b.      Create Application Wizard

                                                               i.      General

1.       Manually Specify the Application Information

2.       Next

                                                             ii.      General Information

1.       Fill in all required fields

2.       Click Next

                                                            iii.      Application Catalog

1.       Fill in all required fields

2.       Click Next

                                                           iv.      Deployment Types

1.       Click Add

2.       Create Deployment Type Wizard

a.       General

                                                                                                                                       i.      Type: Script Installer

                                                                                                                                     ii.      Manually specify…

                                                                                                                                    iii.      Click Next

b.      General Information

                                                                                                                                       i.      Fill In required fields

                                                                                                                                     ii.      Click Next

c.       Content

                                                                                                                                       i.      Content Location

1.       Go to the UNC path of your downloaded files

                                                                                                                                     ii.      Installation program

1.       For Windows 7 x86

2.       For Windows 7 x64

3.       For Windows 8 x86

4.       For Windows 8 x64

                                                                                                                                    iii.      Uninstall Program

1.       For Windows 7 x86

2.       For Windows 7 x64

3.       For Windows 8 x86

4.       For Windows 8 x64

                                                                                                                                   iv.      Click Next

d.      Detection Method

                                                                                                                                       i.      Use a custom script to detect the presence of this deployment type

1.       Click Edit

2.       Script Type: VBScript

3.       Click Open and browse to the script downloaded earlier or paste the code into the script contents section. 

a.       ***Modify the code as needed per KB article

4.       Click OK

                                                                                                                                     ii.      Click Next

e.      User Experience

                                                                                                                                       i.      Installation behavior: Per system

                                                                                                                                     ii.      Logon Requirement: Whether or not a user is logged on

                                                                                                                                    iii.      Installation program visibility: Normal

                                                                                                                                   iv.      Click Next

f.        Requirements

                                                                                                                                       i.      Click Add

1.       Category: Device

2.       Condition: Operating System

3.       Rule type: Value

4.       Operator: One of

a.       Specify the specific OS for your deployment

5.       Click OK

                                                                                                                                     ii.      Click Next

g.       Dependencies

                                                                                                                                       i.      Click Next

h.      Summary

                                                                                                                                       i.      Click Next

i.         Completion

                                                                                                                                       i.      Click Close

3.       Click Add (if you need to setup for a different OS or OS version and go through the above steps again)

4.       Once Complete Click Next

                                                             v.      Summary

1.       Click Next

                                                           vi.      Completion

1.       Click Close

c.       Finish the application by distributing content and deploying the application to a collection

Monday, April 1, 2013

Step by Step: Replace default Recovery Image and integrate MS DaRT 8 into ConfigMgr 2012 OSD Image

Step by Step: Replace default Recovery Image and integrate MS DaRT 8 into ConfigMgr 2012 OSD Image

Scope

This document will detail the steps needed to replace the default recovery image of a Windows 7/8 machine with the MS DaRT 8 Recovery image and integrate it into a ConfigMgr 2012 Operating System Deployment Task Sequence.  I realize this process looks lengthy but it is very simple and again this is step by step so that draws it out a lot.


Prerequisites

1.       Windows 8 Pro or Enterprise (Must have to install MDOP 2012)

2.       DaRT Integration Script Download

3.       Windows 8 Assessment and Deployment Kit (ADK) Download

4.       Windows 8 Debugging Tools Download

5.       Microsoft Desktop Optimization Pack 2012 (MDOP) *Available as part of Microsoft Software Assurance and can be found on the Microsoft Licensing website

6.       Additional Drivers for NIC and HDD Controller (Drivers used for your OSD Boot Images)

Procedure

Install MDOP 2012 (The following steps are only for the DaRT install)

1.       From a Windows 8 Pro/Enterprise Machine (x64 works best)

a.       Install the ADK.

                                                               i.      The options needed is Deployment Tools and the Windows Preinstallation Environment (Windows PE)

b.      Install the Windows 8 Debugging Tools

                                                               i.      Welcome Screen

1.       Click Next

                                                             ii.      Specify Location

1.       Click Next

                                                            iii.      Join the Customer Experience Improvement Program

1.       Choose what fits best

2.       Click Next

                                                           iv.      License Agreement

1.       Click Accept

                                                             v.      Select the features you wish to install

1.       The only Required option is Debugging Tools for Windows

2.       Click Install

                                                           vi.      Complete

1.       Click Close

c.       Insert the MDOP disk and run .\launcher\launcher.hta from the CD

                                                               i.      From the installer choose Microsoft Diagnostics and Recovery Toolset

1.       Choose either Dart 8 32-bit or 64-bit (Must match the version of Windows you are running the install from)

a.       Welcome Screen

                                                                                                                                       i.      Click Next

b.      End User License Agreement

                                                                                                                                       i.      Select I Agree

c.       Microsoft Update

                                                                                                                                       i.      Choose which fits best for you

                                                                                                                                     ii.      Click Next

d.      Select Install Folder

                                                                                                                                       i.      Specify your install folder or accept defaults

                                                                                                                                     ii.      Click Next

e.      Setup Options

                                                                                                                                       i.      Select your options (I accept Defaults)

                                                                                                                                     ii.      Click Next

f.        Summary

                                                                                                                                       i.      Click Next

g.       Install

                                                                                                                                       i.      Click Install

Create a DaRT disk (The following steps must be done for 32-bit and 64-bit)

1.       From your Windows 8 Pro/Enterprise Machine (x64 works best)

a.       From the Start Screen select DaRT Recovery Image

                                                               i.      Welcome Screen

1.       Click Next

                                                             ii.      Windows 8 Media

1.       Specify what DaRT image you wish to create 64-bit or 32-bit

2.       Specify the path to the root of your Windows 8 Installation media

3.       Click Next

                                                            iii.      Tools

1.       Select all the tools you wish to include as part of your DaRT disk or Recovery Partition

a.      I leave out the Locksmith tool so Users cannot change the local administrator password if they get into the tools.

2.       Click Next

                                                           iv.      Remote Connection

1.       This will allow a Remote Assistance like view into the DaRT tools so you can recover a PC remotely (The Remote Viewer/Helper must have the DaRT Install previously listed completed and use the DaRT Remote Connection Viewer)

2.       Select what fits your environment best

3.       Click Next

                                                             v.      Advanced Options

1.       Drivers Tab

a.       Select any Network or HDD drivers you currently use as part of your PXE Boot Disk

2.       WinPE Tab

a.       Select what works best for you

                                                                                                                                       i.      We add WinPE-DismCmdlets, WinPE-Dot3svc, WinPE-EnhancedStorage, WinPE-FMAPI, WinPE-MDAC, WinPE-Netfx4,WinPE-Powershell3, WinPE-PPPOE, WinPE-scripting, WinPE-SecureBootCmdlets, WinPE-SecureStartup, WinPE-StorageWMI, WinPE-WDS-Tools, WinPE-WinRECfg, WinPE-WMI

3.       Crash Analyzer Tab

a.       Select Include the Windows 8 Debugging Tools

                                                                                                                                       i.      Browse to the install location from above

1.       Typically found under C:\Program Files (x86)\Windows Kits\8.0\Debuggers

4.       Defender Tab

a.       Select Download the latest definitions. (Recommended)

5.       Click Next

                                                           vi.      Create Image

1.       Choose Options that work best for you

a.      I choose defaults

2.       Click Create

                                                          vii.      Generate Files

1.       Click Next

                                                        viii.      Create Bootable media

1.       Do this if you need to make a DVD.  The follow steps will not require it

2.       Click Close

b.      At this point you are done creating your DaRT 8 Disks

ConfigMgr Integration

1.       From the Windows 8 Pro/Enterprise machine

a.       Navigate to the network share where you store your Application source files in ConfigMgr and create a folder called Microsoft DaRT 8

                                                               i.      Create a x86 and x64 directory under Microsoft DaRT 8

b.      Navigate to where the DaRT 8 files were created from the Create DaRT 8 Disk steps

                                                              i.      Make a copy of Boot.wim and Rename it to WinRE.wim

1.       Do this for both x86 and x64

                                                             ii.      Copy the WinRE.wim files to the appropriate directory you created for your application source files.

                                                            iii.      Copy the DaRT Integration script from the Prerequisites section to each Microsoft DaRT 8 application source files folder.

c.       At this point where you store your source files you should have an x86 and an x64 folder each with the appropriate WinRE.wim file and the DaRT Integration Script.

2.       From the ConfigMgr 2012 Console

a.       Navigate to Software Library à Application Management à Applications

                                                               i.      Click Create Application from the Ribbon

1.       General

a.       Manually Specify Application Information

                                                                                                                                       i.      Click Next

2.       General Information

a.       Fill in the info to best fit your environment

3.       Application Catalog

a.       Fill in the info to best fit your environment

4.       Deployment Types

a.       Click Add (you will do these steps 2x one for x86 and one for x64)

                                                                                                                                       i.      General

1.       Type:

a.       Script Installer

2.       Click Next

                                                                                                                                     ii.      General Information:

1.       Name:

a.       Microsoft DaRT 8 (x86) or (x64) *Ensure you only type one type

b.      Click Next

                                                                                                                                    iii.      Content

1.       Content Location:

a.       Browse to where you have the source files located

2.       Installation program:

a.       cscript.exe “DaRT Integration.vbs”

3.       Uninstall program

a.       Leave empty

4.       Click Next

                                                                                                                                   iv.      Detection Method

1.        Click Add Clause

a.       Setting Type

                                                                                                                                                                                                               i.      File System

b.      Type

                                                                                                                                                                                                               i.      File

c.       Path

                                                                                                                                                                                                               i.      C:\Windows\

d.      File or Foldername

                                                                                                                                                                                                               i.      DaRT    - This folder is created as part of the DaRT Integration Script

e.      Check This file or folder is associated

f.        Click OK

2.       Click Next

                                                                                                                                     v.      User Experience

1.       Installation behavior:

a.       Install for system

2.       Logon Requirement

a.       Whether or not a user is logged on

3.       Click Next

                                                                                                                                   vi.      Requirements

1.       Click Add

a.       Category

                                                                                                                                                                                                               i.      Device

b.      Condition

                                                                                                                                                                                                               i.      Operating System

c.       Operator

                                                                                                                                                                                                               i.      One of

                                                                                                                                                                                                             ii.      Select all OS versions that match the architecture of the DaRT image you are working on

d.      Click OK

2.       Click Next

                                                                                                                                  vii.      Dependencies

1.       Click Next

                                                                                                                                viii.      Summary

1.       Click Next

                                                                                                                                   ix.      Completion

1.       Click Close

b.      Do all steps from this sections 2.i.4.a to 2.i.4.b again for the other type (x86 or x64)

c.       Click Next

5.       Summary

a.       Click Next

6.       Completion

a.       Click Close

                                                             ii.      Highlight the new Microsoft DaRT 8 application

1.       Select Distribute Content from the Ribbon

a.       General

                                                                                                                                       i.      Click Next

b.      Content

                                                                                                                                       i.      Click Next

c.       Content Destination

                                                                                                                                       i.      Click Add

1.       Select which ever method you use when distributing content

                                                                                                                                     ii.      Click Next

d.      Summary

                                                                                                                                       i.      Click Next

e.      Completion

                                                                                                                                       i.      Click Next

                                                            iii.      At this point you should have a Microsoft DaRT 8 Application created and distributed to your Distribution Points or Groups

b.      Navigate to Software Library à Operating Systems à Task Sequences

                                                               i.      Highlight your Operating System Deployment Task Sequence

                                                             ii.      Click Edit from the Ribbon

1.       Highlight Setup Windows and Configuration Manager

a.       Click Add à General à Install Application

b.      Name:

                                                                                                                                       i.      Microsoft DaRT 8 Integration

c.       Click the YELLOW *

                                                                                                                                       i.      Locate the Microsoft DaRT 8 application

                                                                                                                                     ii.      Click OK

2.       At this point you can close out of the task sequence and everything should be ready to test.