Change Citrix Drive C: back to M:
We have our Citrix server set to boot from the M: drive. Sometimes when doing system maintenance, the drive is changed back to C:. This happens when the signature of the disk changes, like when I used the procedures in this post to align the partition of the virtual machine.
When this happens, Windows tries to load critical DLL files from the M: drive that doesn't exist on boot. I get an error that Windows will shutdown because the ctxgina.dll can't load from the M: drive.
I use a rescue CD that I created by using the excellent BartPE utility. Boot to BartPE.
Click Run and enter regedit.exe to run the Registry Editor program.
Navigate to the HKEY_LOCAL_MACHINE hive. This hive is the registry for BartPE.
Click File adn then Load Hive to load a registry file from disk.
Select the c:\winnt\system32\config or c:\windows\system32\config directory.
Open the file named SYSTEM
Give the hive a name. I used "CitrixSystemHive"
Open this new hive and open the MountedDevices key.
Locate \DosDevices\C: and rename to \DosDevices\M:. If there is already an M:, then rename that to a different drive letter first.
Unload the hive file by clicking File and then Unload Hive. Choose Yes to confirm.
Shut down, remove the BartPE disk, and reboot.