New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unable to write to hosts file in Windows installer #535
Comments
Just to be sure: Does the installer continue or does it abort the installation? We've already received some reports that writing into the WorkaroundAdd |
The installer abort the installation. |
Patched in cryptomator-win commit 4f817ef. |
Adding 127.0.0.1 cryptomator-vault to the hosts file doesn't work for me. I'll test the patch if it is available for me. Could I download the pathed version anywhere? |
You have probably added a tab or multiple whitespaces between ip and hostname. The installer looks for that exact line. PS: We got confirmations that fixing the hosts file manually works. But we're still clueless, what other application blocks access to it in the first place. |
it works with tab now. The error still appear but I could do the next step and the installer finished. Thanks |
@overheadhunter I think Avira Antivirus (and most likely some other similar products) has a setting that protects the hosts file from being changed |
Hosts file protection is pretty common in AV products. I just hit this issue myself right now, attempting to update to the latest release (that is, cryptomator stated it couldn't update it - not that the installer aborted). I use Webroot AV myself. I turned off Webroot protection temporarily, and the install proceeded. You might want to include a notice/warning in the install to turn off AV temporarily for this reason. |
We wanted to updated the notification anyway. How about:
|
Actually - at least with Webroot - not even an admin-mode editor can modify the hosts file. It's pretty hardcore - only way to edit is to either turn off the whole application temporarily (easiest/fastest) or go into the settings and uncheck 'prevent any program from modifying the HOSTs file'. But then if you forget and leave it unchecked, it'll remain unprotected, whereas webroot will re-enable itself after several minutes, automatically. I think the notice as written might cause more trouble - people trying to edit the hosts file rather than disabling AV, and then getting frustrated at not being able to change it? Perhaps just a notice at the start recommending that AV be turned off while installer is running - with a reminder at the end to turn the AV back on. |
Recommending to disable AV doesn't make an installer seem very trustworthy. I'd rather explain what the installer is trying to accomplish. If they fail to write the file even with notepad in admin mode, the hint that their AV is interfering might help them sort out the problem without trusting an installer that could do virtually anything with no malware protection running. |
Sure - I certainly understand your concern. I agree that it's good to explain what specifically the installer is doing with the hosts file. Since this is an open source application, any 'monkey business' would be rapidly discovered. So users have the assurance of transparency in that regard. Over the years, I've installed maybe....four? commercial applications that recommended turning off AV during install. So it's uncommon, but it does happen. Unfortunately I can't recall the names of any of them! |
On my system I also failed in my usual approach - running Notepad as Administrator and then manually editing the hosts file. So I discovered the hosts file was set to read-only by my experiments with Spybot immunization; on some systems ignoring the read-only flag may help. |
I'm using Windows 10 Pro 1703 64Bit
I'm running Cryptomator in version: …
I try to install Version 1.3.0 in 64 and 32Bits.
Description
The install for both ends with an runtime error after choosing the path. The error message is:
Runtime Error (at 11:489):
Cannot create file c:\Windows\system32\drivers\etc\hosts.
I try to delete my current host file so that the install script could create a new hosts file. That doesn't work.
Log files are not generate at this time.
The text was updated successfully, but these errors were encountered: