Why Must Mapping Drives in Logon Scripts be So Obtuse?

Logon scripts have been around forever. We've been using them since the early days of Windows for setting up the user environment with mapped drives, environment variables, and all the other niceties that users need.' So, if they've been around for really that long, then why is a task like a simple mapped drive still so obtuse to set up?

One of the confusions probably lies in all the different options you can use to actually map one.' Most simple is just using the NET USE command to set share to drive letter.' But NET USE isn't terribly fancy.' You can't easily make decisions with it, such as mapping certain drives for certain people.' To do that, you need a full scripting language like VBScript or PowerShell.' Accomplishing this small task with either takes some scripting know-how and a willingness to screw it up once or twice before you get it right.

In this article, I'll give you some sample lines of code you can use to map drives with batch, VBScript, and PowerShell.' I'll even show you how to make some simple drive mapping decisions if VBScript is your scripting language of choice.' With those decisions, you can map a drive based on groups the user belongs to.' I'll even show you how GPPs can assist.' In my video, I actually show you how to use VBScript to map drives. But throughout this article keep thinking about where these native tools are missing the point:' Namely, that you want real control over who gets what mapped drives, when, and why.' You'll also have some thoughts about the actual drive letter, and how that assignment gets more complex as the number of mapped drives grows large.' In the end, I think you'll be curious about non-native solutions that aren't quite as obtuse in accomplishing this seemingly-simple task.

Did this info help you in deciding how to map drives in your logon scripts?


This post is locked
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ