https://technet.microsoft.com/en-us/library/ee790599.aspx
Web Server (IIS) Administration Cmdlets in Windows PowerShell
The Web Server Administration module for Windows PowerShell includes the Internet Information Services (IIS) cmdlets that let you manage the configuration and run-time data of IIS. It implements a namespace hierarchy containing Application Pools, Web sites, Web applications and virtual directories.
The IIS module implements one virtual drive named IIS. The root virtual folders are AppPools and Sites. Within the AppPools folder, run-time data, such as the currently running worker processes, application domains, and requests can be found. The Sites folder contains Web site folders, as well as applications and virtual directories.
By default, Windows PowerShell modules and snap-ins are not loaded in Windows PowerShell. To start Windows PowerShell so that all the Windows PowerShell modules and snap-ins are loaded automatically, right-click the Windows PowerShell icon in the taskbar, and then click Import all modules. In Windows Server 2008 R2, the Windows PowerShell icon is pinned to the taskbar by default. However, you must start Windows PowerShell one time to make the Import all modules task appear.
You can manually add the IIS Module to the instance of Windows PowerShell that you have opened by using the following command at the command prompt: C:\PS>add-pssnapin WebAdministration
.
IIS cmdlets
This section lists the IIS module for Windows PowerShell cmdlets in IIS 7.
To use the Windows PowerShell cmdlets for IIS, you must be a member of the IIS Administrators or Administrators group, or you must have been delegated the appropriate authority.
Cmdlet name | Description |
---|---|
Adds a collection element to an IIS configuration collection. |
|
Locks an IIS configuration section or element. |
|
Adds a property to an IIS configuration section. |
|
Creates a backup of an IIS configuration. |
|
Instructs the IIS configuration system to delay the commitment of changes. |
|
Removes configuration settings from the configuration location specified. |
|
Clears the Request Tracing configuration from the specified Web site. |
|
Converts an IIS virtual directory to an IIS Web application. |
|
Disables the specified IIS module. |
|
Disables Request Tracing for the site specified. |
|
Enables the specified IIS module. |
|
Enables Request Tracing for the site specified. |
|
Instructs the IIS configuration system to resume the commitment of changes. |
|
Gets the application domains in which the specified IIS worker process is running. |
|
Gets the Web applications associated with a specific site or with the name specified. |
|
Gets the run-time state of an IIS application pool. |
|
Gets the bindings on the specified IIS site. |
|
Gets the file system path of the Web.config file. |
|
Gets an IIS configuration element at the specified path. |
|
Gets a list of available IIS configuration backups. |
|
Gets the location of a specified configuration setting. |
|
Gets the lock status of the specified IIS configuration location. |
|
Gets an IIS configuration property at the specified path. |
|
Gets the physical path to the location of the specified IIS module. |
|
Gets the global modules configured in IIS. |
|
Gets IIS Request Handlers. |
|
Gets the run-time state of a site or an application pool. |
|
Gets the managed modules that are configured for a particular application. |
|
Gets the IIS requests that are currently being executed. |
|
Gets configuration information for an IIS Web site. |
|
Gets the state of an IIS Web site. |
|
Gets information about the URL associated with the specified Web site. |
|
Gets the list of virtual directories on the specified site. |
|
Creates a new IIS Web application. |
|
Creates a new IIS application pool. |
|
Adds a new Web site binding to an existing Web site. |
|
Create a new FTP 7 Site |
|
Creates a new IIS module. |
|
Creates a new IIS Request Handler configuration entry. |
|
Adds a new managed module to the IIS request pipeline. |
|
Creates a new IIS Web site. |
|
Creates a new IIS virtual directory. |
|
Removes an IIS Web application. |
|
Removes an IIS application pool. |
|
Removes a binding from an IIS Web site. |
|
Removes an existing IIS configuration backup. |
|
Removes an IIS configuration location. |
|
Removes a lock on configuration settings. |
|
Removes an IIS configuration property. |
|
Removes an IIS module. |
|
Removes and IIS Request Handler. |
|
Removes an IIS managed module. |
|
Removes an IIS Web site. |
|
Removes an IIS virtual directory. |
|
Renames a configuration location. |
|
Recycles an application pool. |
|
Restarts an application pool or a Web site. |
|
Restores an IIS configuration backup. |
|
Returns Web configuration objects. |
|
Changes a property of an IIS site binding. |
|
Sets the value of an IIS configuration element. |
|
Changes the value of an IIS configuration property. |
|
Sets configuration settings for an IIS module. |
|
Configures an IIS request handler. |
|
Configures an IIS managed module. |
|
Starts an application pool. |
|
Starts an application pool or a site. |
|
Starts an IIS Web site. |
|
Stops an application pool. |
|
Stops an application pool or a site. |
|
Stops an IIS Web site. |