A quite common issue when doing OS Deployment with ConfigMgr is that there is a mismatch on the packages on one or more DPs. The result on the client is an error message in the smsts.log saying: The hash value is not correct, and the error code is 0x80091007.
The fix is typically to update the DP(s) for that package, which calculates a new hash value (checksum). But how can you verify this without doing a deployment of a device or VM? Standalone media to the rescue. When you create a standalone media in ConfigMgr it performs the same checks as a deployment would, but you can create this media with PowerShell to get an instant validation of all packages referenced by the task sequence. Here is an example:
Create Standalone Media using PowerShell – The Script
Please note that this script will only validate packages the task sequence knows about (packages that are referenced by the task sequence).
# Set variables
$SiteCode = "PS1"
$DP = "dp01.corp.viamonstra.com"
$Media = "E:\Setup\standaloneMedia.iso"
# Import ConfigMgr Module
Import-Module (Join-Path $(Split-Path $env:SMS_ADMIN_UI_PATH) ConfigurationManager.psd1)
cd "$SiteCode`:"
# Create the standalone media
$TaskSequence = Get-CMTaskSequence -Name "Windows 11 Enterprise x64 22H2 Native with MDM CMG" -Fast
$DistributionPoint = Get-CMDistributionpoint -SiteSystemServerName $DP
New-CMStandaloneMedia -MediaType CdDvd -MediaSize SizeUnlimited -Path $Media -TaskSequence $TaskSequence -DistributionPoint $DistributionPoint
Troubleshooting
For troubleshooting check the CreateTsMedia.log file, the default location is C:\Program Files (x86)\Microsoft Configuration Manager\AdminConsole\AdminUILog