Link to home
Start Free TrialLog in
Avatar of Mike Miazga
Mike MiazgaFlag for United States of America

asked on

Map drive by username variable in Group Policy

I want to use group policy to map user drives specific to each user.  Such as:  username domainname\peteh needs to map to \\servername\peteh$

Is there a way to do this via group policy?
ASKER CERTIFIED SOLUTION
Avatar of arnold
arnold
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of Mike Miazga

ASKER

Variable is the username they log in as.  The mapped drive would be \\servername\username$

I tried the attached in GPP but it doesn't work.
usernamemapdrive.JPG
Also, how do you map based on group membership?  Like if in group HR, map \\servername\hr$?
groups are easy, goto common tab and item level targeting

you can do username there too, but I doubt you want a policy for each user.

also make your your user drive is running in their security context
You either create a GPO per mapped drive using the security filtering I.e GPO map drive A security filter members of groupa
GPO groupB shared drive security filter groupB

The other is to use a single logins vbscript/powershell script that has drive mapping a which includes verification of group membership as a condition.  There are examples of vbscript said, powershell and batch scripts tart conditionally map drives.

The script would either obe part of the GPO or the login script under the user's AD profile using netlogon  script.

are you mapping drive letters.

C:
D: DVD
E: he
F: management
Etc?
SOLUTION
Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial