What's the difference between IISAdministration and WebAdministration

1.3k Views Asked by At

Here's the docs for both modules:

And here's a couple articles detailing the release notes of IISAdministration

It seems that IISAdministration is the newer utility as of IIS 10.0

Questions

  1. Should IISAdministration be preferred over WebAdministration where possible?
  2. What are the major differences between the two?
1

There are 1 best solutions below

0
YurongDai On

Maybe this article can clarify your doubts: IIS PowerShell modules and OS versions

IISAdministration has one big advantage; the types returned by the commands are much more useful. While they are still XML wrappers, they are adorned with useful properties and methods that make the objects much more usable without relying on the commands:

If you’re using the old WebAdministration, you pretty much have to do everything with the PowerShell CmdLets or by embracing the XML. There’s no way to navigate from a site returned by Get-Website to its applications, as one simple example. The new module also works much better with PowerShell pipelining.