Get-IisAppPool

Gets a Microsoft.Web.Administration.ApplicationPool object for an application pool.

Syntax

Get-IisAppPool [[-Name] <String>] [<CommonParameters>]

Description

The Get-IisAppPool function returns an IIS application pools as a Microsoft.Web.Administration.ApplicationPool object. Use the Name parameter to return the application pool. If that application pool isn't found, $null is returned.

Carbon adds a CommitChanges method on each object returned that you can use to save configuration changes.

Beginning in Carbon 2.0, Get-IisAppPool will return all application pools installed on the current computer.

Beginning with Carbon 2.0.1, this function is available only if IIS is installed.

Related Commands

Parameters

Name Type Description Required? Pipeline Input Default Value
Name String

The name of the application pool to return. If not supplied, all application pools are returned.

false false

Return Values

Microsoft.Web.Administration.ApplicationPool.

EXAMPLE 1

Get-IisAppPool

Demonstrates how to get all application pools.

EXAMPLE 2

Get-IisAppPool -Name 'Batcave'

Gets the Batcave application pool.

EXAMPLE 3

Get-IisAppPool -Name 'Missing!'

Returns null since, for purposes of this example, there is no Missing~ application pool.