Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Change Home Directory path for all AD Users

Posted on 2008-06-12
3
Medium Priority
?
1,579 Views
Last Modified: 2009-03-31
I currently have home directories which map "H:\" to "\\server01\firstname.lastname$" for all users in my Windows 2003 AD domain. Users are in multiple OU's. I need to change only the server name portion of the mapping for all the home drive mappings. Is there a VB Script i could use to lookup usernames from a text file and do this for all users in the text file? (Any other solution would also be welcome.)
0
Comment
Question by:LColdicott
3 Comments
 
LVL 6

Accepted Solution

by:
raptorjb007 earned 750 total points
ID: 21774550
Typically home directories are configured in the profile tab of the user account, something like "\\server01\users\%username%". The %username% is a an environment variable that is defined by the current user's account logon name.

You can map a drive in a script based on group policy to accomplish this as well as the %username% variable would be accessible in a batch environment.

Are you specifically looking to utilize a firstname.lastname directory naming structure for the user folders or would their username suffice(assuming their username inst already the firstname.lastname convention)?
0
 
LVL 2

Assisted Solution

by:kunalclk
kunalclk earned 750 total points
ID: 21774641
create a batch file and include this iline in that

net use  M: \\servername\myshare /y

this would map the drive M: as per the share mentioned.

Apply this batch policy using GPO. so no need to use the Profiles tab to map Home Directories. I hope this will help you.

Thanks
0
 

Author Comment

by:LColdicott
ID: 21775068
thanks for your answers guys. i must have submitted my question twice, accidentally. the question has already been answered satisfactorally.
0

Featured Post

Learn Veeam advantages over legacy backup

Every day, more and more legacy backup customers switch to Veeam. Technologies designed for the client-server era cannot restore any IT service running in the hybrid cloud within seconds. Learn top Veeam advantages over legacy backup and get Veeam for the price of your renewal

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

After seeing many questions for JRNL_WRAP_ERROR for replication failure, I thought it would be useful to write this article.
Transferring FSMO roles is done when an admin wants to split roles between certain Domain Controllers or the Domain Controller holding the Roles has been forcefully demoted using dcpromo / forceremoval
This tutorial will walk an individual through the process of transferring the five major, necessary Active Directory Roles, commonly referred to as the FSMO roles to another domain controller. Log onto the new domain controller with a user account t…
This video shows how to use Hyena, from SystemTools Software, to update 100 user accounts from an external text file. View in 1080p for best video quality.
Suggested Courses

879 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question