Skip to content

Instantly share code, notes, and snippets.

@MyITGuy
MyITGuy / Invoke-WinSxSTempCleanup.psm1
Last active May 20, 2024 22:01
On Windows, the WinSxS InFlight folder can grow to thousands of folders, subfolders and files. When DISM component analysis and cleanup operations are performed, this causes enumeration of the folders, subfolders and files.
function Invoke-WinSxSTempCleanup {
[CmdletBinding()]
param(
[string[]]
$ScanID
)
begin {
#region Enable Privilege function
function Enable-Privilege {

ComponentCleanup progress appears to hang.

  • StartComponentCleanup after progress at 100%
  • AnalyzeComponentStore after progress at 17%

Preface

TiWorker.exe is still working. Do not stop the TiWorker.exe process. Instead, analyze its progress, which make take hours...or longer.

function Get-DirectoryHash {
[CmdletBinding()]
param(
[System.IO.DirectoryInfo]
$Path
,
[switch]
$IncludeName
)

Flexera App Portal Web Extension Design Flow

Disclaimer

The information provided in this documentation was neither created by, nor is supported by, Flexera. It is my understanding of how the product works based on objective data.

Preface

This understanding makes the following assumptions:

AFFECTED VERSION

     Recast Right Click Tools Console Extension 5.4.2402.1403

BUG DEFINITION

     When the Check for Bugfix Updates checkbox option is checked, and the update check is preformed (occurs once a day), the consumer receives a prompt.

UNEXPECTED USER EXPERIENCE

function Get-KNOWNFOLDERID {
<#
.SYNOPSIS
Lists KNOWNFOLDERID data.
.DESCRIPTION
Reads the registry and outputs a PSCustomObject and contains the KNOWNFOLDERID data.
.PARAMETER KNOWNFOLDERID
Limits the output to the provided KNOWNFOLDERID.
.OUTPUTS
After upgrading to Configuration Manager 2309 on Windows Server 2022, clicking on a console node that utilizes Microsoft Edge WebView2 causes the console node to present a blank view and subsequently crashes the console with a message stating _Microsoft.ConfigurationManagement has stopped working._
There is a known issue with Microsoft Edge and Microsoft Edge WebView2 whereas the executable will crash and reopen, constantly, causing a WerFault.exe storm to occur.
The workaround for Microsoft Edge is described in the **Known issues in this update** for the [January 9, 2024—KB5034129 (OS Build 20348.2227)](https://support.microsoft.com/en-us/topic/january-9-2024-kb5034129-os-build-20348-2227-6958a36f-efaf-4ef5-a576-c5931072a89a) cumulative update.
function Get-WinREPartitionInfo {
[CmdletBinding()]
param()
if ( $false -eq (New-Object System.Security.Principal.WindowsPrincipal([System.Security.Principal.WindowsIdentity]::GetCurrent())).IsInRole([System.Security.Principal.WindowsBuiltInRole]::Administrator) ) {
Write-Warning "Please run this as an administrator."
return
}
#region REAGENTC.EXE to PSCustomObject
$AddressToSite = Get-AddressToSite
$DomainNetwork = Get-DomainNetwork
$AddressToSite | Add-Member -MemberType NoteProperty -Name 'IPSubnet' -Value $DomainNetwork.Subnet
$AddressToSite | Add-Member -MemberType NoteProperty -Name 'DC' -Value $DomainNetwork.DC
$AddressToSite | Add-Member -MemberType NoteProperty -Name 'DCSiteName' -Value $DomainNetwork.DCSiteName -PassThru
#region Get-CMInstallPath
function Get-CMInstallPath {
function Split-CommandLine {
[CmdletBinding()]
Param
(
[Parameter(Mandatory = $false, ValueFromPipeline = $true, ValueFromPipelineByPropertyName = $true, Position = 0)]
[ValidateNotNullOrEmpty()]
[string]$CommandLine
)