I am trying to edit my hosts file and I cannot seem to save it. I open notepad (run as admin) and when I go to save it gives me the error: "please make sure the file isn't opened in another location." I then took a look at the processes and it's not running this file.

Any ideas?

  • Workaround: copy and paste host file to some other location say desktop and do edit and then replace the original file with the edited one. – Renju Chandran chingath Jun 26 '14 at 4:45

It's because the file is open. Boot into safe mode and try to edit it. In the worst case get a Linux Live USB, boot it and edit your file from it.

  • Where is it open, I show no process using this file? – user338772 Jun 26 '14 at 3:38
  • 1
    It doesn't have to be open by a process to be locked. The error information is inaccurate and displays that as an error. – arielnmz Jun 26 '14 at 3:40
  • 1
    True... well I found out where it was open, my antivirus system. – user338772 Jun 26 '14 at 3:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.