Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Why does Windows always mount a USB drive as the next drive letter after the last physical drive, even when that letter is already taken by a mapped drive, and is there any way to improve this behaviour?

What happens is I tend to use a few different flash drives on my PC, as well as having both a Blackberry and a personal phone that mount as USB drives when I plug them in to charge. Being on a corporate PC I also have a number of mapped network drives (some set by login script, some set as persistent mappings in my profile).

When I first login I'll have drive letters like this:

C: - Local Drive
D: - DVD Drive
G: - Login script mapped drive
J: - Login script mapped drive

When I plug the Blackberry in it'll mount two drives (one for onboard storage, one for the SD card) as E: and F:. If I then plug in another USB drive it will mount as G:, even though that's already taken by a network mapped drive. This leaves me with the following drives:

C: - Local Drive
D: - DVD Drive
E: - USB drive (Blackberry)
F: - USB drive (Blackberry)
G: - Login script mapped drive
[G: - USB drive - mounted but not visible in Explorer or command prompt]
J: - Login script mapped drive

I then have to go into Disk Management, find the new USB drive that's mounted to G: and re-assign it to another letter eg Z:, once this is done Auto-Play detects it and throws up its normal dialog, and its browseable in Explorer.

While this is OK to do if you only use one or two USB drives and have admin access to your PC with your login account, its a total pain in the proverbial if you regularly use a whole load of different USB devices, and corporate policy means you have one account for your normal login (that only has User access to workstations), but have to use a different account for any privileged action.

I realize that one possible reason for this is the difference between hardware which is mounted and assigned drive letters at the systen level, and mapped drives which are done at the user level. For USB devices that are already plugged in before login, then obviously they're mounted before Windows knows what network drives may be mapped. However if you plug the USB devices in after you're fully logged in and have drives mapped then Windows must know which letters are available?

share|improve this question
    
It’s because network drives are per-user and the kernel knows nothing about them. –  kinokijuf Dec 17 '11 at 12:44
add comment

4 Answers

up vote 1 down vote accepted

For this kind of problem, USB Drive Letter Management (USBDLM) makes wonders. You can allocate drive letters to USB drives, make sure it does not interfere with network drives, ...

From their Getting Started section:

When a removable drive (USB flash drive, flash card reader, portable hard drive) is attached for the first time, Windows mounts it to the first available 'local' drive letter. If there is a network share on this letter, Windows XP will use it anyway for the new USB drive because since XP network shares are specific to the current user and not visible in the context of the system where the letter is assigned. The USB drive then appears to be invisible. This is fixed by SP3 in most situations. You can change the letter assignments in the Windows Disk Management Console with a lot of mouse clicks but you have to do it again for every new device. And, for USB devices that have no serial number (in violation of the USB standards) you have to do it too when you attach it to a different USB port. USBDLM can for newly attached USB drives

...

check if the letter is used by a network share of the currently logged on user and assign the next letter that is really available

share|improve this answer
    
Hmmm looks like it does do what I'm after, but I was hoping (perhaps naively) for a solution that didn't need third party software loaded. If it turns out there aren't any (and SP3 isn't an option at the moment) then I could end up looking further into USBDLM. –  GAThrawn Sep 9 '09 at 13:23
    
And it's expensive as hell –  NginUS Nov 10 '10 at 10:54
    
"USBDLM is Freeware for private and educational (schools, colleges, universities) use only." –  Snark Nov 16 '10 at 4:49
add comment

You can try the mountvol command:

mountvol g: /d
mountvol 

To get the right VolumeName:

mountvol h: \\?\Volume{blablabla}\
share|improve this answer
add comment

The Windows-native way to do this may be DISKPART. It works for me.

From the DISKPART> prompt use:

list volume

to identify the USB drive,

select volume {number}

to choose it then

assign letter={letter}

to set its drive letter.

share|improve this answer
add comment

It's a huge pain and I'm not quite sure why Microsoft didn't right some extra code to use the next available letter.

You might consider pestering your IT department to change the login script to map the network drive in the latter half of the alphabet instead of "G." Depending on the size of your operation and the extent of use of the network drive, that might be a huge undertaking.

share|improve this answer
    
This is an unintended byproduct of some security enhancements. As one of the guys in corporate IT its been an issue up until SP3 (where they finally fixed it... on most machines). Unless you're a small shop, pestering IT probably won't do much. There may be policy reasons, or other issues that prevented them from doing what you suggest, and pestering them will only frustrate you and them. –  AnonJr Sep 9 '09 at 15:14
    
Hence the last sentence in my answer. Pestering an IT department (such as the corporate IT department I run) will do just that - pester them. My suggestion was only intended to shed light on the other side of the solution -- the IT department has the power to make the change themselves, even if it might be a huge undertaking. –  Russ Warren Sep 9 '09 at 15:19
2  
I am part of the IT department, hence why I have access to be able to us Disk Management with an alternate login. Unfortunately this also means that I know that changing that particular drive mapping isn't practical. It's been assigned to departmental group drives now for getting on for 2 decades, and has crept into being hard-coded into all sorts of bespoke apps, personal Access DBs, Word macros, etc all over thousands of machines. Best practice is one thing, 15-20 years of real world use is another :( –  GAThrawn Sep 9 '09 at 16:40
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.