Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

commend Get-WindowsFeature in Power Shell 5?

Tags:

powershell

When i type the command Get-WindowsFeature in PowerShell 5 it displays this error, and I don't know why!

Get-WindowsFeature: The term "Get-WindowsFeature" is not recognized as a cmdlet name,
function, script file or executable program. Check the spelling of the name, or if a path
access exists, verify that the path is correct and try again.
To the character Line: 1: 1
+ Get-WindowsFeature
+ ~~~~~~~~~~~~~~~~~~
     + CategoryInfo: ObjectNotFound: (Get-WindowsFeature: String) [], CommandNotFoundException
     + FullyQualifiedErrorId: CommandNotFoundException

enter image description here

like image 541
mohammed zine Avatar asked Oct 24 '25 00:10

mohammed zine


1 Answers

Get-WindowsFeature is not part of PowerShell 5, but of the Server Manager module, which is either not installed or loaded, because the error message clearly states, that the command you trying to execute is not available.

Use Import-Module ServerManager to import it, or Import-Module -ListAvailable to see if it's even installed.

like image 165
vrdse Avatar answered Oct 25 '25 19:10

vrdse



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!