引言
當你在使用火狐或者Chrome浏覽器的HostAdmin插件時,會遇到說去擷取寫host檔案的權限的問題,下面我就将具體方法介紹一下。
Windows Vista/7
在Windows下啟動cmd,而且是要用管理者身份運作。
對于所有的使用者:
cacls %windir%/system32/drivers/etc/hosts /E /G Users:W
對于自定義的賬号:
cacls %windir%/system32/drivers/etc/hosts /E /G "User Account Name":W
Linux (Ubuntu Fedora ...)
sudo chmod og+w /etc/hosts
Mac OS X
sudo chmod og+w /etc/hosts