Important Note
Firstly, please try to reproduce the same BSOD issue with the MasterImage VM by publishing it with "Other service or technology" option in Citrix Studio > Create Machine Catalog. Suppose the BSOD issue can be reproduced, please simply follow step 1-4 to collect the crash dump from the MasterImage VM with the rest steps skipped.
Key Steps
1. Take a VM snapshot for the MasterImage VM as a backup
2. In hypervisor console, add a secondary disk to the MasterImage VM, whose size is able to hold a full memory dump (e.g. 2~3 x RAM size).
3. In the MasterImage VM, initialize the disk, format and assign it a drive letter (e.g. E:\).
4. In the MasterImage VM, configure Windows to write dumps to the secondary disk,
4.1 Go to System Properties > Advanced System Settings > Startup and Recovery > System failure, and set,
"Automatically restart" - ticked
"Write debugging information" - select "Complete Memory Dump"
"Dump file" - the secondary disk path, e.g. E:\MEMORY.DMP
"Overwrite any existing file" - ticked
4.2 Go to System Properties > Advanced System Settings > Advanced > Performance > Advanced, and set,
"Automatically manage paging file size for all drives" - unticked
"Paging file size for each drive" - select the disk drive letter assigned in step 3
"Custom Size" - tick and set both Initial Size and Maximum Size as 1.5 x RAM Size
4.3 Go to registry path [HKLM\SYSTEM\CurrentControlSet\Services\CVhdFilter\Parameters] and set the registry value in case MCS/IO is enabled.
"EnableDedicatedDumpFile"(REG_DWORD)=0
4.4 Reboot the MasterImage VM
5. Shutdown the MasterImage VM, detach the secondary disk from hypervisor console and then create another VM snapshot
6. In Citrix Studio, update the Machine Catalog with the MasterImage VM snapshot created in step 5, so that the above memory dump settings in the MasterImage VM can be reflected to the MCS provisioned machines in the catalog.
7. After the machine catalog update is successfully done, in hypervisor console, attach the previous disk (detached from the MasterImage VM in step 5) to a MCS provisioned machine in the catalog.
8. Bootup the MCS provisioned machine, login Windows and confirm that,
8.1 the disk attached in step 7 is well recognized in Windows "This PC" with the same driver letter as what you set in step 3
8.2 the Windows dump settings configured in step 4.1/4.2/4.3 have been duplicated to the machine
9. Reproduce the BSOD incident with the MCS provisioned machine.
10. After the MCS provisioned machine being auto rebooted, gather MEMORY.DMP file generated by Windows OS under the file path specified in step 4.1.
The article describes the key steps of collecting Windows OS crash (BSOD) dump in a non-persistent machine provisioned by MCS.