How to Clear the ASP.NET Temporary files in Windows
Abstract: the application start working again. Remove ASP.NET Temp Files in Windows To clear the temporary files do the following on both the Web Serverin the c
Sometimes you may notice a strange caching behavior by the applications running in IIS. Today I found that my ASP.NET application showed a blank page. It is hosted on Windows Server 2019 in Azure Platform. I tried multiple times to resolve the issue but did not get success.
After searching about the issue, I found a suggestion in Google search to remove all ASP.NET temporary files. Once I removed all the temporary files, the application start working again.
Remove ASP.NET Temp Files in WindowsTo clear the temporary files do the following on both the Web Server:
- Log in to the server and open IIS.
- Stop IIS service. Run 「iisreset /stop」 in the command prompt to stop the IIS service.
- Navigate to the below directories:
- 「C:\Windows\Microsoft.NET\Framework\v4.0.30319\Temporary ASP.NET Files\」
- 「C:\Windows\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP.NET Files\」
- Remove all files under both directoires.
- Start IIS service. Run 「iisreset /start」 in the command prompt to stop the IIS service.
Even you can remove the temporary file without stopping the IIS server. Hope this tutorial helps you to resolve the caching-related issue on your Windows server.