{"id":165,"date":"2018-07-29T08:39:31","date_gmt":"2018-07-29T00:39:31","guid":{"rendered":"https:\/\/pfsense.freeddns.org\/wp\/?p=165"},"modified":"2020-08-24T22:14:28","modified_gmt":"2020-08-24T14:14:28","slug":"pfsense-book%e4%b9%8bdns%e8%bd%ac%e5%8f%91","status":"publish","type":"post","link":"https:\/\/blog.pfchina.org\/?p=165","title":{"rendered":"pfSense book\u4e4bDNS\u8f6c\u53d1"},"content":{"rendered":"<p style=\"text-align: justify;\">pfSense\u4e2d\u7684DNS\u8f6c\u53d1\u5668\u662f\u4e00\u4e2a\u4f7f\u7528dnsmasq\u5b88\u62a4\u8fdb\u7a0b\u7684\u7f13\u5b58DNS\u89e3\u6790\u5668\u3002 \u5b83\u5728\u5f53\u524d\u7248\u672c\u4e2d\u88ab\u9ed8\u8ba4\u7981\u7528\uff0c\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0cDNS\u89e3\u6790\u5668\uff08<a href=\"http:\/\/unbound.net\/\" target=\"_self\" rel=\"noopener noreferrer\">unbound<\/a>\uff09\u5904\u4e8e\u6d3b\u52a8\u72b6\u6001\u3002 DNS\u8f6c\u53d1\u5668\u5c06\u5728\u4e4b\u524d\u5904\u4e8e\u6d3b\u52a8\u72b6\u6001\u7684\u65e7\u7cfb\u7edf\u6216\u5347\u7ea7\u7cfb\u7edf\u4e0a\u4fdd\u6301\u542f\u7528\u72b6\u6001\u3002<\/p>\n<p style=\"text-align: justify;\">\n<p style=\"text-align: justify;\">DNS\u8f6c\u53d1\u5668\u4f7f\u7528\u5728<strong>\u7cfb\u7edf&gt;\u5e38\u89c4\u8bbe\u7f6e<\/strong>\u4e2d\u914d\u7f6e\u7684DNS\u670d\u52a1\u5668\uff0c\u6216\u4f7f\u7528\u4eceISP\u81ea\u52a8\u83b7\u53d6\u7684\u7528\u4e8e\u52a8\u6001\u914d\u7f6e\u7684WAN\u63a5\u53e3\uff08DHCP\uff0cPPPoE\uff0cPPTP\uff09\u7684DNS\u670d\u52a1\u5668\u3002 \u5bf9\u4e8e\u9759\u6001IP\u5730\u5740\u5e7f\u57df\u7f51\u8fde\u63a5\uff0c\u5fc5\u987b\u5728<strong>\u7cfb\u7edf&gt;\u5e38\u89c4\u8bbe\u7f6e<\/strong>\u6216\u8bbe\u7f6e\u5411\u5bfc\u671f\u95f4\u8f93\u5165DNS\u670d\u52a1\u5668\u4ee5\u4f7fDNS\u8f6c\u53d1\u5668\u6b63\u5e38\u5de5\u4f5c\u3002 \u9759\u6001\u914d\u7f6e\u7684DNS\u670d\u52a1\u5668\u4e5f\u53ef\u7528\u4e8e\u52a8\u6001\u914d\u7f6e\u7684\u5e7f\u57df\u7f51\u63a5\u53e3\uff0c\u65b9\u6cd5\u662f\u53d6\u6d88\u9009\u4e2d\u5141\u8bb8DNS\u670d\u52a1\u5668\u5217\u8868\uff0c\u4ee5\u4fbf\u5728\u201c\u7cfb\u7edf&gt;\u5e38\u89c4\u8bbe\u7f6e\u201d\u9875\u9762\u4e0a\u7684\u5e7f\u57df\u7f51\u4e0a\u7684DHCP \/ PPP\u8986\u76d6\u3002<\/p>\n<p style=\"text-align: justify;\">\n<p style=\"text-align: justify;\">\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0cDNS\u8f6c\u53d1\u5668\u5c06\u7acb\u5373\u67e5\u8be2\u6240\u6709DNS\u670d\u52a1\u5668\uff0c\u5e76\u4e14\u53ea\u4f7f\u7528\u6536\u5230\u7684\u7b2c\u4e00\u4e2a\u54cd\u5e94\u5e76\u8fdb\u884c\u7f13\u5b58\u3002 \u4ece\u5ba2\u6237\u7684\u89d2\u5ea6\u6765\u770b\uff0c\u8fd9\u4f1a\u4f7fDNS\u670d\u52a1\u66f4\u52a0\u5feb\u901f\uff0c\u5e76\u4e14\u53ef\u4ee5\u5e2e\u52a9\u7f13\u89e3\u6e90\u81ea\u95f4\u6b47\u6027\u8f83\u6162\u6216\u5177\u6709\u9ad8\u5ef6\u8fdf\u7684DNS\u670d\u52a1\u5668\u7684\u95ee\u9898\uff0c\u7279\u522b\u662f\u5728\u591aWAN\u73af\u5883\u4e2d\u3002 \u901a\u8fc7\u987a\u5e8f\u6fc0\u6d3b\u67e5\u8be2DNS\u670d\u52a1\u5668\u9009\u9879\u53ef\u4ee5\u7981\u7528\u6b64\u884c\u4e3a\u3002<\/p>\n<h2 style=\"text-align: justify;\">DNS\u00a0\u8f6c\u53d1\u548c IPv6<\/h2>\n<p style=\"text-align: justify;\">DNS\u8f6c\u53d1\u5668\u4e0eIPv6\u5b8c\u5168\u517c\u5bb9\u3002\u5b83\u63a5\u53d7\u548c\u67e5\u8be2IPv6\uff0c\u652f\u6301AAAA\u8bb0\u5f55\uff0c\u5e76\u6ca1\u6709\u4efb\u4f55\u4e0eIPv6\u7684\u4efb\u4f55\u65b9\u9762\u548c\u5904\u7406DNS\u7684\u5df2\u77e5\u95ee\u9898\u3002<\/p>\n<h2 style=\"text-align: justify;\">DNS\u00a0\u8f6c\u53d1\u914d\u7f6e<\/h2>\n<p style=\"text-align: justify;\">\u914d\u7f6eDNS\u8f6c\u53d1\uff0c\u8bf7\u5bfc\u822a\u5230<strong>\u7cfb\u7edf\u670d\u52a1\u00a0&gt; DN<\/strong><strong>S\u8f6c\u53d1<\/strong><\/p>\n<p style=\"text-align: justify;\">\u5e38\u7528\u9009\u9879\u5982\u4e0b:<\/p>\n<p style=\"text-align: justify;\"><strong>\u542f\u7528<\/strong>:\u9009\u4e2d\u6b64\u6846\u5c06\u6253\u5f00DNS\u8f6c\u53d1\u5668\uff0c\u6216\u53d6\u6d88\u9009\u4e2d\u4ee5\u7981\u7528\u6b64\u529f\u80fd\u3002 DNS\u8f6c\u53d1\u5668\u548cDNS\u89e3\u6790\u5668\u4e0d\u80fd\u540c\u65f6\u5728\u540c\u4e00\u4e2a\u7aef\u53e3\u4e0a\u5904\u4e8e\u6d3b\u52a8\u72b6\u6001\uff0c\u56e0\u6b64\u5728\u5c1d\u8bd5\u542f\u7528DNS\u8f6c\u53d1\u5668\u4e4b\u524d\uff0c\u7981\u7528DNS\u89e3\u6790\u5668\u6216\u5c06\u4e00\u4e2a\u670d\u52a1\u6216\u53e6\u4e00\u4e2a\u670d\u52a1\u79fb\u52a8\u5230\u5176\u4ed6\u7aef\u53e3\u3002<\/p>\n<p style=\"text-align: justify;\">\n<p style=\"text-align: justify;\"><strong>DHCP\u6ce8\u518c<\/strong>:\u5904\u4e8e\u6d3b\u52a8\u72b6\u6001\u65f6\uff0c\u53ef\u4ee5\u4f7f\u7528DNS\u89e3\u6790DHCP\u5ba2\u6237\u7aef\u7684\u5185\u90e8\u673a\u5668\u540d\u79f0\u3002\u8fd9\u53ea\u9002\u7528\u4e8e\u5728DHCP\u8bf7\u6c42\u4e2d\u6307\u5b9a\u4e3b\u673a\u540d\u7684\u5ba2\u6237\u7aef\u3002\u7cfb\u7edf&gt;\u5e38\u89c4\u8bbe\u7f6e\u4e2d\u7684\u57df\u540d\u7528\u4f5c\u4e3b\u673a\u4e0a\u7684\u57df\u540d\u3002<\/p>\n<p style=\"text-align: justify;\">\n<p style=\"text-align: justify;\"><strong>\u9759\u6001DHCP<\/strong>:\u8fd9\u4e0eDNS\u8f6c\u53d1\u5668\u4e2d\u7684\u6ce8\u518cDHCP\u79df\u7ea6\u7684\u4f5c\u7528\u76f8\u540c\uff0c\u53ea\u4e0d\u8fc7\u5b83\u6ce8\u518c\u4e86DHCP\u9759\u6001\u6620\u5c04\u5730\u5740\u3002<\/p>\n<p style=\"text-align: justify;\">\n<p style=\"text-align: justify;\"><strong>\u9996\u9009DHCP<\/strong>:\u5f53\u4e00\u4e2aIP\u5730\u5740\u6709\u591a\u4e2a\u4e3b\u673a\u540d\u65f6\uff0c\u5982\u679c\u5176\u4e2d\u4e00\u4e2a\u4e3b\u673a\u540d\u5728\u4e3b\u673a\u8986\u76d6\u4e2d\uff0c\u5e76\u4e14\u7cfb\u7edf\u901a\u8fc7DHCP\u4f7f\u7528\u53e6\u4e00\u4e2a\u4e3b\u673a\u540d\uff0c\u5219\u6267\u884c\u53cd\u5411\u67e5\u627e\u53ef\u80fd\u4f1a\u4ea7\u751f\u610f\u5916\u7684\u7ed3\u679c\u3002 \u9009\u4e2d\u6b64\u9009\u9879\u5c06\u4f7fDHCP\u83b7\u5f97\u7684\u4e3b\u673a\u540d\u4f4d\u4e8e\u9632\u706b\u5899\u4e3b\u673a\u6587\u4ef6\u4e2d\u7684\u9759\u6001\u6620\u5c04\u4e4b\u4e0a\uff0c\u9996\u5148\u67e5\u8be2\u5b83\u4eec\u3002 \u8fd9\u53ea\u5f71\u54cd\u53cd\u5411\u67e5\u627e\uff08PTR\uff09\uff0c\u56e0\u4e3a\u5b83\u4eec\u53ea\u8fd4\u56de\u7b2c\u4e00\u4e2a\u7ed3\u679c\u800c\u4e0d\u662f\u591a\u4e2a\u3002 \u4f8b\u5982\uff0c\u8fd9\u5c06\u4ea7\u751flabserver01.example.com\uff08\u6d4b\u8bd5\u670d\u52a1\u5668\u7684DHCP\u83b7\u5f97\u7684IP\u5730\u5740\uff09\u7684\u7ed3\u679c\uff0c\u800c\u4e0d\u662ftestwww.example.com\u7684\u4e3b\u673a\u8986\u76d6\u540d\u79f0\uff0c\u5426\u5219\u5c06\u8fd4\u56de\u3002<\/p>\n<p style=\"text-align: justify;\">\n<p style=\"text-align: justify;\"><strong>\u6309\u987a\u5e8f\u67e5\u8be2DNS\u670d\u52a1\u5668<\/strong>:\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u9632\u706b\u5899\u540c\u65f6\u67e5\u8be2\u6240\u6709DNS\u670d\u52a1\u5668\u5e76\u4f7f\u7528\u6700\u5feb\u7684\u7ed3\u679c\u3002 \u8fd9\u5e76\u4e0d\u603b\u662f\u53ef\u53d6\u7684\uff0c\u7279\u522b\u662f\u5982\u679c\u6709\u4e00\u4e2a\u672c\u5730\u7684DNS\u670d\u52a1\u5668\u7684\u81ea\u5b9a\u4e49\u4e3b\u673a\u540d\u53ef\u4ee5\u7ed5\u8fc7\u4f7f\u7528\u66f4\u5feb\u7684\u516c\u5171DNS\u670d\u52a1\u5668\u3002 \u9009\u4e2d\u6b64\u9009\u9879\u540e\uff0c\u5c06\u6309\u987a\u5e8f\u4ece\u4e0a\u5230\u4e0b\u5bf9\u6bcf\u4e2aDNS\u670d\u52a1\u5668\u8fdb\u884c\u67e5\u8be2\uff0c\u5e76\u4e14\u5728\u8f6c\u5230\u5217\u8868\u4e2d\u7684\u4e0b\u4e00\u4e2aDNS\u670d\u52a1\u5668\u4e4b\u524d\uff0c\u9632\u706b\u5899\u4f1a\u7b49\u5f85\u8d85\u65f6\u3002<\/p>\n<p style=\"text-align: justify;\">\n<p style=\"text-align: justify;\"><strong>\u9700\u8981\u57df\u540d<\/strong>:\u9700\u8981\u5c06\u4e3b\u673a\u540d\u4e0a\u7684\u57df\u540d\u8f6c\u53d1\u7ed9\u4e0a\u6e38DNS\u670d\u52a1\u5668\u3002 \u4ecd\u7136\u4f1a\u6839\u636e\u4e3b\u673a\u8986\u76d6\u548cDHCP\u7ed3\u679c\u68c0\u67e5\u6ca1\u6709\u540d\u79f0\u7684\u4e3b\u673a\uff0c\u4f46\u4e0d\u4f1a\u9488\u5bf9\u9632\u706b\u5899\u4e0a\u914d\u7f6e\u7684\u540d\u79f0\u670d\u52a1\u5668\u67e5\u8be2\u4e3b\u673a\u3002 \u76f8\u53cd\uff0c\u5982\u679c\u4e00\u4e2a\u7b80\u77ed\u7684\u4e3b\u673a\u540d\u672c\u5730\u4e0d\u5b58\u5728\uff0cNXDOMAIN\u5c06\uff08\u201cNot Found\u201d\uff09\u7ed3\u679c\u8fd4\u56de\u7ed9\u5ba2\u6237\u7aef\u3002<\/p>\n<p style=\"text-align: justify;\">\n<p style=\"text-align: justify;\"><strong>\u4e0d\u8981\u8f6c\u53d1\u4e13\u7528\u7684\u53cd\u5411\u67e5\u627e<\/strong>:\u9009\u4e2d\u65f6\uff0c\u6b64\u9009\u9879\u53ef\u9632\u6b62dnsmasq\u4e3aRFC1918\u4e13\u7528IP\u5730\u5740\u5411\u4e0a\u6e38\u540d\u79f0\u670d\u52a1\u5668\u8fdb\u884c\u53cd\u5411DNS\uff08PTR\u8bb0\u5f55\uff09\u67e5\u627e\u3002 \u5b83\u4ecd\u7136\u4f1a\u8fd4\u56de\u6765\u81ea\u672c\u5730\u6761\u76ee\u7684\u7ed3\u679c\u3002 \u53ef\u4ee5\u4f7f\u7528\u53cd\u5411\u67e5\u627e\u533a\u57df\u7684\u57df\u8986\u76d6\u6761\u76ee\uff0c\u4f8b\u5982\uff0c1.168.192 .in-addr.arpa\uff0c\u4ee5\u4fbf\u5bf9\u7279\u5b9a\u5b50\u7f51\u7684\u67e5\u8be2\u4ecd\u5c06\u88ab\u53d1\u9001\u5230\u7279\u5b9a\u7684DNS\u670d\u52a1\u5668\u3002<\/p>\n<p style=\"text-align: justify;\">\n<p style=\"text-align: justify;\"><strong>\u4fa6\u542c\u7aef\u53e3<\/strong>:\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0cDNS\u8f6c\u53d1\u5668\u4fa6\u542cTCP\u548cUDP\u7aef\u53e353.\u8fd9\u5bf9\u4e8e\u4efb\u4f55DNS\u670d\u52a1\u5668\u90fd\u662f\u6b63\u5e38\u7684\uff0c\u56e0\u4e3a\u5b83\u662f\u7aef\u53e3\u5ba2\u6237\u7aef\u5c06\u5c1d\u8bd5\u4f7f\u7528\u7684\u7aef\u53e3\u3002 \u5728\u67d0\u4e9b\u60c5\u51b5\u4e0b\uff0c\u5c06DNS\u8f6c\u53d1\u5668\u79fb\u5230\u53e6\u4e00\u4e2a\u4fa6\u542c\u7aef\u53e3\uff08\u4f8b\u59825353\u621654\uff09\u662f\u53ef\u53d6\u7684\uff0c\u7136\u540e\u901a\u8fc7\u7aef\u53e3\u8f6c\u53d1\u53ef\u4ee5\u5c06\u7279\u5b9a\u7684\u67e5\u8be2\u8f6c\u53d1\u5230\u90a3\u91cc\u3002<\/p>\n<p style=\"text-align: justify;\">\n<p style=\"text-align: justify;\"><strong>\u63a5\u53e3<\/strong>:\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0cDNS\u8f6c\u53d1\u5668\u4fa6\u542c\u6bcf\u4e2a\u53ef\u7528\u7684\u63a5\u53e3\u548c\u6240\u6709\u53ef\u7528\u7684IPv4\u548cIPv6\u5730\u5740\u3002 \u63a5\u53e3\u63a7\u5236\u9650\u5236\u4e86DNS\u8f6c\u53d1\u5668\u63a5\u53d7\u548c\u56de\u7b54\u67e5\u8be2\u7684\u63a5\u53e3\u3002 \u9664\u9632\u706b\u5899\u89c4\u5219\u5916\uff0c\u8fd8\u53ef\u4ee5\u7528\u6765\u589e\u52a0\u5b89\u5168\u6027\u3002 \u5982\u679c\u9009\u62e9\u4e86\u7279\u5b9a\u7684\u63a5\u53e3\uff0c\u5219\u8be5\u63a5\u53e3\u4e0a\u7684IPv4\u548cIPv6\u5730\u5740\u5c06\u7528\u4e8e\u56de\u7b54\u67e5\u8be2\u3002 \u53d1\u9001\u5230\u9632\u706b\u5899\u4e0a\u7684\u5176\u4ed6IP\u5730\u5740\u7684\u67e5\u8be2\u5c06\u88ab\u9759\u9759\u5730\u4e22\u5f03\u3002<\/p>\n<p style=\"text-align: justify;\">\n<p style=\"text-align: justify;\"><strong>\u4e25\u683c\u7684\u63a5\u53e3\u7ed1\u5b9a<\/strong>:\u8bbe\u7f6e\u540e\uff0cDNS\u8f6c\u53d1\u5668\u5c06\u53ea\u7ed1\u5b9a\u5230\u5305\u542b\u5728\u63a5\u53e3\u63a7\u4ef6\u4e2d\u9009\u62e9\u7684IP\u5730\u5740\u7684\u63a5\u53e3\uff0c\u800c\u4e0d\u662f\u7ed1\u5b9a\u5230\u6240\u6709\u63a5\u53e3\u5e76\u4e22\u5f03\u5bf9\u5176\u4ed6\u5730\u5740\u7684\u67e5\u8be2\u3002 \u8fd9\u53ef\u4ee5\u7c7b\u4f3c\u4e8e\u4fa6\u542c\u7aef\u53e3\u4f7f\u7528\uff0c\u4ee5\u63a7\u5236\u670d\u52a1\u7ed1\u5b9a\u7684\u65b9\u5f0f\uff0c\u4ee5\u4fbf\u5b83\u53ef\u4ee5\u4e0e\u5176\u4ed6\u5177\u6709\u7c7b\u4f3c\u9009\u9879\u7684DNS\u670d\u52a1\u5171\u5b58\u3002<\/p>\n<table class=\"docutils field-list\">\n<colgroup>\n<col class=\"field-name\" \/>\n<col class=\"field-body\" \/><\/colgroup>\n<tbody valign=\"top\">\n<tr class=\"field-even field firstRow\">\n<td><\/td>\n<td class=\"field-body\">\n<p class=\"first admonition-title\">\u6ce8\u610f<\/p>\n<p class=\"last\">\u5728\u5f53\u524d\u7248\u672c\u7684DNS\u8f6c\u53d1\u5668\u5b88\u62a4\u8fdb\u7a0bdnsmasq\u4e2d\uff0c\u6b64\u9009\u9879\u4e0eIPv6\u4e0d\u517c\u5bb9\u3002\u5982\u679c\u9009\u4e2d\u6b64\u9879\uff0c\u5219dnsmasq\u8fdb\u7a0b\u5c06\u4e0d\u4f1a\u7ed1\u5b9a\u5230\u4efb\u4f55IPv6\u5730\u5740\u3002<\/p>\n<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<h3 style=\"text-align: justify;\"><\/h3>\n<h3 style=\"text-align: justify;\">\u9ad8\u7ea7\u9009\u9879<\/h3>\n<p style=\"text-align: justify;\">\u5728GUI\u4e2d\u4e0d\u53ef\u914d\u7f6e\u7684\u81ea\u5b9a\u4e49dnsmasq\u914d\u7f6e\u53c2\u6570\u53ef\u4ee5\u653e\u7f6e\u5728\u9ad8\u7ea7\u9009\u9879\u4e2d\u3002 \u4f8b\u5982\uff0c\u8981\u4e3aDNS\u8bb0\u5f55\u8bbe\u7f6e\u8f83\u4f4e\u7684TTL\uff0c\u8bf7\u8f93\u5165max-ttl=30\u3002 \u6216\u8005\u5236\u4f5c\u901a\u914d\u7b26DNS\u8bb0\u5f55\uff0c\u901a\u8fc7\u6307\u5b9aaddress=\/lab.example.com\/192.2.5.6\u5c06.lab.example.com\u89e3\u6790\u4e3a192.2.5.6\u3002<\/p>\n<p style=\"text-align: justify;\">\u7528\u7a7a\u683c\u6216\u6362\u884c\u7b26\u5206\u9694\u547d\u4ee4\u3002\u6709\u5173\u53ef\u80fd\u4f7f\u7528\u7684\u53c2\u6570\u7684\u66f4\u591a\u4fe1\u606f\uff0c\u8bf7\u53c2\u9605<a href=\"http:\/\/www.thekelleys.org.uk\/dnsmasq\/docs\/dnsmasq-man.html\" target=\"_self\" rel=\"noopener noreferrer\">dnsmasq\u6587\u6863<\/a>\u3002<\/p>\n<h3 style=\"text-align: justify;\">\u4e3b\u673a\u8986\u76d6<\/h3>\n<p style=\"text-align: justify;\">\u4e3b\u673a\u8986\u76d6\u6761\u76ee\u63d0\u4f9b\u4e86\u914d\u7f6e\u81ea\u5b9a\u4e49DNS\u6761\u76ee\u7684\u65b9\u6cd5\u3002\u8be5\u914d\u7f6e\u4e0eDNS\u89e3\u6790\u5668\u4e2d\u7684\u4e3b\u673a\u8986\u76d6\u76f8\u540c\u3002<\/p>\n<h3 style=\"text-align: justify;\">\u57df\u8986\u76d6<\/h3>\n<p style=\"text-align: justify;\">\u57df\u8986\u76d6\u914d\u7f6e\u5907\u7528DNS\u670d\u52a1\u5668\u7528\u4e8e\u89e3\u6790\u7279\u5b9a\u7684\u57df\u3002\u8be5\u914d\u7f6e\u4e0eDNS\u89e3\u6790\u5668\u4e2d\u7684\u57df\u8986\u76d6\u76f8\u540c\uff0c\u53ea\u662f\u7565\u6709\u4e0d\u540c:<\/p>\n<p style=\"text-align: justify;\"><strong>\u57df<\/strong>: \u57df\u5b57\u6bb5\u8bbe\u7f6e\u5c06\u4f7f\u7528\u6b64\u6761\u76ee\u89e3\u6790\u7684\u57df\u540d\u3002 \u8fd9\u4e0d\u4e00\u5b9a\u662f\u4e00\u4e2a\u6709\u6548\u7684TLD\uff0c\u5b83\u53ef\u4ee5\u662f\u4efb\u4f55\u4e1c\u897f\uff08\u4f8b\u5982local, test, lab\uff09\uff0c\u6216\u8005\u5b83\u53ef\u4ee5\u662f\u4e00\u4e2a\u771f\u6b63\u7684\u57df\u540d\uff08example.com\uff09\u3002<\/p>\n<p style=\"text-align: justify;\">\n<p style=\"text-align: justify;\"><strong>IP\u5730\u5740<\/strong>: \u8be5\u5b57\u6bb5\u53ef\u4ee5\u4ee5\u4e09\u79cd\u65b9\u5f0f\u4e4b\u4e00\u4f7f\u7528\u3002 \u9996\u5148\uff0c\u5b83\u53ef\u4ee5\u7528\u6765\u6307\u5b9a\u53d1\u9001\u57df\u4e2d\u4e3b\u673a\u540d\u67e5\u8be2\u7684DNS\u670d\u52a1\u5668\u7684IP\u5730\u5740\u3002 \u5176\u6b21\uff0c\u53ef\u4ee5\u901a\u8fc7\u8f93\u5165\uff03\u6765\u8986\u76d6\u53e6\u4e00\u4e2a\u6761\u76ee\u3002 \u4f8b\u5982\uff0c\u8981\u5c06example.com\u8f6c\u53d1\u5230192.2.66.2\uff0c\u4f46\u5c06lab.example.com\u8f6c\u53d1\u5230\u6807\u51c6\u540d\u79f0\u670d\u52a1\u5668\uff0c\u8bf7\u5728\u6b64\u5b57\u6bb5\u4e2d\u8f93\u5165\uff03\u3002 \u7b2c\u4e09\uff0c\u901a\u8fc7\u8f93\u5165\uff01\u53ef\u4ee5\u9632\u6b62\u975e\u672c\u5730\u67e5\u627e\u3002 \u5982\u679cwww.example.org\u548cmail.example.org\u5b58\u5728\u4e3b\u673a\u8986\u76d6\u6761\u76ee\uff0c\u4f46\u4e0d\u80fd\u5c06example.org\u4e0b\u4e3b\u673a\u7684\u5176\u4ed6\u67e5\u627e\u8f6c\u53d1\u5230\u8fdc\u7a0bDNS\u670d\u52a1\u5668\uff0c\u8bf7\u8f93\u5165\uff01 \u5728\u8fd9\u4e2a\u9886\u57df\u91cc\u3002<\/p>\n<p style=\"text-align: justify;\">\n<p style=\"text-align: justify;\"><strong>\u6e90IP<\/strong>: \u8be5\u5b57\u6bb5\u662f\u53ef\u9009\u7684\uff0c\u4e3b\u8981\u7528\u4e8e\u901a\u8fc7***\u8054\u7cfbDNS\u670d\u52a1\u5668\u3002 \u901a\u5e38\u53ea\u6709\u7279\u5b9a\u7684\u672c\u5730IP\u5730\u5740\u80fd\u591f\u7a7f\u8d8a***\uff0c\u8fd9\u4e2a\u5b57\u6bb5\u6307\u5b9a\u9632\u706b\u5899\u4e0a\u7684\u54ea\u4e2aIP\u5730\u5740\u88ab\u7528\u6765\u53d1\u9001DNS\uff0c\u4ee5\u4fbf\u67e5\u8be2\u80fd\u591f\u6b63\u786e\u4f20\u9012\u3002<\/p>\n<p style=\"text-align: justify;\">\n<p style=\"text-align: justify;\"><strong>\u63cf\u8ff0<\/strong>: \u7528\u4e8e\u8bc6\u522b\u6216\u63d0\u4f9b\u6709\u5173\u6b64\u6761\u76ee\u7684\u66f4\u591a\u4fe1\u606f\u7684\u6587\u672c\u8bf4\u660e\u3002<\/p>\n<h2 style=\"text-align: justify;\">\nDNS\u00a0\u8f6c\u53d1\u548c\u591aWAN<\/h2>\n<p style=\"text-align: justify;\">DNS\u8f6c\u53d1\u5668\u5b8c\u5168\u517c\u5bb9\u591aWAN\u3002\u5728<strong>\u7cfb\u7edf&gt;\u5e38\u89c4\u8bbe\u7f6e<\/strong>\u4e0b\uff0c\u5728\u6bcf\u4e2aWAN\u7f51\u5173\u4e0a\u81f3\u5c11\u914d\u7f6e\u4e00\u4e2aDNS\u670d\u52a1\u5668\u3002<\/p>\n<h2 style=\"text-align: justify;\">DNS\u00a0\u8f6c\u53d1\u548cDNS\u91cd\u7ed1\u5b9a\u4fdd\u62a4<\/h2>\n<p style=\"text-align: justify;\">\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u542f\u7528DNS\u91cd\u65b0\u7ed1\u5b9a\u4fdd\u62a4\uff0c\u5e76\u62d2\u7edd\u79c1\u6709IP\u5730\u5740\u54cd\u5e94\u3002 \u8981\u5141\u8bb8\u6765\u81ea\u5df2\u77e5\u57df\u7684\u4e13\u7528IP\u5730\u5740\u54cd\u5e94\uff0c\u8bf7\u4f7f\u7528DNS\u8f6c\u53d1\u8bbe\u7f6e\u4e2d\u7684\u201c\u9ad8\u7ea7\u9009\u9879\u201d\u6846\u6765\u914d\u7f6e\u5141\u8bb8\u7684\u57df\uff0c\u5982\u4e0b\u6240\u793a:<\/p>\n<pre>rebind-domain-ok=\/example.com\/<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>pfSense\u4e2d\u7684DNS\u8f6c\u53d1\u5668\u662f\u4e00\u4e2a\u4f7f\u7528dnsmasq\u5b88\u62a4\u8fdb\u7a0b\u7684\u7f13\u5b58DNS\u89e3\u6790\u5668 &hellip; <a href=\"https:\/\/blog.pfchina.org\/?p=165\">\u7ee7\u7eed\u9605\u8bfb <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[28],"tags":[229],"class_list":["post-165","post","type-post","status-publish","format-standard","hentry","category-pfsense","tag-dns"],"_links":{"self":[{"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=\/wp\/v2\/posts\/165","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=165"}],"version-history":[{"count":0,"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=\/wp\/v2\/posts\/165\/revisions"}],"wp:attachment":[{"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=165"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=165"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.pfchina.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=165"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}