Untitled
unknown
plain_text
2 years ago
820 B
9
Indexable
$DumpFolderPath = "C:\Minidump" # Specify the folder path where you want to save the minidump files
# Create the dump folder if it doesn't exist
if (-not (Test-Path -Path $DumpFolderPath)) {
New-Item -ItemType Directory -Path $DumpFolderPath | Out-Null
}
# Set the system to create minidump files
[System.Diagnostics.Process]::Start("wmic", "RECOVEROS SET DebugInfoType = 3") | Out-Null
# Collect the minidump files
Get-ChildItem -Path "$env:SystemRoot\Minidump\*.dmp" | ForEach-Object {
$DestinationPath = Join-Path -Path $DumpFolderPath -ChildPath $_.Name
Copy-Item -Path $_.FullName -Destination $DestinationPath -Force
}
# Set the system to create full memory dump files (optional, comment out if not needed)
[System.Diagnostics.Process]::Start("wmic", "RECOVEROS SET DebugInfoType = 1") | Out-Null
Editor is loading...