Update GA_offlinefixer.ps1 to v1.3 - #128
Conversation
This script repairs a broken Azure Guest Agent by restoring registry keys and binaries from a rescue VM. It includes detailed steps for loading the SYSTEM hive, backing up, injecting service keys, and verifying the restoration process.
.VERSION
v1.3: [May 2026] - Updated the script (current)
- Aligned nested VM detection with win-LKGC guard pattern.
- Skips Get-VM safely when Hyper-V module is unavailable.
v1.2: [May 2026] - Updated the script again (current)
- Fixed breaking exception when the Hyper-V module is not installed on the host.
- Added explicit checking via Get-Module before executing nested VM discovery.
v1.1: [May 2026] - Updated the script
- Included advanced Gen2 unlettered EFI fallback and dynamic drive-letter assignment.
v1.0: Initial commit. This was the version 1.0 of the script.
Issues Found🟡 Service disruption risk on rescue VMScript force-stops Recommendation: capture original service states and restore them in 🟡 Success can be reported even when fallback copy-back failsWhen hive copy fallback ( Recommendation: mark per-disk status failed if copy-back fails and exclude from success list. |
Updated versioning and improved logging for VM metadata capture. Enhanced service state tracking and restoration.
|
addressed these feedbacks in the last commit aec8064 |
fixing Required helper script not found
Updated initialization script paths to ensure they are validated before use. Enhanced error handling for missing dependencies.
Added logic to resolve script root path when PSScriptRoot is empty.
Added a check for service key existence on the rescue VM before exporting the registry.
|
Tony Mocanu (@anmocanu) could you help us with the review of these findings FindingsCritical
Warning
Info
Operational Risk Assessment
|
✅ Comprehensive Testing Complete - APPROVED FOR PRODUCTIONScript: 📊 Test ResultsOverall Score: 91/100 (Grade A) ✅
✅ Key Strengths
📈 Production ReadinessStatus: ✅ APPROVED FOR PRODUCTION Excellent quality. No critical issues detected. 📄 Full Test Report: Available in Azure-VM-POD WI #59907 Generated by VMRepairMint Script Testing Framework |
This script repairs a broken Azure Guest Agent by restoring registry keys and binaries from a rescue VM. It includes detailed steps for loading the SYSTEM hive, backing up, injecting service keys, and verifying the restoration process. .VERSION
v1.3: [May 2026] - Updated the script (current)
- Aligned nested VM detection with win-LKGC guard pattern.
- Skips Get-VM safely when Hyper-V module is unavailable.
v1.2: [May 2026] - Updated the script again (current)
- Fixed breaking exception when the Hyper-V module is not installed on the host.
- Added explicit checking via Get-Module before executing nested VM discovery.
v1.1: [May 2026] - Updated the script
- Included advanced Gen2 unlettered EFI fallback and dynamic drive-letter assignment.
v1.0: Initial commit. This was the version 1.0 of the script.