Copy an IIS7 Application Pool

Mark Berry June 14, 2011

Today I needed to create a .NET v4.0 version of an existing application pool. The old app pool was installed by a vendor install and uses a custom identity that gives it access to the vendor’s application. I don’t know the password to the custom identity, so I couldn’t create a new app pool from scratch.

I wondered about copying and modifying .config files, but this thread has a more elegant solution:

  1. Start PowerShell
  2. import-module webadministration
  3. copy IIS:\AppPools\oldpool IIS:\AppPools\newpool –force

Voila! The new app pool is there, referencing the same identity. Change its other properties as needed, then assign your application to the new app pool.



1 Comment

  1. Aaron   |  February 15, 2012 at 8:44 am

    Great Tip. Note to anyone trying this, the app pool you are trying to copy must be stopped for this to work.

Leave a Reply





Notify me of followup comments via e-mail. You can also subscribe without commenting.