0 pts.
 Batch process to create and modify permission to shared home directories in windows 2000 server.
Hi, I'm a trainee Engineer who doesnt have much experience with win2k. I only have little experience in Winnt 4. We have been using Winnt 4 for some years now and decided that this year we will use a win2k server and that's when I came accross this problem. The problem is I cannot run batch process "cacls filename /E /G user:permission" on win2k server. Worked okay on Winnt 4 but not win2k server. I have a large number of users and corresponding home directories and therefore would like to use a batch process rather than creating each home directory individually. I have a logical drive which I would like to have those home directories in it, shared and permission granted to administrator and the user ONLY. Thank you in advance for your cooperation and help in this regard Kind Regards, William

Software/Hardware used:
ASKED: February 16, 2005  12:41 AM
UPDATED: February 17, 2005  7:12 PM

Answer Wiki:
Welcome to the world of Active Directory. A) If this is to be your domain controller, run a migration program to capture the current users and you can create their 'home' directories as part of the first login. B) Not the domain controller but a new server in the domain, therefore no active directory. You will need to brush up your scripting skills, there are some major chnages in syntax. C) Meat of the matter - when you create the folder (directory) where these 'user home directories' will be, set permissions for Admin=full, everybody=list,read, creator/owner=modify. Set advanced permissions so new folders 'inherit' from parent. Now you can script in your logon bat, an 'if not exist' clause to create the folder object. By separating the permissions from the creation you simplify the batch file. D) Good luck.
Last Wiki Answer Submitted:  February 16, 2005  7:04 am  by  Howard2nd   30 pts.
All Answer Wiki Contributors:  Howard2nd   30 pts.
To see all answers submitted to the Answer Wiki: View Answer History.


Discuss This Question:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _


 

What exactly is the error you are receiving? I have a script that creates a home directory, shares it, and sets the permissions using CACLS. The script takes one parameter, the username, which is used to create the directory name and set the permissions. We are using Active Directory and it works fine. Let me know if you want an example of the script.

 0 pts.

 

Sorry, my experience in on XP, but I think they may be similarly close. I can’t tell the exact problem from you description, but here is what I ran into:

When I tried automatic setting the permission via batch cacls I ran into a problem with it prompting you that the change you were making was correct. You needed to manually hit Y. I didn’t see that I needed to do this in batch, I had to run it “manually” to get the message.

I solve this by creating a text file with the letter Y in it (“echo Y > yes.txt”), then sending that to the CACLS command (“cacls ….

 0 pts.

 

You can also use the CPAU.exe utility to run programs under a specific user. DO a google search for it if you want to try it.

 0 pts.