How to restart IIS on all servers of farm from SharePoint Application Page - SharePoint Overflow most recent 30 from http://www.sharepointoverflow.com 2010-03-12T18:34:02Z http://www.sharepointoverflow.com/feeds/question/584 http://www.creativecommons.org/licenses/by-nc/2.5/rdf http://www.sharepointoverflow.com/questions/584/how-to-restart-iis-on-all-servers-of-farm-from-sharepoint-application-page How to restart IIS on all servers of farm from SharePoint Application Page hasankhan 2009-11-20T10:32:42Z 2009-11-20T11:09:23Z <p>SharePoint provides an option in Create New WebApplication page that says Restart IIS Automatically. This restarts IIS on all servers of the farm.</p> <p>What can I do to trigger this programmatically from my Application Page (ASP.NET)?</p> <p>Is there a timer job for this? Is there anything in the API? do I have to create "iisreset" process and pass it the name of servers?</p> http://www.sharepointoverflow.com/questions/584/how-to-restart-iis-on-all-servers-of-farm-from-sharepoint-application-page/585#585 Answer by Stuart Starrs - Starznet for How to restart IIS on all servers of farm from SharePoint Application Page Stuart Starrs - Starznet 2009-11-20T10:42:17Z 2009-11-20T10:42:17Z <p>Hi there</p> <p>When you create a new web application a timer job is created to run seperatly on ALL servers, this timer job will perform the IISReset - It uses remoting to call into IIS - <a href="http://msdn.microsoft.com/en-us/library/system.runtime.remoting.channels.ipc.ipcclientchannel.aspx" rel="nofollow">http://msdn.microsoft.com/en-us/library/system.runtime.remoting.channels.ipc.ipcclientchannel.aspx</a> - however I find these kind of tasks easier using WMI.</p> <p>If you wanted to replicate this exact functionality then a timer job that is set to run on all servers independantly will be sufficient, my first port of call would be to take a look at the SPWebApplicationProvisioningJobDefinition using Reflector, this will show you exactly how they do it :)</p> <p>Stuart</p>