Build brand IT Service Excellence
传真:010-63362930
地址:北京市朝阳区建国路88号SOHO现代城B座19层使用Dnsmasq这款软件来搭建dns服务器加快上网速度、屏蔽广告,在这里分享下常用的屏蔽hosts文件,可以屏蔽绝大部分网站的广告。
使用 sudo nano /etc/dnsmasq.conf 命令修改dnsmasq配置文件,添加代码:
addn-hosts=/etc/dnsmasq.hosts
然后使用 sudo nano /etc/dnsmasq.hosts 命令新建dnsmasq.hosts文件,将我分享的hosts文件添加进去,保存退出,然后重启Dnsmasq,再次刷新网页,就可以看到网页的广告已经没有了,屏蔽广告成功!
;version=201601162048
;Contributors=KwokTree.OrzFly.jason_jiang.Felix Hsu.linjimmy.ZephyR.atmouse.Ehosts.zhqjsh.JayXon
;Description=Smart.Clean.Useful.Safe. Hosts-files.
;Vision=Better Internet Experience and Thanks 4 Every1.
;Down=https://raw.githubusercontent.com/vokins/simpleu/master/hosts
@SmartDirect
#Localhost
127.0.0.1 localhost
::1 localhost
#Windows
127.0.0.1 localhost.localdomain
127.0.0.1 localhost.localdomain localhost
#Ubuntu
127.0.1.1 #Fill Your Ubuntu Pc name here
::1 localhost ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
ff02::3 ip6-allhosts
#MacOS
fe80::1%lo0 localhost
255.255.255.255 broadcasthost
127.0.0.1 iadctest.qwapi.com
127.0.0.1 advertising.apple.com
127.0.0.1 iphone-services.apple.com
127.0.0.1 iphonesubmissions.apple.com
#Flashget Accelerate
221.123.176.125 s5.flashget.com
221.123.176.136 cplog.flashget.com
@Mobile ADPlatform
#iOS
127.0.0.1 aoodoo.feng.com
127.0.0.1 ads.qadservice.com
127.0.0.1 adsrvmedia.adk2.com
127.0.0.1 adsrvmedia.adk2.net
127.0.0.1 extra.thebigboss.org
127.0.0.1 event-img.qwapi.com
127.0.0.1 adserver-live.yoc.mobi
127.0.0.1 admax.nexage.com
127.0.0.1 tongji.app111.com
127.0.0.1 wbw.cocounion.com
#iOS-Cydia
127.0.0.1 a.ad-sys.com
127.0.0.1 a.adorika.net
127.0.0.1 ads.glispa.com
127.0.0.1 api.jw97.com
127.0.0.1 c.gltrkk.net
127.0.0.1 cydia.a3tweaks.com
127.0.0.1 hastrk3.com
127.0.0.1 jw97.com
#iOS-TMZ
127.0.0.1 ads.geornmd.net
127.0.0.1 ads.rnmd.net
#MobPay
127.0.0.1 epay.keepc.com
127.0.0.1 api.mopay.com
127.0.0.1 mobile.yeepay.com
127.0.0.1 payload.moji002.com
127.0.0.1 mobilepay.unionpaysecure.com
127.0.0.1 payment.umpay.com
127.0.0.1 sdk.baopay.com
127.0.0.1 ipay.appchina.com
#000dn
127.0.0.1 kwflvcdn.000dn.com
127.0.0.1 kwcscdn.000dn.com
127.0.0.1 kwcdn.000dn.com
#001union
转载自科技爱好者博客
IT外包咨询热线:010-51295775