In System Center Configuration Manager (SCCM) applications are typically deployed and managed in one of two ways: Applications and Packages.
Sometimes you need something a little more powerful. When we originally installed KwikTag, it didn’t have an installer. It was a folder that had to be copied to the computers and run a batch file to register the dll’s. Now we need to upgrade, which involves unregistering the dll’s, deleting files out of each user’s %appdata% folder, and finally deleting the folder out of “Program Files”. If that weren’t enough, the upgrade must include logic for “Program Files” as well as “Program Files (x86)”, and I have a mix of computers with the old version, the new version, and no version installed.
Normally SCCM Task Sequences are for operating system deployment, but you can use them for much more.
When creating the Task Sequence, choose “New custom task sequence” and do not choose a boot disk.
Here’s my overall “Upgrade KwikTag” Task Sequence:
You’ll notice that I grouped the steps and used an “If” condition to specify to only run the TS if none of the conditions are true, as in only if the new version of the application is not installed. For all except the Install and Restart, I checked “Continue on Error” which covers those cases in which the program was never installed and the files don’t exist.
My Powershell script loops through the all user’s %appdata% folder and cleans up the files.
I recently noticed that one of my computers was connecting to an SMP/DP across a T1 to a remote office to store user state during OSD. After reviewing the logs I saw that it was connecting to the local DP for content, but not for user state storage.
I couldn’t find anything in the logs that explained this behavior, and I checked my boundaries and boundary groups and everything looked good. After failing to resolve this on my own over a few days, I opened a ticket with Microsoft support.
It turns out that while using boundaries to connect a client to the local DP is a feature, connecting to the SMP at the local site is not and the client can connect to any writable SMP, even if its across your slowest WAN connection to a remote office.
You have two options to avoid having the client connect across the WAN for user state storage; check “Enable restore-only mode” in your State Migration Point properties under Administration > Servers and Site System Roles, or check “Capture locally by using links instead of copying files” under the “Capture User Files and Settings” step in your OSD.
Enabling restore-only mode will prevent the SMP from being used to store user state, and user state already stored on the SMP is still available. The problem with this approach is that not only will your other sites not use that SMP to store user state, the local clients won’t use it either so they will be sending user state across the WAN to another SMP. You may have to enable or disable this setting as needed, for example if you are imaging multiple workstations in the same office you could enable this setting on all other SMP’s except the one at the site where computers are being imaged.
Capturing locally by using links instead of copying files would prevent you from having to remember to change the SMP settings frequently as it would be a “set it and forget it” solution which is what I prefer.
Product: Java 8 Update 25 — Error 1722. There is a problem with this Windows Installer package. A program run as part of the setup did not finish as expected. Contact your support personnel or package vendor. Action installexe, location: C:WINDOWSInstallerMSI789B.tmp, command: /s INSTALLDIR=”C:Program Files (x86)Javajre1.8.0_25\” EULA=0 REPAIRMODE=0
Error 1722. There is a problem with this Windows Installer package. A program run as part of the setup did not finish as expected. Contact your support personnel or package vendor.
Fix: Put this in your Installation program: msiexec /i jre1.8.0_25.msi JU=0 JAVAUPDATE=0 AUTOUPDATECHECK=0 RebootYesNo=No WEB_JAVA=1 /q
WMI Explorer looks like a useful tool for the Windows and SCCM admin. From http://wmie.codeplex.com/
WMI Explorer is a utility intended to provide the ability to browse and view WMI namespaces/classes/instances/properties in a single pane of view.
• Ability to browse and view WMI namespaces/classes/instances/properties in a single pane of view.
• Ability to provide alternate credentials for connecting to remote computers.
• Ability to filter classes and instances matching specified criteria.
• Ability to view classes/instances in Managed Object Format (MOF).
• Ability to search classes, methods and properties with names matching specified criteria.
• Ability to run custom WQL queries.
• Automatic generation of WQL query for the selected Class/Instance.
• Automatic script creation (PowerShell and VBS).
• Highlighting of objects that have been previously viewed in the same session.
• Lists property enumeration values (if available). This is generally useful for SMS Provider classes.
• Lists property values containing embedded objects. This is especially useful for SMS Provider classes.
• Caching of retrieved classes/instances.
Some days SCCM will have you pulling your hair out in frustration. I frequently get errors when my OSD TS are installing programs or applications. It will work fine one time then fail the next.
This is the error I’m talking about:
Severity,Type,Site code,Date / Time,System,Component,Message ID,Description
Error,Milestone,NFK,8/19/2014 11:56:08 AM,COMPUTERNAME,Task Sequence Engine,11135,The task sequence execution engine failed executing the action (Run Command Line Copy default backgound image) in the group (Setup Operating System) with the error code 2147942402 Action output: … 02 (e:nts_sccm_releasesmsframeworktscoreresolvesource.cpp,3273) TS::Utility::ResolveSource (pszPkgID, sPath, 0, hUserToken, mapNetworkAccess), HRESULT=80070002 (e:nts_sccm_releasesmsclientosdeploymentinstallsoftwareruncommandline.cpp,399)cmd.Execute(pszPkgID, sProgramName, dwCmdLineExitCode), HRESULT=80070002 (e:nts_sccm_releasesmsclientosdeploymentinstallsoftwaremain.cpp,372) WinHttpSendRequest failed. SendWinHttpRequest failed. 80072ee2. DownloadFile() failed for http://SERVER -FQDN:80/SMS_DP_SMSPKG$/NFK00079/sccm?/backgroundDefault.jpg, C:_SMSTaskSequencePackagesNFK00079backgroundDefault.jpg. 80072ee2. Error downloading file from http://SERVER -FQDN:80/SMS_DP_SMSPKG$/NFK00079/sccm?/backgroundDefault.jpg toC:_SMSTaskSequencePackagesNFK00079backgroundDefault.jpg DownloadFiles() failed. 80072ee2. Download() failed. 80072ee2. Failed to resolve the source for SMS PKGID=NFK00079, hr=0x80070002 Install Software failed to run command line, hr=0x80070002. The operating system reported error 2147942402: The system cannot find the file specified.
To fix this, add the following Task Sequence Variables to the top of your TS.
SMSTSDownloadRetryCount = 5
SMSTSDownloadRetryDelay = 15