?
Solved

Remove folder access problem from parent dir -Urgent

Posted on 2013-11-27
5
Medium Priority
?
1,071 Views
Last Modified: 2014-02-03
$acl= get-acl F:\correct # correct folder permission. 
$files= get-childItem  F:\new\sub 1\sub2\sub 3|set-acl -aclobject $acl 

Open in new window

The code works only if unwanted permission exist only in Sub3 .I need exact same user permission as like  F:\correct for  F:\new\sub 1\sub2\sub . But if any un-needed permission have access to it previous folder,or parent folder, the un-wanted permissions doesn't get removed.

So,kindly help me in fixing this issue.

I need a sample help scripts where it check only required users & their corresponding persmission should exist .If it's finds any un wanted permission then it go to previous level folder and have to remove those permission.
And if the previous sub folder inherit the unwanted permission from parent folder then it should remove those from the parent folder as well.
0
Comment
[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
  • 2
5 Comments
 
LVL 40

Expert Comment

by:Subsun
ID: 39690186
So are you just trying to remove the inherited permission from the folder where you copy the permissions?
0
 
LVL 5

Author Comment

by:VIVEKANANDHAN_PERIASAMY
ID: 39691301
Yes i want to remove the inherited permission apart from set of domain groups.
0
 
LVL 40

Accepted Solution

by:
Subsun earned 2000 total points
ID: 39701639
Sorry I missed this alert.. Try..

$acl= get-acl F:\correct # correct folder permission. 
$acl.SetAccessRuleProtection(1,0)
$files= get-childItem  F:\new\sub 1\sub2\sub 3|set-acl -aclobject $acl 

Open in new window

0

Featured Post

Office 365 Training for Admins - 7 Day Trial

Learn how to provision tenants, synchronize on-premise Active Directory, implement Single Sign-On, customize Office deployment, and protect your organization with eDiscovery and DLP policies.  Only from Platform Scholar.

Question has a verified solution.

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

Background Information Recently I have fixed file server permission issues for one of my client. The client has 1800 users and one Windows Server 2008 R2 domain joined file server with 12 TB of data, 250+ shared folders and the folder structure i…
In previous parts of this Nano Server deployment series, we learned how to create, deploy and configure Nano Server as a Hyper-V host. In this part, we will look for a clustering option. We will create a Hyper-V cluster of 3 Nano Server host nodes w…
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…
In this video, Percona Director of Solution Engineering Jon Tobin discusses the function and features of Percona Server for MongoDB. How Percona can help Percona can help you determine if Percona Server for MongoDB is the right solution for …
Suggested Courses

765 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