Run the grant against the large folder separately with success output suppressed and errors logged; /grant without :r adds to the user’s existing explicit permissions rather than replacing them.
Back up and apply the additive permission
Open Command Prompt as administrator. First save the existing ACLs so they can be restored if necessary:
mkdir C:\Temp 2>nul
icacls "C:\Folder\*" /save "C:\Temp\Folder-before.acl" /T /C
Then target only the large third folder:
icacls "C:\Folder\ThirdFolder" /grant "COMPUTER\User":RX /T /C /Q ^
2>"C:\Temp\ThirdFolder-errors.txt"
Replace COMPUTER\User with the account’s fully qualified name, such as DOMAIN\User.
-
/T visits every child file and directory, including items with inheritance disabled.
-
/C continues after file errors.
-
/Q suppresses a success message for every item. On a very large tree, console output can make the command appear stalled.
-
RX grants Read and Execute.
-
/grant adds to existing explicit permissions. Do not use /grant:r, because :r replaces that user’s existing explicit grants. Existing permissions for other users remain in place.^1^
Check whether the process is still consuming CPU or disk in Task Manager → Details → icacls.exe. Also inspect C:\Temp\ThirdFolder-errors.txt after completion.
Verify the result
Check the folder and one representative file below it:
icacls "C:\Folder\ThirdFolder"
icacls "C:\Folder\ThirdFolder\path\sample-file.ext"
Check the entire tree for malformed or noncanonical ACLs:
icacls "C:\Folder\ThirdFolder" /verify /T /C /Q ^
>"C:\Temp\ThirdFolder-verify.txt" 2>&1
/verify reports ACLs whose lengths do not agree with their access-control entry counts or whose entries are not canonical.^1^
If it stops at exactly the same location
Look for a junction or symbolic link at that point:
Get-ChildItem -LiteralPath 'C:\Folder\ThirdFolder' -Force -Recurse |
Where-Object { $_.Attributes -band [IO.FileAttributes]::ReparsePoint } |
Select-Object FullName, LinkType, Target
Symbolic links and junctions are implemented as reparse points and can redirect traversal to another location.^2^ Junctions may also reference another local volume.^3^
If a link points outside the intended tree, apply icacls separately to the normal subfolders rather than recursively traversing the parent. The /L option operates on a symbolic link itself instead of its destination.^1^
If access errors are logged
Administrative membership and Full Control do not necessarily establish ownership of every child object. Only if the log contains Access is denied, take ownership of the affected subtree and retry that subtree:
takeown /F "C:\Folder\ThirdFolder\AffectedPath" /A /R
icacls "C:\Folder\ThirdFolder\AffectedPath" /grant "COMPUTER\User":RX /T /C /Q
Taking ownership changes security metadata, so restrict this to paths that actually fail rather than the entire share. Recursive ownership and permission assignment are supported recovery actions for inaccessible trees.^4^
Roll back if needed
Restore the saved ACLs with:
icacls "C:\Folder" /restore "C:\Temp\Folder-before.acl" /C
/save stores DACLs for later use, and /restore reapplies those stored DACLs.^1^
The command changes NTFS permissions, not the share-level permissions configured under Properties → Sharing → Advanced Sharing → Permissions. Both layers affect access through the network share.^5^
References
- icacls
- Reparse points
- Hard links and junctions
- How Repair Files and Folders Security Properties No Longer Accessible - Microsoft Q&A
- Access management and control