Reputation: 11
I am trying to enable Windows features "MSMQ Server" and "MSMQ Server Core" using PowerShell with the below command:
Enable-WindowsOptionalFeature -Online -FeatureName 'MSMQ-Server' -All -NoRestart
But the above command enables only the "MSMQ Server" and not "MSMQ Server Core". I want a PowerShell command which enables both "MSMQ Server" and "MSMQ Server Core" feature. Any help on this will be highly appreciated.
Thanks, Mani Athreya S
Upvotes: 1
Views: 7420
Reputation: 983
You might want to add an -All
flag to Enable-WindowsOptionalFeature
. This installs the prerequisites of the specified feature.
Upvotes: 0
Reputation: 13537
If you want to enable all MSMQ features, you can run this command. For the record, I do not see a MSMS-Server-Core feature available in my up-to-date Server 2019 VM.
Get-WindowsOptionalFeature -FeatureName MSMQ* -Online |
Enable-WindowsOptionalFeature -Online -NoRestart -Verbose
Upvotes: 3