• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 207
  • Last Modified:

Tools to Give Apply NTFS permissions

Hi, I haved used Xcacls.vbs to apply NTFS permission on Cluster but somehow it screwed my Cluster and all the permission are lost.

I am looking for resource kit tool where in i can use that and give NTFS rights to 3000 users on their home directories and common directories.

Thanks
ram
0
moorthy_kulumani
Asked:
moorthy_kulumani
  • 2
1 Solution
 
Steve KnightIT ConsultancyCommented:
Standard cacls.exe will do it and subinacl.exe to take ownership for the user.  Something like this:

call setrights.cmd with a paramater which is the username.  You could write a loop to go down all directories and call this if your directory structure allows:

@echo off
REM Set Rights Script
REM Steve Knight

Set user=%1

if "%1"=="" goto error

:OK
echo Setup user, profile, and data directories with permissions for %user%
title Setup user data profile directories for %USER% %2
echo.

if exist \\server\users\%user% goto skip1
  echo Creating users directory
  md \\server\users\%user%
:skip1

echo.
echo This may take some while.  Please Wait...
echo.

echo Setting USERS directory permissions
echo Y|cacls \\server\users\%user% /e /t /g  domain\%user%:C > nul

echo Taking ownership of USERS area
subinacl /noverbose /subdirectories \\server\users\%user%\*.* /setowner=domain\%user%
subinacl /noverbose /file \\server\users\%user% /setowner=domain\%user%

goto end

:error

echo SETRIGHTS.  Steve Knight. Jan 2002.
echo.
echo Usage setrights username
echo
echo You typed: %0 %1 %2 %3
echo.
echo This sets permissions and ownership for domain user
echo.
echo Requires SUBINACL from Resource Kit
pause

:end
0
 
Steve KnightIT ConsultancyCommented:
Fine by me.
0

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now