Get-WindowsOptionalFeature -Online Returns list of installed features
Get-Package - Returns list of installed programs/MSI - not features
So, D is correct.
Answer is D ( Get - Windows Optional Features )
Explanations:
First of all "DNS" is a feature not application / program .
Get - Windows Optional Features > Lists all of the installed features.
Get-Package > Lists all of installed programs / Software packages
References:
https://docs.microsoft.com/en-us/powershell/module/dism/get-windowsoptionalfeature?view=win10-ps
https://docs.microsoft.com/en-us/powershell/module/packagemanagement/get-package?view=powershell-7
Pardon.
I got confused, the correct answer is "B. Get-Package".
https://docs.microsoft.com/en-us/windows-server/get-started/deploy-nano-server#inventory-installed-packages
It's D guys! "The Get-WindowsOptionalFeature cmdlet gets information about all features (operating system features that include optional Windows foundation features) in the Windows Foundation Package or a specified package in the Windows image."
The correct answer is Get-Package, which will return installed package. Here is a Microsoft reference
https://docs.microsoft.com/en-us/powershell/module/packagemanagement/get-package?view=powershell-6
It is indeed Get-package
Quoted from the given website
"The Get-Package cmdlet returns a list of all software packages on the local computer that were installed with PackageManagement. You can run Get-Package on remote computers by running it as part of an Invoke-Command or Enter-PSSession command or script."
Dear Bonna, Get-package is use to list out installed packages(software) only & to list out installed roles & features we need to use Get-WondowsOptionalFeature command.
I have to say, I was wrong in my first comment. Raghvendra is correct.
https://docs.microsoft.com/en-us/powershell/module/dism/get-windowsoptionalfeature?view=win10-ps#examples
Wrong. Get-Package won't help you. On NanoServer you'll need Find-NanoServerPackage to look for DNS server role or Get-NanoServerPackage to just list all the roles and find DNS server role among them by looking at the list.
upvoted 2 times
...
Log in to ExamTopics
Sign in:
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
Aldrid
Highly Voted 5 years agoLeonSKanady
Highly Voted 4 years, 7 months agoguyl
Most Recent 4 years agoRogercampos
3 years, 11 months agoSebastian
4 years, 3 months agoSebastian
4 years, 3 months agoDanuda
4 years, 8 months agoxbGigi
5 years, 1 month agoriose01
5 years, 1 month agoRicardoRyuma
5 years, 2 months agoITGEEK
5 years, 3 months agoGordy
5 years, 3 months agoZaz11
5 years, 3 months agoITGEEK
5 years, 4 months agoraghvendra
5 years, 6 months ago[Removed]
5 years, 6 months agoRockClimber
5 years, 6 months agoraghvendra
5 years, 6 months agoRockClimber
5 years, 6 months agolbs
4 years, 8 months agoZel
5 years, 6 months ago