Solved

Creating a folder in a network location using GPO - Group Policy

Posted on 2013-12-04
9
547 Views
Last Modified: 2013-12-05
I am trying to create a folder on a mapped drive that all the users have. For example the drive is H:\ and the folder existing is "folder1". I want to create a folder in "folder1" for everyone so that it will read H:\folder1\folder2. Anyone know if this is possible by using group policy?
0
Comment
Question by:Wayside_Tech
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 4
  • 4
9 Comments
 
LVL 7

Expert Comment

by:George Simos
ID: 39696740
So you have shared a folder on a server which is named as folder1 right?
Let's say your server's name is "FileServer1" and the physical path of the shared folder named "Folder1" is D:\Folder1.
Have you shared folder1 and given the right permissions (sharing and ntfs ones) to the users you want?
After that have you created another folder named "Folder2" under "Folder1"?
If you have done the above steps then from a windows explorer you can type:
\\FileServer1\Folder1\Folder2
and you will have access to the folder.
If you want now to map the path \\FileServer1\Folder1\ to H:\ you can do this either via a logon script by using the command
"net use H:\ \\FileServer1\Folder1\"

Open in new window

and putting the script file on your netlogon folder of your domain (eg \\mydomain.local\netlogon\mapdrives.cmd) and put this path in the GPO.
Alternatively if you have Windows 7 you can use Group Policy Preferences to map the drive letter to your share.
Group Policy preferences can work in Windows XP too but you have to download the following update (http://www.microsoft.com/en-us/download/details.aspx?id=3628) but you have to manage the GPOs via a Windows Vista and later machine with the Group Policy Management Console installed via the Remote Server Administration Tools package.

What I don't understand it that you say "I want to create a folder in "folder1"" via GPO, you actually don't have to do that via GPO, you do it as described above!
0
 
LVL 14

Expert Comment

by:dmwynne
ID: 39696742
You can try using group policy preferences, configure a folder item:

http://technet.microsoft.com/en-us/library/cc730913.aspx

I can't test this at the moment to tell you it will work definitively.
0
 
LVL 1

Author Comment

by:Wayside_Tech
ID: 39696874
Gsimos,

I thank you for your quick response. The mapped drives have already been setup. Every user that log's in has this drive being mapped. It's a folder for each user mapped according to their usernames. Each user has their own folder that is named their username.
The issue is rather than me going to everyone's computer and create this folder within the mapped drive; I wanted to create this folder using Group Policy.
The reason I want to create the folder is because I want to redirect a file to the folder . I was looking for a way to automate the creation of the folder in GPO then use another group policy to redirect a file location. But, my issue is I can't get the folder to be created in the mapped drive when I test it. Which means I can't get the file to relocate to the network location (mapped drive).
0
Best Practices: Disaster Recovery Testing

Besides backup, any IT division should have a disaster recovery plan. You will find a few tips below relating to the development of such a plan and to what issues one should pay special attention in the course of backup planning.

 
LVL 7

Expert Comment

by:George Simos
ID: 39696925
Let me get this straight, your final target is to redirect users folders such as "Documents", "Videos", "Desktop" etc?
0
 
LVL 1

Author Comment

by:Wayside_Tech
ID: 39696948
Yes, I am trying to redirect the user's "Templates" folder.
0
 
LVL 7

Expert Comment

by:George Simos
ID: 39696950
This is a custom folder you have created I presume right?
0
 
LVL 1

Author Comment

by:Wayside_Tech
ID: 39696966
No, usually the folder is found at C:\Users\"username"\AppData\Roaming\Microsoft\Templates

I am just trying to have the templates go to the mapped drive instead of locally on the hard drive.
0
 
LVL 7

Accepted Solution

by:
George Simos earned 500 total points
ID: 39697039
Well you don't have to burden yourself a lot with that, especially you don't have to map it on any drive letter, the solution for you is the enabling of roaming user profiles, by doing that the %AppData%\Roaming folders of the users are moved to the network location you designate and a local cached copy is kept and synchronised during logon/logoff (you may set up policies through GPOs to sync periodically also while logged in).

You can achieve that by creating a GPO and link it on the OU with the Users you want to have such profiles.
Then edit the GPO and go to the Section: User Configuration > Policies > Folder Redirection
Right Click on "AppData(Roaming) and click properties
At the Setting dropdown select "Basic - Redirect everyones folder to the same location
At "Target folder location" select "Create a folder for each user under the root path"
In the "Root Path" box type the UNC path for the server share you have created, let's say \\FileServer1\Folder1\
Now click on "Settings" tab and check that the boxes "Grant the user exclusive rights to AppData(Roaming)." and "Move the contents of AppData(Roaming) to the new location" are checked
The final step is to decide the Policy removal which by default does not redirects back the folder when the policy is removed or is out of scope, this is something you will decide better
Finally press Apply and OK and close the GP Editor.
Now what we have achieved? Every user's Appdata(Roaming) profile folder will be redirected to the shared folder above, users don't need to have direct access there because they have a cached copy on their PC(s) but they can go and work on any pc in the premises and have their roaming profile following them!
You must keep in mind that this needs a double logon/logoff to work.

I hope this helps you.
0
 
LVL 1

Author Closing Comment

by:Wayside_Tech
ID: 39698429
Very quick and consistent in answering us back! Thanks for the great suggestions and solutions.
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Determining the an SCCM package name from the Package ID
This article provides a convenient collection of links to Microsoft provided Security Patches for operating systems that have reached their End of Life support cycle. Included operating systems covered by this article are Windows XP,  Windows Server…
The viewer will learn how to successfully create a multiboot device using the SARDU utility on Windows 7. Start the SARDU utility: Change the image directory to wherever you store your ISOs, this will prevent you from having 2 copies of an ISO wit…
With the advent of Windows 10, Microsoft is pushing a Get Windows 10 icon into the notification area (system tray) of qualifying computers. There are many reasons for wanting to remove this icon. This two-part Experts Exchange video Micro Tutorial s…

728 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