|
楼主 |
发表于 2015-2-9 12:26
|
显示全部楼层
本帖最后由 dato 于 2015-2-9 12:33 编辑
这个世界真是太小了。。。。
目前这个方法的问题是依赖socks连接的稳定性,目前碰到alipay.com可能存在解析问题
现在整个pdnsd.conf是28325条,在家里路由全局翻,一个个人用用还是没问题的。
上传个己缩小的子网。目的尽量是简化通过域名方式进行配置,但是多多少还是不能那么完美,有时候还是得用到exclude
- global {
- par_queries=1;
- }
- server {
- label="isp";
- ip=xxx.xxx.xxx.xxx,xxx.xxx.xxx.xxx;
- port=53;
- timeout=10;
- proxy_only=on;
- purge_cache=off;
- reject=1.0.0.0/24,
- 223.255.254.0/23;
- reject_policy = fail; #negate; #fail;
- reject_recursively=off;
- /*
- exclude=.twitter.com,
- .facebook.com,
- .google.com,
- .googlevideo.com,
- .youtube.com;
- */
- }
- # The following section is most appropriate if you have a fixed connection to
- # the Internet and an ISP which provides good DNS servers.
- server {
- label= "myisp";
- ip = 127.0.0.1; # Put your ISP's DNS-server address(es) here.
- port=5353;
- proxy_only=on; # Do not query any name servers beside your ISP's.
- # This may be necessary if you are behind some
- # kind of firewall and cannot receive replies
- caching=off; # from outside name servers.
- timeout=6; # Server timeout; this may be much shorter
- # that the global timeout option.
- uptest=if; # Test if the network interface is active.
- interface=lo; # The name of the interface to check.
- interval=10m; # Check every 10 minutes.
- purge_cache=off; # Keep stale cache entries in case the ISP's
- # DNS servers go offline.
- # edns_query=yes; # Use EDNS for outgoing queries to allow UDP messages
- # larger than 512 bytes. May cause trouble with some
- # legacy systems.
- # exclude=.thepiratebay.org, # If your ISP censors certain names, you may
- # .thepiratebay.se, # want to exclude them here, and provide an
- # .piratebay.org, # alternative server section below that will
- # .piratebay.se; # successfully resolve the names.
- reject=1.0.1.0/24,
- 223.255.252.0/23;
- reject_policy = fail; #negate; #fail;
- reject_recursively=off;
- exclude=.alipay.com,
- .sohu.com,
- .qq.com,
- .taobao.com;
- }
复制代码
|
本帖子中包含更多资源
您需要 登录 才可以下载或查看,没有账号?立即注册
×
|