• Status: Solved
  • Priority: High
  • Security: Public
  • Views: 83
  • Last Modified:

Error while running PowerShell command

When I try to run the following command within Power Shell on a Windows 10 Pro OS I get the following error message.

What do I need to do to fix this so I will be able to successfully run this PowerShell command?

PS C:\support> Get-ChildItem "C:\Users\dstroble\AppData\Local\Temp\" | Get-NTFSAccessInheritance

Get-NTFSAccessInheritance : The term 'Get-NTFSAccessInheritance' is not recognized as the name of a cmdlet, function,
script file, or operable program. Check the spelling of the name, or if a path was included, verify that the path is
correct and try again.
At line:1 char:57
+ ... m "C:\Users\dstroble\AppData\Local\Temp\" | Get-NTFSAccessInheritance
+                                                 ~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : ObjectNotFound: (Get-NTFSAccessInheritance:String) [], CommandNotFoundException
    + FullyQualifiedErrorId : CommandNotFoundException

PS C:\support>
0
IT Guy
Asked:
IT Guy
  • 2
3 Solutions
 
Travis MartinezSmoke JumperCommented:
Have you installed the module:

https://gallery.technet.microsoft.com/scriptcenter/1abd77a5-9c0b-4a2b-acef-90dbb2b84e85#content

"Get-Module -ListAvailable"

Imported using "Import-Module NTFSSecurity"
0
 
Bill PrewCommented:
I had trouble with that link but this one works for me...

PowerShell Gallery | NTFSSecurity 4.2.3


»bp
0
 
Shaun VermaakTechnical Specialist/DeveloperCommented:
With PowerShell 5 you can just run
Install-Module NTFSSecurity

Open in new window

2
 
Travis MartinezSmoke JumperCommented:
Nice one Shaun, I didn't think of that.
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Protect Your Employees from Wi-Fi Threats

As Wi-Fi growth and popularity continues to climb, not everyone understands the risks that come with connecting to public Wi-Fi or even offering Wi-Fi to employees, visitors and guests. Download the resource kit to make sure your safe wherever business takes you!

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