If you are using IIS 7, the PeriodicRestart key. Add the following to your ApplicationHost.config file:
<add name="YourApplicationPool"> <recycling logEventOnRecycle="Schedule"> <periodicRestart> <schedule> <clear /> <add value="12:00:00" /> </schedule> </periodicRestart> </recycling> <processModel identityType="NetworkService" shutdownTimeLimit="00:00:30" startupTimeLimit="00:00:30" /> </add>
It will recycle your Application Pool every 12 hours.
If you are using IIS7, you can configure the Scheduled Task in business days by running the following command:
appcmd.exe recycle apppool "YourApplicationPool"
If you are using IIS6, I will follow the guide here .
source share