0

Until a few days ago, I had any server I connect to frequently in my hosts file. They're now getting frequently wiped.

It would appear that a backup "hosts.bak" file is being created so not all is lost... This has only happenned recently, seems the hosts.bak file was originally created on the 29th and edited last today (30th). Both files have the same permissions and are owned by the SYSTEM user.

Is there any way I can stop Windows resetting my hosts file? It's rather irritating to have to keep copying a backup over the top.

Jamie Taylor
  • 1,401
  • 3
  • 18
  • 27
  • Windows isn't resetting your hosts files, it's something else doing it. Is the file set to Read-only? – Ƭᴇcʜιᴇ007 Jan 30 '17 at 21:59
  • 1
    Do you have some security software installed? For example, Bitdefender automatically makes it "safe": https://superuser.com/questions/1018133/windows-10-hosts-file-entries-been-commented-out?rq=1 – Hex Jan 30 '17 at 22:00
  • 1
    It could be a security product resetting it. How about running [Process Monitor](https://technet.microsoft.com/en-us/sysinternals/processmonitor.aspx) with a path filter for the host file and also choose to drop events not matching the filter to see which process is responsible for changing it and presumably making the backup. – HelpingHand Jan 30 '17 at 22:00
  • The fact something is create a hosts.bak indicates you have security software doing this. In any event, the more enteries in the hosts file, actually the slower your DNS lookups will be. Hosts file isn't meant to block sites, and while your using it for frequently used sites, the same rule applies. – Ramhound Jan 30 '17 at 22:00
  • I agree that it sounds likely that it's some 3rd party program, but nothing has changed with the system recently. File isn't read only. I've got process monitor running now to see what it'll dig up. Cheers all – Jamie Taylor Jan 30 '17 at 22:02
  • @Ramhound - The hosts I'm using them for have no domain name, they're IPs, I'll take the hit to DNS resolution over copying and pasting IPs :P – Jamie Taylor Jan 30 '17 at 22:03

0 Answers0