{"id":149,"date":"2014-05-21T15:37:28","date_gmt":"2014-05-21T07:37:28","guid":{"rendered":"http:\/\/its.juan.tw\/?p=149"},"modified":"2014-05-21T15:37:28","modified_gmt":"2014-05-21T07:37:28","slug":"dhcp-%e6%b4%be%e9%80%81-static-route-pfsense-2-1","status":"publish","type":"post","link":"https:\/\/its.juan.tw\/?p=149","title":{"rendered":"DHCP \u6d3e\u9001 static route &#8211; pfSense 2.1"},"content":{"rendered":"<p>\u6700\u8fd1\u5728\u7814\u7a76 pfSense<br \/>\n\u4e3b\u8981\u662f\u628a\u5b83\u63a5\u4e0a\u4e00\u689d\u5149\u4e16\u4ee3\u5206\u6d41<br \/>\n\u964d\u4f4e\u5be6\u9a57\u5ba4\u5167\u90e8 VPN \u7684 loading <\/p>\n<p>\u56e0\u70ba\u4e0d\u60f3, \u4e5f\u66ab\u6642\u6c92\u6b0a\u9650\u52d5\u5230 VPN \u7528\u7684\u90a3\u53f0 Fortinet \u7684\u8a2d\u5b9a<br \/>\n\u65bc\u662f\u5c31\u5728 pfSene \u4e0a\u7684 System > Routing \u7684\u90e8\u4efd\u52a0\u4e0a\u5e7e\u689d static routes<br \/>\n\u4e26\u5728 Firewall > Rules > LAN \u628a VPN \u5167\u7684 IPs \u5168\u90e8\u8a2d\u6210 pass<\/p>\n<p>\u4f46\u9047\u5230\u4e00\u500b\u5c0f\u72c0\u6cc1<br \/>\n\u5c31\u662f\u5916\u9ede\u6709\u5169\u53f0 AS\/400 \u90fd\u53ef\u4ee5\u9806\u5229\u9023\u4e0a<br \/>\n\u4f46\u6c92\u591a\u4e45\u5c31\u6703\u88ab\u8e22\u6389<\/p>\n<p>\u4e00\u5ea6\u5728\u61f7\u7591\u662f Idle Timeout \u9020\u6210\u7684<br \/>\n\u4f46\u67e5\u4e86 pfSense \u4e0a Firewall \u7684 Rules,<br \/>\n\u4e26\u6c92\u6709\u7279\u5225\u53bb\u8abf\u6574 Session \u7684 Timeout \u7684\u5730\u65b9<\/p>\n<p>\u5f8c\u4f86, \u8a66\u4e86\u4e00\u4e0b<br \/>\n\u5982\u679c\u76f4\u63a5\u5728 PC \u7aef\u5c31\u52a0\u4e86\u689d static route<br \/>\n\u628a\u5230\u5916\u9ede\u7684 default gateway \u6539\u6210 VPN \u7684 ip<br \/>\n\u9019\u500b\u554f\u984c\u5c31\u89e3\u6c7a\u4e86<br \/>\n<!--more--><\/p>\n<p>\u770b\u4f86, \u53ea\u80fd\u900f\u904e DHCP \u4f86\u4e1f static route<br \/>\n\u5728 PC \u7aef\u6293\u5230 IP \u6642\u5c31\u76f4\u63a5\u8abf\u6574 routing \u4e86 = =<\/p>\n<p>pfSense \u7684 DHCP \u8a2d\u5b9a\u8981\u52a0 static route<br \/>\n\u53ef\u4ee5\u4f7f\u7528 DHCP option 121 \u6216 249 \u4f86\u8655\u7406<br \/>\n\u4f46\u56e0\u70ba\u5fae\u8edf\u65e9\u671f\u7684\u4f5c\u696d\u7cfb\u7d71\u6703\u5ffd\u7565 option 121<br \/>\n\u9019\u5e7e\u5929\u53c8\u767c\u73fe Sony Xperia Sola \u66f4\u72e0,<br \/>\n\u9047\u5230 Option 121 \u5f8c\u5c31\u76f4\u63a5\u4e0d\u8655\u7406<\/p>\n<p>\u6240\u4ee5, \u53ea\u80fd\u7528 Option 249 \u4f86\u6307\u5b9a static route<\/p>\n<p>\u5728 pfSense \u7684 Services ->  DHCP Server \u8a2d\u5b9a\u4e0b\u65b9<br \/>\n\u53ef\u4ee5\u627e\u5230 Additional BOOTP\/DHCP Options <\/p>\n<p>Number \u7684\u90e8\u4efd\u8f38\u5165 249<br \/>\nType \u9078 String<br \/>\n\u5f8c\u65b9\u7684\u503c, \u5247\u8f38\u5165 16 \u9032\u5236\u7684\u6578\u503c..<\/p>\n<p><a href=\"http:\/\/its.juan.tw\/wp-content\/uploads\/2014\/05\/hpcstaticr.jpg\"><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/its.juan.tw\/wp-content\/uploads\/2014\/05\/hpcstaticr.jpg\" alt=\"hpcstaticr\" width=\"946\" height=\"520\" class=\"alignnone size-full wp-image-172\" srcset=\"https:\/\/its.juan.tw\/wp-content\/uploads\/2014\/05\/hpcstaticr.jpg 946w, https:\/\/its.juan.tw\/wp-content\/uploads\/2014\/05\/hpcstaticr-300x164.jpg 300w\" sizes=\"auto, (max-width: 946px) 100vw, 946px\" \/><\/a><\/p>\n<p>Option 249 \u7684\u5beb\u6cd5\u662f<br \/>\n<strong>Subnet mask + Destination + Router<\/strong><br \/>\n\u5176\u4e2d\u5982\u679c\u503c\u662f 0,\u5c31\u76f4\u63a5\u5ffd\u7565\u8df3\u904e<\/p>\n<p>\u8209\u4f8b\u4f86\u8aaa:<br \/>\n    Destination: 192.168.123.0 (Hex: C0:A8:7B:0)<br \/>\n    Router: 10.34.72.42 (Hex: 0A:22:48:2A)<br \/>\n    Subnet mask: 24 (Hex: 18)<\/p>\n<p>\u90a3\u4f60\u7684 Value \u6703\u662f 24.192.168.123.10.34.72.42 (\u6578\u503c\u662f0\u7684\u5c31\u5ffd\u7565)<br \/>\n\u4f46\u5fc5\u9808\u63db\u7b97\u6210 16 \u9032\u5236,<br \/>\n\u6240\u4ee5\u4f60\u5728 Value \u7684\u5730\u65b9\u5c31\u586b\u4e0a 18:C0:A8:7B:0A:22:48:2A<\/p>\n<p>\u5982\u679c\u4e00\u6b21\u8981\u8a2d\u5b9a\u591a\u7d44 static route<br \/>\n\u5beb\u6cd5\u5c31\u6703\u8b8a\u6210<\/p>\n<p><strong>Subnet mask + Destination + Router + Subnet mask + Destination + Router<\/strong> <\/p>\n<p>\u6536\u5de5<\/p>\n<div class=\"pvc_clear\"><\/div>\n<p id=\"pvc_stats_149\" class=\"pvc_stats all  \" data-element-id=\"149\" style=\"\"><i class=\"pvc-stats-icon medium\" aria-hidden=\"true\"><svg aria-hidden=\"true\" focusable=\"false\" data-prefix=\"far\" data-icon=\"chart-bar\" role=\"img\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 512 512\" class=\"svg-inline--fa fa-chart-bar fa-w-16 fa-2x\"><path fill=\"currentColor\" d=\"M396.8 352h22.4c6.4 0 12.8-6.4 12.8-12.8V108.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v230.4c0 6.4 6.4 12.8 12.8 12.8zm-192 0h22.4c6.4 0 12.8-6.4 12.8-12.8V140.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v198.4c0 6.4 6.4 12.8 12.8 12.8zm96 0h22.4c6.4 0 12.8-6.4 12.8-12.8V204.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v134.4c0 6.4 6.4 12.8 12.8 12.8zM496 400H48V80c0-8.84-7.16-16-16-16H16C7.16 64 0 71.16 0 80v336c0 17.67 14.33 32 32 32h464c8.84 0 16-7.16 16-16v-16c0-8.84-7.16-16-16-16zm-387.2-48h22.4c6.4 0 12.8-6.4 12.8-12.8v-70.4c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v70.4c0 6.4 6.4 12.8 12.8 12.8z\" class=\"\"><\/path><\/svg><\/i> <img loading=\"lazy\" decoding=\"async\" width=\"16\" height=\"16\" alt=\"Loading\" src=\"https:\/\/its.juan.tw\/wp-content\/plugins\/page-views-count\/ajax-loader-2x.gif\" border=0 \/><\/p>\n<div class=\"pvc_clear\"><\/div>\n","protected":false},"excerpt":{"rendered":"<p>\u6700\u8fd1\u5728\u7814\u7a76 pfSense \u4e3b\u8981\u662f\u628a\u5b83\u63a5\u4e0a\u4e00\u689d\u5149\u4e16\u4ee3\u5206\u6d41 \u964d\u4f4e\u5be6\u9a57\u5ba4\u5167\u90e8 VPN \u7684 loading \u56e0\u70ba\u4e0d\u60f3 [&hellip;]<\/p>\n<div class=\"pvc_clear\"><\/div>\n<p id=\"pvc_stats_149\" class=\"pvc_stats all  \" data-element-id=\"149\" style=\"\"><i class=\"pvc-stats-icon medium\" aria-hidden=\"true\"><svg aria-hidden=\"true\" focusable=\"false\" data-prefix=\"far\" data-icon=\"chart-bar\" role=\"img\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" viewBox=\"0 0 512 512\" class=\"svg-inline--fa fa-chart-bar fa-w-16 fa-2x\"><path fill=\"currentColor\" d=\"M396.8 352h22.4c6.4 0 12.8-6.4 12.8-12.8V108.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v230.4c0 6.4 6.4 12.8 12.8 12.8zm-192 0h22.4c6.4 0 12.8-6.4 12.8-12.8V140.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v198.4c0 6.4 6.4 12.8 12.8 12.8zm96 0h22.4c6.4 0 12.8-6.4 12.8-12.8V204.8c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v134.4c0 6.4 6.4 12.8 12.8 12.8zM496 400H48V80c0-8.84-7.16-16-16-16H16C7.16 64 0 71.16 0 80v336c0 17.67 14.33 32 32 32h464c8.84 0 16-7.16 16-16v-16c0-8.84-7.16-16-16-16zm-387.2-48h22.4c6.4 0 12.8-6.4 12.8-12.8v-70.4c0-6.4-6.4-12.8-12.8-12.8h-22.4c-6.4 0-12.8 6.4-12.8 12.8v70.4c0 6.4 6.4 12.8 12.8 12.8z\" class=\"\"><\/path><\/svg><\/i> <img loading=\"lazy\" decoding=\"async\" width=\"16\" height=\"16\" alt=\"Loading\" src=\"https:\/\/its.juan.tw\/wp-content\/plugins\/page-views-count\/ajax-loader-2x.gif\" border=0 \/><\/p>\n<div class=\"pvc_clear\"><\/div>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[26],"tags":[30,29,31],"class_list":["post-149","post","type-post","status-publish","format-standard","hentry","category-router","tag-dhcp-249","tag-pfsense","tag-static-route"],"_links":{"self":[{"href":"https:\/\/its.juan.tw\/index.php?rest_route=\/wp\/v2\/posts\/149","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/its.juan.tw\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/its.juan.tw\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/its.juan.tw\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/its.juan.tw\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=149"}],"version-history":[{"count":5,"href":"https:\/\/its.juan.tw\/index.php?rest_route=\/wp\/v2\/posts\/149\/revisions"}],"predecessor-version":[{"id":174,"href":"https:\/\/its.juan.tw\/index.php?rest_route=\/wp\/v2\/posts\/149\/revisions\/174"}],"wp:attachment":[{"href":"https:\/\/its.juan.tw\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=149"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/its.juan.tw\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=149"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/its.juan.tw\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=149"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}