Introduction to the Software Reset Starter Pack 

Windows Troubleshooting Platform (WTP) provides ISVs, OEMs, and administrators the ability to write troubleshooting packs that are used to discover and resolve issues found on the computer. Previously, troubleshooting software and hardware issues was a manual process; however, using WTP you can automate the process of fixing the most common detectable issues that the user might encounter using your software or hardware. Several troubleshooting packs ship with Windows and any developer can create their own custom packs with WTP. A Troubleshooting Pack is a collection of scripts (troubleshooter, verifier and resolver), a manifest file and localized resources that rely on Windows Troubleshooting Platform to accomplish automation tasks.

Starter Packs are Troubleshooting Pack “templates” for the Windows Troubleshooting Platform that can be modified by developers to suit their specific needs, providing an easy way for developers to quickly create fully-functional Troubleshooting Packs. Each Starter Pack includes a set of basic functionality that can be customized and extended to support additional customer scenarios. Starter Packs can be used to develop troubleshooters for a range of customers, from home users to developers & IT Administrators.

The Software Reset Starter Pack simplifies Troubleshooting Pack development for low to medium complexity support scenarios by significantly reducing the amount of PowerShell and Troubleshooting Pack-specific knowledge required by the developer. It enables developers to quickly transform a series of manual troubleshooting steps into a self-help troubleshooter that can be used by customers to easily apply fixes for one or more problems.

This Starter Pack can be used to apply pre-defined settings for modifying files, registry keys, and performing command line operations. These pre-defined settings, called “Settings Groups”, contain display information and the sequence of operations to reset that group to a known “good state”. The developer can define one or many groups, depending on the level of detail required. For example, a troubleshooter for a web browser may include settings groups to reset browser history, default security settings, default privacy settings, and default add-ons.  

clip_image001[4] 

When the troubleshooting pack is deployed and run by the customer they will be presented with a list of settings groups they may want to fix. The troubleshooting pack then performs the sequence of operations associated with the user-selected settings groups. Finally, the customer is presented with a summary of the actions performed by the troubleshooting pack.

clip_image002[4] 

This document will provide you with the necessary steps to customize and package troubleshooting packs based on the Software Reset Starter Pack. You will learn how to install Troubleshooting Pack Designer, open the necessary files in the Starter Pack, customize display information with Troubleshooting Pack Designer, and edit the Settings.xml file to add functionality to your pack. You will also learn how to package your troubleshooting pack for use on other computers in your home or organization.  

 Loading the Project 

The following section will guide you through installing Troubleshooting Pack Designer and opening a Starter Pack. 

Installing Troubleshooting Pack Designer

Although you can author, package, and test troubleshooting packs manually, you should consider using the Windows Troubleshooting Pack Designer (TSPDesigner.exe) included in the Windows 7 SDK. In addition to helping you more quickly author your troubleshooting pack, the tool also manages security and deployment related tasks such as creating security catalogs, applying digital signatures, building resource files, and packaging the final troubleshooting pack. For the best possible development experience we recommend using the Troubleshooting Pack Designer, PowerShell ISE, and a fully-featured XML editor, such as Microsoft Visual Studio.  

To use the Software Reset Starter Pack with Troubleshooting Pack Designer you must first setup your Troubleshooting Pack development environment on a Windows 7 PC by following the steps below. 

1. Install Microsoft Visual C++ 2010 Express or Microsoft Visual Studio 2010
2. Install the Windows 7 SDK 7.1 (NOTE: The “Tools” features under "Windows Native Code Development" and ".NET Development" must both be checked) 

The Troubleshooting Pack Designer can be launched by clicking Start > All Programs > Microsoft Windows SDK v7.1 > Tools > Windows Troubleshooting Pack Designer.  

NOTE: If you are unable to launch or use the Troubleshooting Pack Designer please visit Microsoft Knowledge Base Article 2644923 for steps to resolve. 

Opening the Starter Pack 

Open the Software Reset Starter Pack by following the steps below 

1. Download the Software Reset Starter Pack from http://starterpacks.codeplex.com/
2. Unzip the package to package to your Documents\Troubleshooting Packs folder
3. Open Troubleshooting Pack Designer
4.
In Windows Troubleshooting Pack Designer, select Project>Open in the menu bar.
5.
Select Documents\Troubleshooting Packs\Software Reset Starter Pack\SoftwareResetStarterPack.diag, then click Open

6. Open Documents\Troubleshooting Packs\Software Reset Starter Pack\Settings.xml using Visual Studio or your preferred XML editor 

You have now loaded the project in Troubleshooting Pack Designer, have opened the Settings.xml file, and are ready to get started with customizing the Software Reset Starter Pack to create your own troubleshooting pack. 

 Customizing the Project

With the Software Reset Starter Pack source files, you have the option to quickly view the schema and sample implementation of the Starter Pack by opening \Software Reset Starter Pack\Settings.xsd or \Software Reset Starter Pack\Settings.xml. For detailed reference, please see the Settings.xml Reference section of this document.

By default, the Settings.xml file includes a pre-built XML tree with four sample Settings Groups. The sample in the source provided can be packaged into a troubleshooter (with Troubleshooting Pack Designer) that displays several prompts when deployed (see figures 1 and 2). Unless it has been customized, a troubleshooting pack created using the existing elements in the pre-built Starter Pack tree will not change the settings on the computer it is run on.

clip_image003[4]

Click “Next”. You will now see a prompt that lists the default Settings Groups:

clip_image004[4]

The Software Reset Starter Pack supports two categories of customization:

n  Display Information: This requires editing the SoftwareResetStarterPack.diag file in Troubleshooting Pack Designer to customize the pack icon, title and description in the Troubleshooting Wizard.

n  Settings Groups: This requires editing the Settings.xml file to define the Settings Groups shown in the Troubleshooting Wizard and associated operations. To edit the XML file you must first understand the elements and attributes available to you.

The following sections in this document will use the steps in Microsoft Knowledge Base Article 223300 as an example. Windows Installer can use logging to help assist in troubleshooting issues with installing software packages. This logging is enabled by adding keys and values to the registry. After following the steps below, you will have a troubleshooting pack that automates the process of enabling/disabling Windows Installer Logging, starting/stopping the installer service and copying/deleting the log file. Starting/stopping the installer service and log file copy/delete features are not included in the KB article, but have been added to this troubleshooting pack to demonstrate the capabilities of the Software Reset Starter Pack.

Please read KB Article 223300 carefully before creating this troubleshooting pack so you understand how it will change your computer.

 

Editing Display Information 


Modifying display information for the Software Reset Starter Pack involves changing the icon and editing the Project Properties in Troubleshooting Pack Designer. Adding additional interactions beyond the scope of this starter pack requires the use of both Troubleshooting Pack Designer and PowerShell. Using PowerShell is beyond the scope of this document.

Changing the Icon

To change the icon, go to project properties in the main Troubleshooting Pack Designer screen with the project loaded. Click on “Change” in the Project icon section:

clip_image005[4]

Browse for the desired icon (.ico) file and select “Open”. Press F5 or select the button from the toolbar.

Troubleshooting Pack Designer will now sign and package the troubleshooting pack. The Troubleshooting Wizard will launch and your new icon will show on the first screen and title bar of the pack. To stop running, exit troubleshooting pack and return to editing, click “Cancel” or close the Troubleshooting Wizard window.

Changing the title and project description 

 


To edit the title and description shown to the user when the pack is run, update the Project Name and Project Description on the main page of Troubleshooting Pack Designer with your desired content. Change the default text “Software Reset Starter Pack” to “Installer Logging Troubleshooting Pack”. Change “Reset software settings to a known state” to “Enable/Disable Windows Installer Logging to troubleshoot software installation issues:

clip_image006[4]

Press F5 or select the clip_image007[4]button from the toolbar to sign and package the troubleshooting pack again. The Troubleshooting Wizard will launch with your new pack title and description, and should look similar to the screen below:

clip_image008[4]

Close the Troubleshooting Wizard as described above to continue Starter Pack customization. The next section describes how to customize and add functionality to the Settings Groups that will be displayed on the next screen in the Troubleshooting Wizard.

Customizing Settings Groups


The Software Reset Starter Pack source provides Settings Group A, Settings Group B and Settings Group C by default. You can change names of these categories, as well as the operations run when the user selects them by changing the text, elements and associated attributes in the Settings.xml file. If you build the Starter Pack with the default markup, then the screen below will show when the user clicks “Next” in the first display.

clip_image009[4]

To begin editing the Settings.xml file, open Documents\Troubleshooting Packs\Software Reset Starter Pack\Settings.xml in an XML editor and review the sample provided there.

To view your changes each time you edit the Settings.xml file, you must first save it, then repackage and deploy the troubleshooting pack in Troubleshooting Pack Designer. The example markup for Settings.xml below shows one way you can implement the steps in KB Article 223300 mentioned in the previous example. Replace the existing markup in the Starter Pack Settings.xml file with the following:

<?xml version="1.0" encoding="utf-8"?>

<SoftwareReset xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="Settings.xsd">

<SettingsGroup id="0">

<DisplayInformation>

<Name>Enable Windows Installer logging</Name>

<Description>

Windows includes a registry-activated logging service to help diagnose Windows Installer issues. This will enable it.

</Description>

</DisplayInformation>

<Settings>

<SetRegValue key="Registry::HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\Installer" value="Logging" Type="String" data="voicewarmupx"/>

</Settings>

</SettingsGroup>

 

<SettingsGroup id="1">

<DisplayInformation>

<Name>Disable Windows Installer logging</Name>

<Description>

Windows includes a registry-activated logging service to help diagnose Windows Installer issues. This will disable it.

</Description>

</DisplayInformation>

<Settings>

<SetRegValue key="Registry::HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\Installer" value="Logging" Type="String" data=""/>

</Settings>

</SettingsGroup>

 

<SettingsGroup id="2">

<DisplayInformation>

<Name>Stop Installer Service</Name>

<Description>

This will stop the installer service.

</Description>

</DisplayInformation>

<Settings>

<RunCommand commandline="sc.exe config msiserver start= auto"/>

<RunCommand commandline="net stop msiserver "/>

<RunCommand commandline="sc.exe config msiserver start= demand"/>

</Settings>

</SettingsGroup>

 

<SettingsGroup id="3">

<DisplayInformation>

<Name>Start Installer Service</Name>

<Description>

Windows includes a registry-activated logging service to help diagnose Windows Installer issues.

</Description>

</DisplayInformation>

<Settings>

<RunCommand commandline="sc.exe config msiserver start= auto"/>

<RunCommand commandline="net start msiserver"/>

<RunCommand commandline="sc.exe config msiserver start= demand"/>

</Settings>

</SettingsGroup>

 

<SettingsGroup id="4">

<DisplayInformation>

<Name>Copy MSI log Files</Name>

<Description>

Copy the MSI log files of the installer service to certain folder.

</Description>

</DisplayInformation>

<Settings>

<CopyFile source="%temp%\MSI*.log" destination="%temp%\Installer Log" overwrite ="True"/>

</Settings>

</SettingsGroup>

 

<SettingsGroup id="5">

<DisplayInformation>

<Name>Delete MSI log Files</Name>

<Description>

Log files from Installer service will be deleted.

</Description>

</DisplayInformation>

<Settings>

<DeleteFile path ="%temp%\MSI*.log"/>

</Settings>

</SettingsGroup>

</SoftwareReset>


Save the updated Settings.xml file and return to the Troubleshooting Pack Designer to build the pack. Press F5 or select the button from the toolbar to sign and package the troubleshooting pack. The Troubleshooting Wizard will launch again. You will see the first prompt you created when customizing display information. Click “Next”. The next prompt should now look as follows:

clip_image010[4]

Please note that this troubleshooting pack is now capable of making changes to your computer. To observe one such change, leave the Troubleshooting Pack Wizard open at the above prompt and open the Windows Registry editor (go to Start, then type “regedit.exe” in the search box). Browse to the HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\Installer key. Take a look at the values listed in the right pane. In most cases, you will only see a string (REG_SZ) value with the name (Default):

clip_image011[4]

Go back to the Troubleshooting Wizard and select “Enable Windows Installer Logging” and click “Next”. The pack will now make the changes defined with the “Enable Windows Installer Logging” settings group in the Settings.xml file. After the pack completes the steps and runs a verifier script to ensure the computer has been set to the desired state, you should see a report as follows:

clip_image012[4]

Close this window, go back to the registry editor and press F5 to refresh the view. You should now see the following under the HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\Installer key:

clip_image013[4]

It is recommended to delete this key if you do not intend to create log files of all installations. This should be used only for troubleshooting purposes and should not be left on because it will have adverse effects on system performance and disk space. Each time you use the Add/Remove Programs tool in Control Panel, a new Msi*.log file is created in the %temp% folder.

To delete the key, you can manually do so by right clicking on it and selecting “Delete”. You can also package the troubleshooting pack from Troubleshooting Pack Designer again and select “Disable Windows Installer Logging”

Note: The troubleshooting pack itself is stored under Documents\Troubleshooting Packs\Software Reset Starter Pack\output\cab\ as “Software Reset Starter Pack.diagcab”. You can directly run this as a troubleshooting pack on your computer without using Troubleshooting Pack Designer. The .diagcab file is updated every time you package the troubleshooting pack in Troubleshooting Pack Designer.

 Completing the Project


Now that you have implemented all of your interactions you are ready to build the pack and use it for your needs.

Testing your custom pack


To run any troubleshooting pack, including one built from the Starter Kit, you must create\sign a security catalog and install a certificate. Troubleshooting Pack Designer handles all of this for you on the computer you use to build troubleshooting packs.

The easiest way to deploy the troubleshooting packs you have built on a different computer is to install the Generated Test Certificate for the pack on that computer. Troubleshooting Pack Designer creates this Test Certificate as part of the build process.

Use the following steps to build and deploy your troubleshooting pack with a Test Certificate on a new computer:

1. Build the troubleshooting pack in Troubleshooting Pack Designer by pressing F5 or Build>Run in the menu.
2. Navigate to the location of the built starter pack .diagcab file. In the case of the Software Reset Starter Pack, this will be under Documents\Troubleshooting Packs\Software Reset Starter Pack\output\cab\. Troubleshooting Pack Designer creates .diagcab files in C:\Users\%user%\Documents\troubleshooting packs\<your troubleshooting pack>\output\cab by default
3. Move this .diagcab file to the machine in which you would like to run it (i.e. the desktop)
4. Right click on the file and select “Properties”
5. Navigate to the Digital Signatures tab – highlight the line under Signature List and click “Details”
6. Click “View Certificate”
7.
Click “Install Certificate”

8. Click “Next”
9. Click “Place all certificates in the following store” and click “Browse”
10. Click to highlight “Trusted Root Certification Authorities” and click “OK”
11. Click “Next”
12. Click “Finish”
13. Prompt should return stating “The import was successful” – Click “OK”
14. Click “OK” to exit out of the Certificate Information screen

Your pack is now ready to be securely deployed on the target computer. Double click the .diagcab file and it will step through the troubleshooting logic you specified.

 

Sharing your pack outside your organization

 

To make your troubleshooting pack available for public use on the web, you must create a signed .diagcab file. If you would like to install your certificate as part of your troubleshooting pack, you will need to point Troubleshooting Pack Designer to a PFX file for which you have a location and password.

clip_image014[4]

For more information about packaging and security with the Windows Troubleshooting Platform, please review this section in the Windows 7 Troubleshooting Guide: http://msdn.microsoft.com/en-us/library/dd776530.aspx#PackagingAndSecurity.

 

 Starter pack reference – details, notes and best practices 

 

 

The following section provides details about the Settings.xml file structure, as well as notes and best practices for each of the operation elements (<SetRegValue>, <DeleteRegValue>, <RenameRegValue>, <CopyFile>, <DeleteFile>, and <RunCommand>).

 

Settings.xml reference

 

The <SoftwareReset> element is the main element of the xml file and must contain one or more <SettingsGroup> child element(s). Each <SettingsGroup> element represents a category of operations for which the developer can define in a specific sequence. The developer can use the <DisplayInformation> and <Settings> child elements of the <SettingsGroup> to create a series of list items in the user interface for the end user to choose from during pack deployment. A troubleshooting pack based on the Software Reset Starter Pack can have many Settings Groups with various quantities and combinations of operations within each.

The example below shows how elements and attributes within one Settings Group can be used to define a sequence of operations that create new a registry key value, delete a value, rename a value, copy a file, delete a file and run a command:

 

<SettingsGroup id="[group id]">

<DisplayInformation>

<Name>[Settings Group Name]</Name>

<Description>[Description of Settings Group]</Description>

</DisplayInformation>

<Settings>

<SetRegValue key="[registry key path]" value="[registry key value to add]" Type="[registry value type]" data="[registry value data]"/>

<DeleteRegValue key="[registry key path]" value="[registry key value to delete]"/>

<RenameRegValue key="[registry key path]" value="[registry key value to rename]" newValue="[new key value]"/>

<CopyFile source="[file path\filename to be copied]" destination="[new file path]" overwrite="[True or False]"/>

<DeleteFile path="[file path\filename to be deleted]"/>

<RunCommand commandline="[command line]"/>

</Settings>

</SettingsGroup>

 

Note: All actions specified in the XML file will run in the order listed under the <Settings> element. Thus it is very important to consider the order that you would run the operations if you were performing them manually.

The following list describes each element built into the Software Reset Starter Pack.

<SoftwareReset>

Root element for troubleshooting pack settings

Attribute:

xmlns:xsi

 

XML schema instance namespace

Attribute:

xsi:noNamespaceSchemaLocation

 

XML schema definition file for Settings.xml

Syntax:

<SoftwareReset xmlns:xsi="[Schema instance namespace]" xsi:noNamespaceSchemaLocation="[reference to definition file]"></SoftwareReset>

Example:

<SoftwareReset xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="Settings.xsd"></SoftwareReset>

Parent Element:

None

Child Element(s):

<SettingsGroup>

 

<SettingsGroup>

Element containing display information, settings and operations for the troubleshooting pack

Attribute:

id

 

Uniquely identifies the settings group for reference by the PowerShell Script. Default is "0", "1", "2", etc. Can be any string sequence, but must not contain spaces or non-alphanumeric characters, and must be unique from other settings groups

Syntax:

<SettingsGroup id="[group id]"></SettingsGroup>

Example:

<SettingsGroup id="0"></SettingsGroup>

Parent Element:

<Software Reset>

Child Element(s):

<DisplayInformation> and <Settings>

 

<DisplayInformation>

Settings Group name and description

Attribute:

None

   

Syntax:

<DisplayInformation></DisplayInformation>

Example:

<DisplayInformation></DisplayInformation>

Parent Element:

<SettingsGroup>

Child Element(s):

<Name> and <Description>

 

<Name>

Friendly name of Settings Group presented to the user in the selection list

Attribute:

None

   

Syntax:

<Name>[Name of Settings Group]</Name>

Example:

<Name>SettingsGroupA</Name>

Parent Element:

<DisplayInformation>

Child Element(s):

None

 

<Description>

Friendly description of Settings Group that appears as a tooltip when the user hovers over the name in the UI. Also shows in troubleshooting report details at end of deployment

Attribute:

None

   

Syntax:

<Description>[Description of Settings Group]</Description>

Example:

<Description>Description of SettingsGroupA</Description>

Parent Element:

<DisplayInformation>

Child Element(s):

None

 

<Settings>

Defines the list of operations that will take place in each Settings Group

Attribute:

None

   

Syntax:

<Settings></Settings>

Example:

<Settings></Settings>

Parent Element:

<SettingsGroup>

Child Element(s):

<SetRegValue>, <DeleteRegValue>, <RenameRegValue>, <CopyFile>, <DeleteFile>, and <RunCommand>

 

<SetRegValue>

Create a new value under existing or new registry key. Also change an existing value’s data

Attribute:

key

 

Full path to new or existing registry key containing value or data to be set. Please refer to the Registry Modification Notes/Best Practices for notes and syntax

Attribute:

value

 

Name of registry value to be created or changed

Attribute:

type

 

Registry value type. Please refer to the Registry Modification Notes/Best Practices for syntax

Attribute:

data

 

Registry value data

Syntax:

<SetRegValue key="[registry key path]" value="[registry key value to add]" Type="[registry value type]" data="[registry value data]"/>

Example:

<SetRegValue key="HKLM:\Software\Microsoft\Windows\CurrentVersion"

value="myKeyA" Type="REG_SZ" data="HelloWorldA"/>

Parent Element:

<Settings>

Child Element(s):

None

 

<DeleteRegValue>

Delete an existing value under existing registry key

Attribute:

Key

 

Full path to existing registry key containing value to be deleted

Attribute:

Value

 

Name of registry value to be deleted

Syntax:

<DeleteRegValue key="[registry key path]" value="[registry key value to delete]"/>

Example:

<DeleteRegValue key="HKLM:\Software\Microsoft\Windows\CurrentVersion"

value="KeyToDeleteA"/>

Parent Element:

<Settings>

Child Element(s):

None

 

<RenameRegValue>

Rename an existing value under existing registry key

Attribute:

Key

 

Full path to existing registry key containing value to be renamed

Attribute:

Value

 

Name of registry value to be renamed

Attribute:

newValue

 

New name of registry value

Syntax:

<RenameRegValue key="[registry key path]" value="[registry key value to rename]" newValue="[new key value]"/>

Example:

<RenameRegValue key="HKLM:\Software\Microsoft\Windows\CurrentVersion"

value="KeyToRenameA" newValue="newkeyA"/>

Parent Element:

<Settings>

Child Element(s):

None

 

<CopyFile>

Copy a file from one location to another

Attribute:

source

 

File system path to source file to be copied

Attribute:

destination

 

File system path to destination folder

Attribute:

overwrite

 

True or false to overwrite if file exists in destination folder

Syntax:

<CopyFile source="[file path\filename to be copied]" destination="[new file path]" overwrite="[True or False]"/>

Example:

<CopyFile source="%windir%\notepad.exe" destination="%userprofile%\desktop" overwrite="True"/>

Parent Element:

<Settings>

Child Element(s):

None

 

<DeleteFile>

Delete a file from a specified location

Attribute:

path

 

File system path to file to be deleted

Syntax:

<DeleteFile path="[file path\filename to be deleted]"/>

Example:

<DeleteFile path="%userprofile%\desktop\notepad.txt"/>

Parent Element:

<Settings>

Child Element(s):

None

 

<RunCommand>

Delete a file from a specified location

Attribute:

Commandline

 

Command to be run from command prompt

Syntax:

<RunCommand commandline="[command line]"/>

Example:

<RunCommand commandline="start www.bing.com"/>

Parent Element:

<Settings>

Child Element(s):

None

 

The following sections outline XML based functions and best practices when implementing each category of operations in the Software Reset Starter Pack: registry, file, and command line.

 

Registry modification notes/best practices – Using <SetRegValue>, <DeleteRegValue>, and <RenameRegValue>

 

n  Binary registry value type (REG_BINARY) creation is not supported by the Software Reset Starter Pack.

n  When using <SetRegValue> and the key for the value to be added does not exist, then the troubleshooting pack will create it.

n  When using <DeleteRegValue> and the value to be deleted does not exist then the troubleshooting pack will not report an error.

n  It is highly recommended to perform a registry backup before making changes to the registry. It may be possible to mistakenly use incorrect data for creating or changing registry keys, which may affect the target machine in unexpected ways. Please refer to Back up the registry on the Windows 7 support website. It is also recommended that you create a backup only of the individual key or subkey you are attempting to modify.

n  Registry access rights: You must be careful to ensure that the proper read-write permissions on registry keys are in place before making changes. The troubleshooting pack runs at the permission level of the current user. Some subkeys are set to read-only, or may not be written to via script. A troubleshooting pack built with the Software Reset Starter Pack will respect the security settings for each key. For example, if a key is read-only and you attempt to modify it with the troubleshooting pack, it will return the following error: “[yourKeyName]” could not be set.

n  Syntax: This Starter Pack supports several types of syntax when referencing registry key paths within the Settings.xml file. The following table shows a list of predefined keys in Windows and reference syntax, followed by examples of different kinds of registry key paths that are handled by the Settings.xml file:

Predefined key handle 

Abbreviated name 

PowerShell syntax 

HKEY_CLASSES_ROOT\ 

HKCR:\

Registry::HKEY_CLASSES_ROOT\

HKEY_CURRENT_CONFIG\ 

HKCC:\

Registry::HKEY_CURRENT_CONFIG\

HKEY_CURRENT_USER\ 

HKCU:\

Registry::HKEY_CURRENT_USER\

HKEY_LOCAL_MACHINE\ 

HKLM:\

Registry::HKEY_LOCAL_MACHINE\

HKEY_USERS\ 

HKU:\

Registry::HKEY_USERS\

 

"HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion"

"HKLM:\Software\Microsoft\Windows\CurrentVersion"

"Registry::HKEY_LOCAL_MACHINE\Software\Microsoft\Windows\CurrentVersion"

n  The Settings.xml file only supports the following case-sensitive format and values as registry value type attributes:

Value Type

Description

REG_SZ

String

REG_DWORD

32-bit number (hex or decimal)

REG_QWORD

64-bit number (hex or decimal)

REG_MULTI_SZ

Sequence of null terminated strings (i.e. String1\0String2\0String3\0LastString\0\0)

REG_EXPAND_SZ

Null terminated string that contains unexpanded references to environment variables (i.e. %PATH%)


The following example shows the creation of a string-type registry value named “Logging” in the HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\Installer registry subkey:

<SetRegValue key="HKEY_LOCAL_MACHINE\Software\Policies\Microsoft\Windows\Installer" value="Logging" type="REG_SZ" data="voicewarm"/>

 

n  When using <RenameRegValue> and the value to be renamed does not exist then the troubleshooting pack will report that it was unable to automatically fix all of the issues found similar to the screen below. To diagnose the issue further, click “Detailed information” at the bottom of the report window:


clip_image015[4]

Viewing “Detailed information” at the bottom of the report window will show that the update has completed, but the task failed. Click on “Rename Registry Value” to expand it.

clip_image016[4]

In this case, running <RenameRegValue> resulted in an error because the value to be renamed did not exist:

clip_image017[4]

 

 

File modification notes/best practices – Using <CopyFile> and <DeleteFile>

n  When using <CopyFile>, if the destination directory does not exist, then it will be created.

n  When using <CopyFile>, if a file being copied does not exist in the specified location, you will get an error.

n  When using <DeleteFile>, if the file to be deleted does not exist in the specified location, the troubleshooting pack will not report an error. This is because the verifier script only checks to see whether the file is in not present at the end of pack deployment. This highlights how the verifier checks for a desired end state on the system.

n  It is considered a best practice (but not required) to use user or system environment variables when specifying paths. Please see this article for recognized environment variables.

Command line notes/best practices – Using <RunCommand>

n  There is no verifier associated with this operation and will always return fixed, even if there was no result because the command failed. If the command you are attempting to run makes modifications to the system, then you should write your own scripts as part of the troubleshooter to check for those modifications. This operation is ignored when the pack evaluates whether it has fixed the problem or not.


 Software Reset Starter Pack help and support

 

 

For support with this Starter Kit, please make comments as feedback on the project page discussion on the project page:

http://softwareresetstarterpack.codeplex.com/discussions

If you find something you know that appears to be a bug, please post your issue here:

http://softwareresetstarterpack.codeplex.com/workitem/list/basic

 Feedback and contribution

 

 

Feedback on this Starter Pack is welcome and needed. Please give it the star rating you think it deserves and please leave comments that will benefit the development team behind this project as well as the community. This is a work in progress, and is being hosted on Codeplex based on the assumption that the developers who use this will understand its benefit and provide feedback to make it better. Long term we hope to enable others to share their own solutions made with this Starter Pack. For the time being, we need feedback to guide this free project’s development.

<script type="text/javascript">// <![CDATA[ var sc_project=7504474; var sc_invisible=0; var sc_security="f38d3600"; // ]]></script>

<noscript>

</noscript>

Last edited Dec 19, 2011 at 7:55 PM by ivonak, version 9

Comments

No comments yet.