Changing the Windows System Drive Letter

Sometimes Windows system drive letters get altered. Here's a procedure you can try when you can't use the Control Panel's Disk Management tools to solve the problem.

Bret A. Bennett

June 23, 2010

4 Min Read
abstract gear shapes
Alamy

Sometimes Windows system drive letters get altered, and the Control Panel's Disk Management tools can't solve the problem because the drive has to be dismounted. However, it's possible to quickly fix this problem without dismounting the drive.  Here's how I recently did so.

A customer called and said that when he logged on to his Windows XP Pro machine, the desktop icons were there, but they were missing the icon artwork. In addition, while some of the icons still worked, others displayed various error dialog boxes.

Using our company's remote management software, I accessed his computer and opened Windows Explorer. I noticed that the system drive letter (i.e., the drive where Windows is located) was no longer C. Instead, it was D, which was a data storage hard drive on his system.

In Control Panel, I selected Administrative Tools, then Computer Management. After expanding the Storage branch, I selected Disk Management. In the Disk Management window, you can typically right-click the partition of interest, select Change Drive Letters and Paths, click Change, and select an available drive letter for the Assign the following drive letter option. In this case, however, I received a dialog box with the following message: Windows cannot modify the drive letter of your system volume or boot volume.

Related:Windows 11 Migration Guide: 4 Best Practices When Upgrading

After a little research, I discovered the Microsoft article "How to restore the system/boot drive letter in Windows." This article provided the steps I needed to correct the problem. However, even though Microsoft stated that the information was applicable to XP, Windows Server 2003, and Windows 2000, I found a few steps unnecessary when you're applying it to XP.

Basically, "How to restore the system/boot drive letter in Windows" tells you how to do a little shell game with the OS drive letter. (The article assumes that C is the real OS drive or partition and D is a real non-OS drive or partition on your system.) First, you temporarily rename the non-OS drive (the one that's incorrectly labeled as C) to Z. Next, you rename the real OS drive letter (the one that's incorrectly labeled as D) to C. Finally, you rename the non-OS drive letter from Z to the correct letter of D.

The HKLMSYSTEMMountedDevices registry key is used to rename the OS and non-OS drives. In a nutshell, the article tells you to log on as an Administrator, use regedt32 to change this key's permissions to Full Control for the Administrators security group if necessary, use regedit to rename the drives, then use regedt32 to change the permissions back. (See Figure 1.)

Related:Tracking Windows Group Policy Changes With PowerShell

However, note that:

  • In XP and later, regedt32 redirects to regedit. So, if you're using XP or later, you can open regedit in step 3 and use it throughout, which makes steps 8 and 17 unnecessary. (If you're running Win2K Pro, you still need to use regedt32.)

  • Although the "How to restore the system/boot drive letter in Windows" article doesn't mention it specifically, if the problem PC is in a domain environment, you should log on as the domain's administrator (or a member of the Domain Administrators security group). If the problem PC is in a nondomain (i.e., local) environment, you should log on as the local PC's administrator (or user who is a member of the Local Administrators security group). Otherwise, the permissions will be greyed out and you won't be able to change them if necessary. If you do change the permissions, remember to return the permissions to the previous setting for Administrators, as step 18 instructs you to do.

After I applied this procedure on the customer's PC, the desktop icons had their artwork back and all the desktop icons launched their respective programs without error. I then ran both a full system virus scan and Windows Defender scan, but nothing turned up. I suspect that some form of malware or a browser script sneaked through the antivirus defense line and perpetrated this registry-based annoyance.

Related:Comparing Windows VM Installation Times: HDD vs. NVMe vs. RAM

If malware or something else wreaks havoc with the Windows system drive letters on users' PCs, you might want to try this procedure. Note that you need to be comfortable with using regedit and possibly regedt32. Before you attempt to implement it, though, I strongly recommend that you manually create a restore point. The Microsoft article "How to back up and restore the registry in Windows XP" provides instructions and even a help guide. The article also provides links to instructions on how to back up the registry in Windows 7.0 and Windows Vista.

Sign up for the ITPro Today newsletter
Stay on top of the IT universe with commentary, news analysis, how-to's, and tips delivered to your inbox daily.

You May Also Like