LayoutModification.xml file not working for customizing StartMenu Windows 10

So you are in the process of developing a Windows 10 image, nice!

You want de customize your StartMenu, nice!

You have built a reference machine, and exported the StartMenu file.
https://msdn.microsoft.com/en-us/library/windows/hardware/mt171092(v=vs.85).aspx

We know how to do that with PowerShell:

Export-StartLayout – Path C:\Export\MyStartMenu.xml

And in your task sequence you import the file again with PowerShell:

Import-StartLayout C:\Import\MyStartMenu.xml –MountPath $env:SystemDrive\

(or you can rename your MyStartMenu.xml file to LayoutModification.xml and do a xcopy to C:\Users\Default\AppData\Local\Microsoft\Windows\Shell\)

xcopy /e /s /y /h /i “%~dp0LayoutModification.xml” “C:\Users\Default\AppData\Local\Microsoft\Windows\Shell\LayoutModification.xml”

Ok you do a deployment, log on with a new user who has no profile on the computer, open up the startmenu and……Nothing, still the default startmenu!

Like this:

Windows 10 Original StartMenu - LayoutModification.xml

Windows 10 Original StartMenu

But I wanted this:

Windows 10 Wanted StartMenu - LayoutModification.xml

Windows 10 Wanted StartMenu

Well I found a nasty line in the generated XML file while exporting with PowerShell

Export:

And with this it is NOT working.

Just remove the line and things will start to work! Nice!

Sysprep was not able to validate your Windows installation

On a machine running Windows 8, 8.1, 10 or even Windows Server 2012, 2012R2 or 2016 you can get a strange error when sysprepping the machine.

Sysprep was not able to validate your Windows installation.

(Error 0x8007139f)

Normally this is true because you can’t sysprep an upgraded machine. But I had this in a fresh install.

So the error is telling me to look in C:\Windows\System32\Sysprep\Panther and open the setupact.log file. So I did:

Error [0x0f0036] SYSPRP spopk.dll:: Sysprep will not run on an upgraded OS. You can only run Sysprep on a custom (clean) install version of Windows.

Error [0x0f0082] SYSPRP ActionPlatform::LaunchModule: Failure occurred while executing ‘Sysprep_Clean_Validate_Opk’ from C:\Windows\System32\spopk.dll; dwRet = 0x139f

Error SYSPRP SysprepSession::Validate: Error in validating actions from C:\Windows\System32\Sysprep\ActionFiles\Cleanup.xml; dwRet = 0x139f

Error SYSPRP RunPlatformActions:Failed while validating SysprepSession actions; dwRet = 0x139f

Error [0x0f0070] SYSPRP RunExternalDlls:An error occurred while running registry sysprep DLLs, halting sysprep execution. dwRet = 0x139f

Error [0x0f00d8] SYSPRP WinMain:Hit failure while pre-validate sysprep cleanup internal providers; hr = 0x8007139f

What we see here is that for some reason Windows thinks it has been upgraded.
Ok now we know that, what is the solution?

Actually pretty easy, in the registry!

In the HKEY_LOCAL_MACHINE\SYSTEM\Setup\ node you will
find a REG_DWORD ‘Upgrade‘ with a value of probably 0 (meaning not an upgrade…)

Just delete the ‘Upgrade’ key and you are good to go!

Not even a reboot is required.

Reset Trust Relationship for Domain Computer

When a computer somehow loses the trust relationship with the domain (for instance when longer than 30 days not connecting to the domain, or in a virtual environment returning to a snapshot) the usual steps you have to take are:

  1. Get the computer out of the domain to a workgroup (remember the local admin password!)
  2. Reboot
  3. Rejoin the domain
  4. Reboot

With powershell to the rescue it is an easier process:

Test-ComputerSecureChannel -Repair -Credential YourDomain\AdminUser

From the get-help

NAME

Test-ComputerSecureChannel

SYNOPSIS

Tests and repairs the secure channel between the local computer and its domain.

SYNTAX

Test-ComputerSecureChannel [-Credential [<PSCredential>]] [-InformationAction {SilentlyContinue | Stop | Continue | Inquire | Ignore | Suspend}] [-InformationVariable [<System.String>]] [-Repair] [-Server [<String>]] [-Confirm] [-WhatIf] [<CommonParameters>]

DESCRIPTION

The Test-ComputerSecureChannel cmdlet verifies that the secure channel between the local computer and its domain is working correctly by checking the status of its trust relationships. If a connection fails, you can use the Repair parameter to try to restore it.

Test-ComputerSecureChannel returns “True” if the secure channel is working correctly and “False” if it is not. This result lets you use the cmdlet in conditional statements in functions and scripts. To get more detailed test results, use the Verbose parameter.

This cmdlet works much like NetDom.exe. Both NetDom and Test-ComputerSecureChannel use the NetLogon service to perform the actions.

RELATED LINKS

Online Version: http://go.microsoft.com/fwlink/p/?linkid=293925

Checkpoint-Computer

Reset-ComputerMachinePassword

Restart-Computer

Stop-Computer

REMARKS

To see the examples, type: “get-help Test-ComputerSecureChannel -examples”.

For more information, type: “get-help Test-ComputerSecureChannel -detailed”.

For technical information, type: “get-help Test-ComputerSecureChannel -full”.

For online help, type: “get-help Test-ComputerSecureChannel -online”

Windows Installer Error Codes

When working with Windows msi installers you sometimes run into some kind of error or message.

Here is an overview of the most common errors or messages. They are most commonly found at the end of your installer log (always install with logging ;-)) usually prefaced by “MainEngineThread is returning”. This is the place where a zero is most preferred.

Enable logging on installation:

msiexec /I “yourInstaller.msi” /l*v “LOGlocation.log”

(There are versions where you have to use capital l (so L) instead of the lowercase l)

Value Description Error Code
0 Action completed successfully. ERROR_SUCCESS
13 The data is invalid. ERROR_INVALID_DATA
87 One of the parameters was invalid. ERROR_INVALID_PARAMETER
120 This function is not available for this platform. It is only available on Windows 2000 and Windows XP with Window Installer version 2.0. ERROR_CALL_NOT_IMPLEMENTED
1259 This error code only occurs when using Windows Installer version 2.0 and Windows XP or later. If Windows Installer determines a product may be incompatible with the current operating system, it displays a dialog informing the user and asking whether to try to install anyway. This error code is returned if the user chooses not to try the installation. ERROR_APPHELP_BLOCK
1601 The Windows Installer service could not be accessed. Contact your support personnel to verify that the Windows Installer service is properly registered. ERROR_INSTALL_SERVICE_FAILURE
1602 User cancel installation. ERROR_INSTALL_USEREXIT
1603 Fatal error during installation. ERROR_INSTALL_FAILURE
1604 Installation suspended, incomplete. ERROR_INSTALL_SUSPEND
1605 This action is only valid for products that are currently installed. ERROR_UNKNOWN_PRODUCT
1606 Feature ID not registered. ERROR_UNKNOWN_FEATURE
1607 Component ID not registered. ERROR_UNKNOWN_COMPONENT
1608 Unknown property. ERROR_UNKNOWN_PROPERTY
1609 Handle is in an invalid state. ERROR_INVALID_HANDLE_STATE
1610 The configuration data for this product is corrupt. Contact your support personnel. ERROR_BAD_CONFIGURATION
1611 Component qualifier not present. ERROR_INDEX_ABSENT
1612 The installation source for this product is not available. Verify that the source exists and that you can access it. ERROR_INSTALL_SOURCE_ABSENT
1613 This installation package cannot be installed by the Windows Installer service. You must install a Windows service pack that contains a newer version of the Windows Installer service. ERROR_INSTALL_PACKAGE_VERSION
1614 Product is uninstalled. ERROR_PRODUCT_UNINSTALLED
1615 SQL query syntax invalid or unsupported. ERROR_BAD_QUERY_SYNTAX
1616 Record field does not exist. ERROR_INVALID_FIELD
1618 Another installation is already in progress. Complete that installation before proceeding with this install. ERROR_INSTALL_ALREADY_RUNNING
1619 This installation package could not be opened. Verify that the package exists and that you can access it, or contact the application vendor to verify that this is a valid Windows Installer package. ERROR_INSTALL_PACKAGE_OPEN_FAILED
1620 This installation package could not be opened. Contact the application vendor to verify that this is a valid Windows Installer package. ERROR_INSTALL_PACKAGE_INVALID
1621 There was an error starting the Windows Installer service user interface. Contact your support personnel. ERROR_INSTALL_UI_FAILURE
1622 Error opening installation log file. Verify that the specified log file location exists and is writable. ERROR_INSTALL_LOG_FAILURE
1623 This language of this installation package is not supported by your system. ERROR_INSTALL_LANGUAGE_UNSUPPORTED
1624 Error applying transforms. Verify that the specified transform paths are valid. ERROR_INSTALL_TRANSFORM_FAILURE
1625 This installation is forbidden by system policy. Contact your system administrator. ERROR_INSTALL_PACKAGE_REJECTED
1626 Function could not be executed. ERROR_FUNCTION_NOT_CALLED
1627 Function failed during execution. ERROR_FUNCTION_FAILED
1628 Invalid or unknown table specified. ERROR_INVALID_TABLE
1629 Data supplied is of wrong type. ERROR_DATATYPE_MISMATCH
1630 Data of this type is not supported. ERROR_UNSUPPORTED_TYPE
1631 The Windows Installer service failed to start. Contact your support personnel. ERROR_CREATE_FAILED
1632 The temp folder is either full or inaccessible. Verify that the temp folder exists and that you can write to it. ERROR_INSTALL_TEMP_UNWRITABLE
1633 This installation package is not supported on this platform. Contact your application vendor. ERROR_INSTALL_PLATFORM_UNSUPPORTED
1634 Component not used on this machine ERROR_INSTALL_NOTUSED
1635 This patch package could not be opened. Verify that the patch package exists and that you can access it, or contact the application vendor to verify that this is a valid Windows Installer patch package. ERROR_PATCH_PACKAGE_OPEN_FAILED
1636 This patch package could not be opened. Contact the application vendor to verify that this is a valid Windows Installer patch package. ERROR_PATCH_PACKAGE_INVALID
1637 This patch package cannot be processed by the Windows Installer service. You must install a Windows service pack that contains a newer version of the Windows Installer service. ERROR_PATCH_PACKAGE_UNSUPPORTED
1638 Another version of this product is already installed. Installation of this version cannot continue. To configure or remove the existing version of this product, use Add/Remove Programs on the Control Panel. ERROR_PRODUCT_VERSION
1639 Invalid command line argument. Consult the Windows Installer SDK for detailed command line help. ERROR_INVALID_COMMAND_LINE
1640 Installation from a Terminal Server client session not permitted for current user. ERROR_INSTALL_REMOTE_DISALLOWED
1641 The installer has started a reboot. This error code not available on Windows Installer version 1.0. ERROR_SUCCESS_REBOOT_INITIATED
1642 The installer cannot install the upgrade patch because the program being upgraded may be missing or the upgrade patch updates a different version of the program. Verify that the program to be upgraded exists on your computer and that you have the correct upgrade patch.
This error code is not available on Windows Installer version 1.0.
ERROR_PATCH_TARGET_NOT_FOUND
1643 The patch package is not permitted by system policy. This error code is available with Windows Installer versions 2.0 or later. ERROR_PATCH_PACKAGE_REJECTED
1644 One or more customizations are not permitted by system policy. This error code is available with Windows Installer versions 2.0 or later. ERROR_INSTALL_TRANSFORM_REJECTED
3010 A reboot is required to complete the install. This does not include installs where the ForceReboot action is run. This error code not available on Windows Installer version 1.0. ERROR_SUCCESS_REBOOT_REQUIRED

Version (build) numbers Microsoft products

Hi!

Just a short post for reference.

In my line of work I sometimes need to find the product description or version (build) number of a product.
While searching for them I stumbled upon a perfect website for most regular Microsoft products!

https://buildnumbers.wordpress.com/

Products like AX, CRM, Exchange, Office, SCCM, SCDPM, SCOM, SCSM, SCVMM, Sharepoint, SQL Server, TMG/ISA

I don’t know who is behind the site but a great cheerio for him/her or them! 🙂

/Stephan

Task Sequence Built-in Variables in ConfigMgr 2012 R2

This is just a reminder for the built-in Task Sequence variables in ConfigMgr 2012 R2.

You can also find them at: https://technet.microsoft.com/en-us/library/hh273375.aspx

 

Built-in Variable Name Description
_SMSTSAdvertID Stores the current running task sequence deployment unique ID. It uses the same format as a Configuration Manager software distribution deployment ID. If the task sequence is running from stand-alone media, this variable is undefined.
Example:
ABC20001
_TSAppInstallStatus For System Center 2012 R2 Configuration Manager only:
The task sequence sets the _TSAppInstallStatus variable with the installation status for the application during the Install Application task sequence step. The task sequence sets the variable with one of the following values:

  1. Undefined: Set when the Install Application task sequence step has not been run.
  2. Error: Set when at least one application failed because of an error during the Install Application task sequence step.
  3. Warning: Set when no errors occur during the Install Application task sequence step, but one or more applications, or a required dependency, did not install because a requirement was not met.
  4. Success: Set when there are no errors or warning detected during the Install Application task sequence step.
_SMSTSBootImageID Stores the Configuration Manager boot image package ID if a boot image package is associated with the current running task sequence. The variable will not be set if no Configuration Manager boot image package is associated.
Example:
ABC00001
_SMSTSBootUEFI For System Center 2012 Configuration Manager SP1 and System Center 2012 R2 Configuration Manager only:
The task sequence sets the SMSTSBootUEFI variable when it detects a computer that is in UEFI mode.
_SMSTSClientGUID Stores the value of Configuration Manager client GUID. This variable is not set if the task sequence is running from stand-alone media.
Example:
0a1a9a4b-fc56-44f6-b7cd-c3f8ee37c04c
_SMSTSCurrentActionName Specifies the name of the currently running task sequence step. This variable is set before the task sequence manager runs each individual step.
Example:
run command line
_SMSTSDownloadOnDemand Set to true if the current task sequence is running in download-on-demand mode, which means the task sequence manager downloads content locally only when it must access the content.
_SMSTSInWinPE This variable is set to true when the current task sequence step is running in the Windows PE environment, and it is set to false if not. You can test this task sequence variable to determine the current operating system environment.
_SMSTSLastActionRetCode Stores the return code that was returned by the last action that was run. This variable can be used as a condition to determine if the next step is run.
Example:
0
_SMSTSLastActionSucceeded The variable is set to true if the last action succeeded and to false if the last action failed. If the last action was skipped because the step was disabled or the associated condition evaluated to false, this variable is not reset, which means it still holds the value for the previous action.
_SMSTSLaunchMode Specifies the task sequence launch method. The task sequence can have the following values:

  • SMS – specifies that the task sequence is started by using the Configuration Manager client.
  • UFD – specifies that the task sequence is started by using USB media and that the USB media was created in Windows XP/2003.
  • UFD+FORMAT – specifies that the task sequence is started by using USB media and that the USB media was created in Windows Vista or later.
  • CD – specifies that the task sequence is started by using a CD.
  • DVD – specifies that the task sequence is started by using a DVD.
  • PXE – specifies that the task sequence is started from PXE.
  • HD – specifies that the task sequence was started from a hard disk (prestaged media only).
_SMSTSLogPath Stores the full path of the log directory. This can be used to determine where actions are logged. This value is not set when a hard drive is not available.
_SMSTSMachineName Stores and specifies the computer name. Stores the name of the computer that the task sequence will use to log all status messages. To change the computer name in the new operating system, use the OSDComputerName variable.
Example:
ABC
_SMSTSMDataPath Specifies the path defined by the SMSTSLocalDataDrive variable. When you define SMSTSLocalDataDrive before the task sequence starts, such as by setting a collection variable, Configuration Manager then defines the _SMSTSMDataPath variable once the Task Sequence starts.
_SMSTSMediaType Specifies the type of media that is used to initiate the installation. Examples of types of media are Boot Media, Full Media, PXE, and Prestaged Media.
_SMSTSMP Stores the name or IP address of a Configuration Manager management point.
_SMSTSMPPort Stores the management point port number of a Configuration Manager management point.
Example:
80
_SMSTSOrgName Stores the branding title name that is displayed in a task sequence progress user interface dialog box.
Example:
XYZ Organization
_SMSTSPackageID Stores the current running task sequence ID. This ID uses the same format as a Configuration Manager software package ID.
Example:
HJT00001
_SMSTSPackageName Stores the current running task sequence name specified by the Configuration Manager administrator when the task sequence is created.
Example:
Deploy Windows 7 task sequence
_SMSTSRunFromDP Set to true if the current task sequence is running in run-from-distribution-point mode, which means the task sequence manager obtains required package shares from distribution point.
_SMSTSSiteCode Stores the site code of the Configuration Manager site.
Example:
ABC
_SMSTSType Specifies the type of the current running task sequence. It can have the following values:
1 – indicates a generic task sequence.
2 – indicates an operating system deployment task sequence.
_SMSTSTimezone The _SMSTSTimezone variable stores the time zone information in the following format (without spaces):
Bias, StandardBias, DaylightBias, StandardDate.wYear, wMonth, wDayOfWeek, wDay, wHour, wMinute, wSecond, wMilliseconds, DaylightDate.wYear, wMonth, wDayOfWeek, wDay, wHour, wMinute, wSecond, wMilliseconds, StandardName, DaylightName
Example:
For the Eastern Time U.S. and Canada, the value would be 300,0,-60,0,11,0,1,2,0,0,0,0,3,0,2,2,0,0,0,Eastern Standard Time,Eastern Daylight Time
_SMSTSUseCRL Specifies whether the task sequence uses the certificate revocation list when it uses a Secure Socket Layer (SSL) certificate to communicate with the management point.
_SMSTSUserStarted Specifies whether a task sequence is started by a user. This variable is set only if the task sequence is started from the Software Center. For example, if _SMSTSLaunchMode is set to SMS. The variable can have the following values:

  • true – specifies that the task sequence is manually started by a user from the Software Center.
  • false – specifies that the task sequence is initiated automatically by the Configuration Manager scheduler.
_SMSTSUseSSL Specifies whether the task sequence uses SSL to communicate with the Configuration Manager management point. If your site is running in native mode, the value is set to true.
_SMSTSWTG For System Center 2012 Configuration Manager SP1 and System Center 2012 R2 Configuration Manager only:
Specifies if the computer is running as a Windows To Go device.
SMSTSAssignmentsDownloadInterval For System Center 2012 Configuration Manager SP1 and System Center 2012 R2 Configuration Manager only:
Use this variable to specify the number of seconds to wait before the client will attempt to download the policy since the last attempt (which returned no policies). By default, the client will wait 0 seconds before retrying.
You can set this variable by using a prestart command from media or PXE.
SMSTSAssignmentsDownloadRetry For System Center 2012 Configuration Manager SP1 and System Center 2012 R2 Configuration Manager only:
Use this variable to specify the number of times a client will attempt to download the policy after no policies are found on the first attempt. By default, the client will retry 0 times.
You can set this variable by using a prestart command from media or PXE.
SMSTSAssignUsersMode Specifies how a task sequence associates users with the destination computer. Set the variable to one of the following values.

  • Auto: The task sequence creates a relationship between the specified users and destination computer when it deploys the operating system to the destination computer.
  • Pending: The task sequence creates a relationship between the specified users and the destination computer, but waits for approval from the administrative user before the relationship is set.
  • Disabled: The task sequence does not associate users with the destination computer when it deploys the operating system.
SMSTSDownloadProgram For System Center 2012 Configuration Manager SP1 and System Center 2012 R2 Configuration Manager only:
Use this variable to specify an Alternate Content Provider, a downloader program that is used to download content instead of the default Configuration Manager downloader, for the task sequence. As part of the content download process, the task sequence checks the variable for a specified downloader program. If specified, the task sequence runs the program to perform the download.
SMSTSDownloadRetryCount For System Center 2012 R2 Configuration Manager only:
Use this variable to specify the number of times that Configuration Manager attempts to download content from a distribution point. By default, the client will retry 2 times.
SMSTSDownloadRetryDelay For System Center 2012 R2 Configuration Manager only:
Use this variable to specify the number of seconds that Configuration Manager waits before it retries to download content from a distribution point. By default, the client will wait 15 seconds before retrying.
SMSTSErrorDialogTimeout When an error occurs in a task sequence, a dialog box is displayed that is automatically dismissed after a number of seconds specified by this variable. By default, the dialog box is automatically dismissed after 900 seconds (15 minutes)..
TSErrorOnWarning For System Center 2012 R2 Configuration Manager only:
Use this variable to specify whether the task sequence engine considers a detected warning as an error during the Application Installation task sequence step. The task sequence sets the _TSAppInstallStatus variable to Warning when one or more applications, or a required dependency, did not install because a requirement was not met. When you set the TSErrorOnWarning variable to True and the _TSAppInstallStatus variable is set to Warning, it is treated as an error. A value of False is the default behavior.
SMSTSLanguageFolder For System Center 2012 Configuration Manager SP1 and System Center 2012 R2 Configuration Manager only:
Use this variable to change the display language of a language neutral boot image.
SMSTSLocalDataDrive Specifies where temporary files are stored on the destination computer while the task sequence is running.
This variable must be set before the task sequence starts, such as by setting a collection variable. Once the task sequence starts, Configuration Manager defines the _SMSTSMDataPath variable once the Task Sequence starts.
SMSTSMPListRequestTimeout For System Center 2012 R2 Configuration Manager only:
Use this variable to specify how many milliseconds a task sequence waits before it retries to install an application after it fails to retrieve the management point list from location services. By default, the task sequence waits 60,000 milliseconds (60 seconds) before it retries the step, and retries up to three times. This variable is applicable only to the Install Application task sequence step.
SMSTSPersistContent For System Center 2012 Configuration Manager SP1 and System Center 2012 R2 Configuration Manager only:
Use this variable to temporarily persist content in the task sequence cache.
SMSTSPostAction For System Center 2012 Configuration Manager SP1 and System Center 2012 R2 Configuration Manager only:
Specifies a command that is run after the task sequence completes. For example, you can use this variable to specify a script that enables write filters on embedded devices after the task sequence deploys an operating system to the device.
SMSTSPreferredAdvertID Forces a specific targeted deployment on the destination computer to be run. This can be set through a prestart command from media or PXE. If this variable is set, the task sequence overrides any required deployments.
OSDPreserveDriveLetter For System Center 2012 Configuration Manager SP1 and System Center 2012 R2 Configuration Manager only:
This variable determines whether or not the task sequence uses the drive letter captured in the operating system image WIM file when applying that image to a destination computer. In Configuration Manager with no service pack, the drive letter captured in the WIM file is used when applying the operating system image WIM file. In Configuration Manager SP1, you can set the value for this variable to False to use the location that you specify for the Destination setting in the Apply Operating System task sequence step. For more information about the Apply Operating System task sequence step, see the Apply Operating System Image section in the Task Sequence Steps in Configuration Manager topic.
SMSTSRebootDelay Specifies how many seconds to wait before the computer restarts. The task sequence manager will display a notification dialog before reboot if this variable is not set to 0.
Examples:
0
30
SMSTSRebootMessage Specifies the message to display in the shutdown dialog box when a restart is requested. If this variable is not set, a default message will appear.
Example:
This computer is being restarted by the task sequence manager.
SMSTSRebootRequested Indicates that a restart is requested after the current task sequence step is completed. If a restart is required, just set this variable to true, and the task sequence manager will restart the computer after this task sequence step. The task sequence step must set this task sequence variable if it requires the restart to complete the task sequence step. After the computer is restarted, the task sequence will continue to run from the next task sequence step.
SMSTSRetryRequested Requests a retry after the current task sequence step is completed. If this task sequence variable is set, the SMSTSRebootRequested must also be set to true. After the computer is restarted, the task sequence manager will rerun the same task sequence step.
SMSTSUDAUsers Specifies the primary user of the destination computer. Specify the users by using the following format. Separate multiple users by using a comma (,).
Example:
domain\user1, domain\user2, domain\user3
For more information about associating users with the destination computer, see How to Associate Users with a Destination Computer.

ConfigMgr Client Log locations during OSD

Just a quick reference for finding the client logs during an Operating System Deployment.

As we all know ConfigMgr moves the logs during a deployment depending on the stage of deployment.

We can define 4 major stages in regard to the log file locations:

  1. System has started in WinPE, no hard drive configuration has taken place:
    “x:\windows\temp\smstslog” folder
  2. System has started in WinPE, hard drive has been partitioned and formatted:
    “x:\smstslog” folder
    “c:\_SMSTaskSequence\Logs\Smstslog” folder
  3. System has started in Windows but ConfigMgr is NOT yet installed:
    “c:\_SMSTaskSequence\Logs\Smstslog” folder
  4. System has started in Windows and ConfigMgr IS installed:
    “c:\windows\ccm\logs\Smstslog” folder

After the completion of the OSD the Task Sequence log file can be found in:

“c:\windows\ccm\logs\smsts.log

Probably you will find 2 of those, 1 with a date appended. This is because log files can’t grow unlimited!

Deploy the Windows 7 Kernel Mode Driver Framework (KMDF) with ConfigMgr 2012

So you got your brand new Dell or other manufacturer’s hardware, deploy an OS with ConfigMgr 2012 and he, no go – chrash – missing drivers etc.

Well you might need the new Kernel Mode Driver Framework 1.11 (here) or the User Mode Driver Framework 1.11 (here).

But wait, this is an Windows Update! And I am doing OSD.

To successfully add the Driver Framework use good old dism
during OSD. Of course you will build a new reference image but in the meantime you have some deployment to do.

Okay let’s start.

First extract the files out of the .msu (I am using the x64 version for this). Use WinRar or 7zip for this.

In this folder create a batch file – install.cmd – containing following code:

Dism.exe /Image:%1\ /Add-Package /PackagePath:"%~dp0Windows6.1-KB2685811-x64.cab" /NoRestart

So the content of folder will now look like this (b.t.w. we do not need the .msu in the package ;-))

Create a ConfigMgr package from these files. No program needed! Distribute the content.

Now we can apply this in our Task Sequence. It has to be done AFTER the ‘Apply Operating System’, but BEFORE the installation of the ConfigMgr client.

Add a ‘Run Command Line’ and enter following as command:

Cmd.exe /c install.cmd %OSDTargetSystemDrive%

Reference the package.

Now the KMDF will be installed during the deployment!

You can do the same steps for the UMDF.

(Re)-Creating a boot image for ConfigMgr 2012 using Windows ADK

When you are having problems with your boot images (corruption or just malfunctioning) there might come a time you need to (re)-create one or maybe both.

This is a very straight forward process which will be described below.

You use the Windows ADK for this process. Depending on your version of ConfigMgr this will be the 8 (http://www.microsoft.com/en-us/download/details.aspx?id=30652) or 8.1 (http://www.microsoft.com/en-us/download/details.aspx?id=39982) version.

Run the ‘Deployment and Imaging Tools Environment’ As Administrator

This will open up the environment

Depending on the architecture the command to issue will be the following:

32-bit boot-image:

COPYPE.CMD x86 C:\WINPE86\

64-bit boot-image:

COPYPE.CMD amd64 C:\WINPE64\

ARM boot-image:

COPYPE.CMD arm C:\WINPEARM\

The target folder can be a folder of choice!

This will only take a few seconds.

And there it is, your freshly created boot image!
You can find this in the C:\WINPE64\media\sources folder.

In the ConfigMgr console go-to ‘Software Library – Overview – Operating Systems – Boot Images’, right-click and select ‘Add Boot Image’

Select your new image:

Provide information:

And there it is, your boot image in ConfigMgr.

Now you can work with this image as well!
Just remember to distribute the image, and when needed to enable ‘Deploy this boot image from PXE-enabled distribution point’

Monitoring Task Sequences in ConfigMgr 2012 R2 console

When doing OSD in SCCM 2012 R2 you can view the deployment information in the Task Sequence reports, but the Status Messages is really the preferred place for this.

First thing you need is to get the deployment ID of the Task Sequence you wish to monitor. You have to setup a query for each Task Sequence.

Go to Monitoring, Overview, Deployments.

(The Deployment ID are not displayed by default so you have to select this. Right-click and select ) and take a note of the Deployment ID

 Deployment ID:

 Build the Status Message Queries:

  • Go to Monitoring, Overview, System Status, Status Message Queries, right click and choose Create Status Message Query.
  • Give the Status Message Query a name, and click Edit Query Statement

  • In the General Tab choose Show Query Language and paste in the following text (watch out with the quotes ;-));
    Replace the collection ID with the one you looked up.

select
SMS_StatusMessage.*,
SMS_StatMsgInsStrings.*,
SMS_StatMsgAttributes.*,
SMS_StatMsgAttributes.AttributeTime
from SMS_StatusMessage
left join SMS_StatMsgInsStrings
on SMS_StatMsgInsStrings.RecordID = SMS_StatusMessage.RecordID
left join SMS_StatMsgAttributes
on SMS_StatMsgAttributes.RecordID = SMS_StatusMessage.RecordID
where SMS_StatMsgAttributes.AttributeID = 401 and SMS_StatMsgAttributes.AttributeValue = “ODV20002”
and SMS_StatMsgAttributes.AttributeTime >= ##PRM:SMS_StatMsgAttributes.AttributeTime## order by SMS_StatMsgAttributes.AttributeTime DESC

 


  • Click OK, and complete the wizard.

To launch the Query:

  • In the State Message, right click the query and select the date and time (default 1 hour ago), and click OK.

 

And an overview of the result!