IIS: The process cannot access the file because it is being used by another process
November 11, 2010 1 Comment
When you want to browse web site hosted in IIS, you may get sometimes page not found error. If you try to start web site from IIS admin manager you may get this message such as The process cannot access the file because it is being used by another process.
For example, when I browse *.aspx page using http://localhost/test.aspx then it shows page not found error, and when try to start web site from IIS7 manager then it shows this message.
Why this is shown is because any other process listening to port 80, since http by default listen to port 80 it conflicts. So one of the ways to fix this is that
- Find Process ID that is using port 80
- Start -> Run -> cmd
- write command – netstat -ano
- Find the Process ID which is listening on port 80
- Open Task Manager and Select the Process
- View -> Select Columns -> Process ID
- Find the Process ID that listening port 80
- Kill the process listening on Port 80
- Restart IIS and Start Website
- That’s all