Saturday, May 5, 2018

windows 10 - Visual Studio made a process I can't kill



Yesterday I was debugging an application. I've stopped the program, modified it then I tried to run it and got this error message:



Error   1   error LNK1168: cannot open E:\DEVELOPMENT\Projects\Visual Studio 2013\GameEngine\bin\Debug\EngineCore.exe for writing   E:\DEVELOPMENT\Projects\Visual Studio 2013\GameEngine\EngineCore\LINK   EngineCore



I've opened the task manager and saw the process, so I've tried to kill it. I wasn't able to. Then I restarted the computer, but got the same error. I've tried deleting the file but I got a message that it's still in use. I've opened task manager again but I couldn't find the process. For a temporary solution I've switched to release mode as that seemed to work until now, when the same thing happened to the release mode process. I have no idea why this happened.



I have Windows 10 64 bit and Visual Studio 2013



Edit:



I've downloaded Process Explorer, found the process but I just can't kill it (error message: "Access denied")! If I restart the computer it's still there. I got it's PID and tried to force-kill it ( taskkill /pid 13684 /f ) but it didn't work either.



Edit2:




I've tried using a live CD. I deleted the exe file. I've quadruple-checked it. But when I booted into windows10, the file reappeared.



Then I've downloaded Unlocker, which couldn't delete the file, but after a restart I was able to delete it manually.


Answer



A reboot will generally fix things. If not, then the system may be loading the file in some way.



Cedrick 'Nitch' Collomb's Unlocker has been known to coerce Windows in allowing a file to be deleted/renamed/etc. when the file appears to be locked. It's an older utility. It's actually worked in a surprisingly high number of cases, although system instability (until the system is rebooted) could occur (and has been known to occur, in a very small number of cases). Despite being an older utility, it has historically been known to work wonders, so it may be worth a shot.



Otherwise, you might want to try deleting the file when your computer is not running a version of Windows that is installed to the "hard drive" (or "SSD" or whatever your "primary storage" is). Instead, boot off of a Live CD. That way, the Windows permissions (including locks for current in-use files) should not be an issue, and you should be able to rename/delete the file.



No comments:

Post a Comment

hard drive - Leaving bad sectors in unformatted partition?

Laptop was acting really weird, and copy and seek times were really slow, so I decided to scan the hard drive surface. I have a couple hundr...