Drive Letter Problems
Restore Original Windows Drive Letter
In previous WinNT operating systems you can have problems with clones or restored images when they do not correctly see themselves as the same drive letter as the parent install. This usually results in major issues and even cross-linked installs where files from both the parent and the clone will be used during bootup. The main cause of trouble is the way WinNT remembers drive letters and stores this information in its registry. When the clone boots it will look at its cloned registry and be inclined to retain the drive letters that the parent has assigned to partitions. This is obviously a problem if you need the clone to assign a different drive letter to the partition it has just been moved to. If the parent saw itself as the C: drive then the clone will also have to see itself as the C: drive, so problems can occur if the clone's registry is telling it that the partition it is now on should be the E: drive. Avoiding such problems in XP can require hiding partitions to prevent the parent install from assigning letters to target partitions, and to prevent a first time booting clone from assigning the C: letter to the parent partition. With Vista however I have found that in most cases it is capable of automatically adapting to make its new partition the drive letter that it needs to be, regardless of whether the parent or any other partition is hidden or not. I'm only getting a few exceptions to this and mainly only for logical partitions on second or higher hard drives, but even this can be avoided by just hiding all partitions on the boot drive during the first boot of the new clone.
If you do have trouble with a clone or restored image assigning itself the wrong drive letter you should still be able to boot Vista by clicking through various dll errors and so eventually get to a limited desktop, or in some cases just to a completely blank light blue screen. In previous WinNT recovering the OS from this situation could be a chore, but in Vista it is relatively easy and can often be done from that limited desktop. All you have to do is change the drive letter to what it needs to be. Once you reach the limited desktop or the blank screen press Ctrl+Shift+Esc or Ctrl+Alt+Del to open Task Manager and then click 'New task...' and run diskmgmt.msc and once the Disk Management utility fully opens determine which drive letter has been assigned to your cloned or restored Windows install. Then 'New task ...' again and this time run regedit and navigate to the key described in the screenshot below. Right click on the \DosDevices\ entry that has the letter currently assigned to the install in question and choose 'rename' and change the letter to the one that the parent install sees itself as when you are booted into it. If the clone's registry already has that letter assigned to another DosDevices entry you will need to change that one first to free up the required letter. You can make it anything for now as you can change it again later in Disk Management once you are fully into Windows.
If regedit or diskmgmt refuses to open for you in the steps above then try doing it all from safemode. (In Win7 in safemode you will have to tick a new option "Create this task with administrative privileges."). If you still can't get Disk Management to open but regedit works then you can make an educated guess as to which DosDevice is your desired target and change its letter and try rebooting. Repeat if necessary with each entry in turn until you get the right one. Or you could just delete all entries and let Windows completely rebuild the list on reboot. This may do the job, or just take you back to where you started. Completely clearing the drive letter list is a useful trick in XP based operating systems to help cure certain drive letter problems, but it has risks and should never be attempted unless you are sure you know what you are doing and have backups to restore the OS or at the very least the registry. For Vista or Win7 OSes that are already having problems then you have little to lose and should still be able to recover with the procedures described on this page.
The amount of entries in MountedDevices can range from several to dozens.
There are many factors that can make changing drive letters a hazard to the health of an operating system and so I must stress that I am only suggesting this for Windows installs that are fully independent and have no links to any other partitions on any drive. If you are using Window's own bootmanager for a dual or multiboot, or have any kind of hardware or software RAID or Dynamic Disk arrangement, or you have made any changes you don't fully understand with apps like EasyBCD or VistaBootPro, then you are advised to avoid changing anything in the MountedDevices key. There may also be some backup and restore software or even some Anti Virus or process monitoring apps that may cause problems, so unless you know the history of a system, or are backed up and prepared for disaster, then proceed no further.
The minimum requirement for modifying entries in the MountedDevices folder of an operating system is that the OS should see itself as the C: drive, it should be both its own System and Boot partition, and it should be on a primary partition on the boot hard drive. Under such circumstances it is normally possible to completely clear all entries (except the top default one), or even delete the entire MountedDevices folder, as it will be recreated on reboot with the default letters for all of the re-discovered devices. If the system was already using the default letters then all should be good and the rebuilt list will only have valid and required entries, which you can further tweak in Disk Management if you want to set specified drive letters for optical drives or data partitions. If however the system had not originally been configured to the standard defaults then the operating system drive letter may be changed and you could have serious problems.
The safer option
When cloning or re-imaging Windows to a different partition it can in some circumstances be useful to clear out the MountedDevices list in the parent install before making the move. As in the previous situation you can retain the Windows drive letter by keeping the relevant \DosDevices\ line. In this instance however you should not retain the matching \??\Volume line, because you need it to be re-created during first bootup to match the new partition (volume) that Windows has been moved to.