Just like disabling windows service, is there a way to disable app pool in IIS? This is just to prevent apppool restarting on server restart.
Asked
Active
Viewed 3,650 times
0
-
What does this have to do at all with [tag:c#]/[tag:web-services]/[tag:rest]? – Camilo Terevinto Oct 31 '17 at 11:36
2 Answers
0
In IIS Manager there is the "Start Automatically" setting in the (General) area in Advanced Settings.
Also see How to config application pool in IIS 7.5 automatically re-start when it was stopped? for an alternative way to do the same thing.

AUSteve
- 3,238
- 21
- 36
0
This C# example works for me
string appPoolPath = "IIS://localhost/W3SVC/AppPools/myapppool";
var appPool = new DirectoryEntry(appPoolPath);
appPool.Invoke("Start", null);
appPool.Invoke("Stop", null);
appPool.Invoke("Recycle", null);`

CobusCoetzee
- 46
- 5