修复google的dns解析示例

查询dns的网站

https://whoer.to/

https://whoer.net/zh

右键这个修复google.bat
选择 以管理员身份运行

覆盖 C:\Windows\system32\drivers\etc\hosts (Y:是/N:否/A:全部)
输入y 回车

即可

本处理 可以修改,也可以恢复系统默认

hosts文件

# Copyright (c) 2017-2020, googlehosts members.
# https://github.com/googlehosts/hosts
# Last updated: 2020-06-19


# This work is licensed under a modified HOSTS License.
# https://github.com/googlehosts/hosts/raw/master/LICENSE


# Modified Hosts Start


# Localhost (DO NOT REMOVE) Start
127.0.0.1	localhost
# Localhost (DO NOT REMOVE) End



# Google Service:China Hongkong Start
172.217.5.139	accounts.google.com.hk

修复google.bat

@echo off
echo "请注意你的杀毒软件提示,一定要允许"
echo "谷歌DNS修复最新时间2021-11-9"
echo "解决谷歌登录游戏问题"
@echo  ########################################
if exist C:\Windows\system32\drivers\etc\hosts.bak\ (
@echo  上一次有备份过hosts
) else (
@xcopy C:\Windows\system32\drivers\etc\hosts C:\Windows\system32\drivers\etc\hosts.bak\ /d /c /i /y
)
@echo  ########################################
@echo  hosts文件备份完毕,开始修改hosts文件修复谷歌
@echo
@xcopy %~dp0\hosts C:\Windows\system32\drivers\etc\hosts /y
::echo 1.116.228.9 freebasic.cn >>C:\Windows\System32\drivers\etc\hosts
::echo 1.116.228.9 www.freebasic.cn >>C:\Windows\System32\drivers\etc\hosts
::netsh interface ipv4 set dnsservers name="freebasic.cn"  static  1.116.228.9 primary
echo   "hosts文件修改完成"
@ipconfig /flushdns
@echo   "刷新DNS完成"
 
echo  hosts文件修改完毕,按任意键恢复系统原始状态
echo  或者点击右上角直接关闭
@echo
@echo  ########################################
@pause > nul
@copy C:\Windows\System32\drivers\etc\hosts.bak\hosts C:\Windows\System32\drivers\etc\hosts /y
@ipconfig /flushdns
@echo
@echo off
echo  hosts文件恢复完毕,按任意键退出
@echo
@pause > nul
@exit
点赞

发表评论

电子邮件地址不会被公开。必填项已用 * 标注