Tutorial :web.config locked by w3wp.exe



Question:

I've got a weird problem. It looks like if my IIS6 locked an application's web.config. If I try to edit it, Windows complains that the web.config is used by another process.

Using Process Explorer I can see that the file is owned by w3wp.exe. Removing the virtual directory and stopping the website wasn't useful at all.

Any idea (I cannot stop the whole server since a lot of sites are hosted in it)?

Thanks in advance


Solution:1

I would try stopping the application pool for the website that is accessing the web.config.


Solution:2

Best bet would be to rename the web config (maintianing the lock on that file) and recreating the file. I'm not sure what would lock the file, but the app pool recycle should have freed the lock.


Solution:3

I had this problem, stopping the application pool didn't help. I then tried launching my text edited as administrator, and then that allowed me to save the file. Unfortunately I don't know if I needed to stop the application pool or not in the end...


Solution:4

If you're using an x32 based system, you could try using Unlocker to 'unlock' the file, or possibly delete web.config and then recreate it. Failing that, you could kill the w3wp.exe worker process, which should automatically restart.


Note:If u also have question or solution just comment us below or mail us on toontricks1994@gmail.com
Previous
Next Post »