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.

When a removable USB HDD is plugged into a Windows XP machine, can I make Windows XP share it automatically? The drive is moved around quite often, and it is a hassle having to 'reshare' it each time it is plugged in. I was looking at the mountvol command, which might do what I want, but I don't want to waste time and effort if there is an existing solution.

Currently I use

mountvol c:\extern \\?\Volume{ volume_id }

in a .bat file in the root of the drive, with c:\extern shared, but I'd like this to trigger whenever the drive is plugged in, without needing to enable AutoRun... unless AutoRun can be enable only for specific volumes?

share|improve this question

1 Answer 1

up vote 0 down vote accepted

You can put an autorun.inf in the root of the drive that calls a .bat that maps the drive via net share. This seems like the easiest solution.

share|improve this answer
    
What drive letter do I map to the share? The drive letter assigned by the OS changes if other storage devices are plugged in. Can you map via volume id instead? –  DrTwox Jul 12 '10 at 6:30

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.