查看应用程序池配置:
Get-WMIObject -class IISApplicationPoolSetting -namespace "rootmicrosoftiisv2" |where {$_.name -eq "W3SVC/APPPOOLS/api"}
Get-WmiObject -Namespace rootWebAdministration -ComputerName . -Class Server
gwmi -list * -namespace "rootmicrosoftiisv2"
=========================
Get-Module -ListAvailable
Import-Module WebAdministration 导入IIS管理模块
gci iis: