Sunday, October 2, 2011

arch安装pdnsd作为dns缓存服务器(本地)

找到pdnsd了。在/etc/pdnsd.conf的server段,这样写:
server {
        label= "mydns";
        ip = 208.67.220.220, 8.8.8.8;  # Put your ISP's DNS-server address(es) here.
        timeout=4;         # Server timeout; this may be much shorter
        interval=30m;      # Check every 30 minutes.
        purge_cache=off;   # Keep stale cache entries in case the ISP's
}
然后再在global段,改写下面的选项
    min_ttl=96h;
    max_ttl=1w;
这样就可以咯,缓存的dns记录最少会保留96个小时,强哦。

No comments: