{"id":112242,"date":"2020-02-11T22:16:32","date_gmt":"2020-02-11T14:16:32","guid":{"rendered":"http:\/\/4563.org\/?p=112242"},"modified":"2020-02-11T22:16:32","modified_gmt":"2020-02-11T14:16:32","slug":"linux-%ef%bc%88openwrt%ef%bc%89%e4%b8%8b%e5%a6%82%e4%bd%95%e5%ae%9e%e7%8e%b0-per-packet-%e6%a8%a1%e5%bc%8f%e7%9a%84%e9%93%be%e8%b7%af%e8%b4%9f%e8%bd%bd%e5%9d%87%e8%a1%a1%ef%bc%9f","status":"publish","type":"post","link":"http:\/\/4563.org\/?p=112242","title":{"rendered":"Linux \uff08OpenWRT\uff09\u4e0b\u5982\u4f55\u5b9e\u73b0 Per-Packet \u6a21\u5f0f\u7684\u94fe\u8def\u8d1f\u8f7d\u5747\u8861\uff1f"},"content":{"rendered":"<div>\n<div>\n<div>\n<h1>                  Linux \uff08OpenWRT\uff09\u4e0b\u5982\u4f55\u5b9e\u73b0 Per-Packet \u6a21\u5f0f\u7684\u94fe\u8def\u8d1f\u8f7d\u5747\u8861\uff1f               <\/h1>\n<p> <\/p>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : Archeb <\/span>  <span><i><\/i> 77<\/span> <\/div>\n<div> <\/div>\n<\/p><\/div>\n<\/p><\/div>\n<\/p><\/div>\n<div isfirst=\"1\"> <\/p>\n<p>\u80cc\u666f\u5b9e\u73b0\uff1a<\/p>\n<ul>\n<li>\u4f7f\u7528 SoftEther VPN \u901a\u8fc7\u4e0d\u540c\u7684\u4e24\u6761\u5bbd\u5e26 \u5efa\u7acb\u4e86\u4e24\u4e2a\u7ea7\u8054\u96a7\u9053<\/li>\n<li>\u4f7f\u7528\u865a\u62df tap \u6865\u63a5\u6a21\u5f0f\uff0c\u5728\u4e24\u4e2a\u8def\u7531\u5668\u4e0a\u5206\u522b\u521b\u5efa\u4e86\u4e24\u4e2a tap \u8bbe\u5907\uff08 tap_link1\u3001tap_link2 \uff09<\/li>\n<li>\u5df2\u7ecf\u786e\u8ba4\u4e24\u7aef\u4e24\u4e2a tap \u8bbe\u5907\u90fd\u662f\u53ef\u4ee5\u901a\u7684\uff08\u5206\u522b\u914d\u4e0a IP \u53ef\u4ee5\u4e92\u76f8 Ping \uff09<\/li>\n<\/ul>\n<p>\u76ee\u524d\u6211\u6240\u77e5\u9053\u5e76\u4e14\u5df2\u7ecf\u5c1d\u8bd5\u4e86\u7684\u90e8\u5206\u65b9\u6cd5\uff1a<\/p>\n<ol>\n<li>bond \u65e0\u6cd5\u7528\u5728 tap \u8bbe\u5907\u4e0a\uff08\u63d0\u793a operation not premitted \uff09<\/li>\n<li>teql \u4e0d\u901a \u4e0d\u6e05\u695a\u4e3a\u4ec0\u4e48 \u9700\u8981\u8fdb\u4e00\u6b65\u5c1d\u8bd5 \u4f46\u662f\u9650\u4e8e\u80fd\u529b\u6211\u6ca1\u80fd\u627e\u5230\u66f4\u591a\u7684\u53c2\u8003\u8d44\u6599\uff08\u6211\u80fd\u627e\u5230\u7684\u53ea\u6709 LARTC \u7684\u4e00\u7bc7\uff09<\/li>\n<li>\u76f4\u63a5\u8def\u7531\u8d1f\u8f7d\u5747\u8861\u8bbe\u7f6e\u591a\u4e2a nexthop\uff0c3.6 &lt; kernel &lt; 4.4 \u662f per-packet \u6a21\u5f0f\uff0c\u5927\u4e8e 4.4 \u5c31\u662f per-flow\uff0c\u76ee\u524d\u7684\u5185\u6838\u662f 4.14 \u6211\u9700\u8981 per-packet \u6a21\u5f0f \u53c8\u542c\u8bf4\u53ef\u4ee5\u7528 equalize \u6765\u6539\u53d8\u6a21\u5f0f\uff0c\u4f46\u53d1\u73b0 iproute2 \u5e76\u6ca1\u6709\u5b9e\u73b0 equalize flag \uff08\u8c37\u6b4c\u641c\u7d22\u7ed3\u679c\uff0c\u81ea\u5df1\u5c1d\u8bd5\u4e5f\u63d0\u793a\u6ca1\u6709\u8fd9\u4e2a\u9009\u9879\uff09\u3002<\/li>\n<li>iptables \u968f\u673a\u6253\u6807 + ip rule \u7b56\u7565\u8def\u7531\uff1a\u65e0\u6cd5\u5e72\u9884\u672c\u5730\u8fdb\u7a0b\u8def\u7531\u9009\u62e9\uff0c\u636e\u8bf4\u53ef\u4ee5\u8ba9\u4ed6\u5728 lo \u8d70\u4e00\u8d9f\u6765\u5e72\u9884<\/li>\n<li>teamd \u56e0\u4e3a openwrt \u4f3c\u4e4e\u6ca1\u6709\u76f4\u63a5\u80fd\u7528\u7684\u5305\u6682\u672a\u5c1d\u8bd5<\/li>\n<\/ol>\n<p>\u5e0c\u671b\u5927\u4f6c\u80fd\u7ed9\u51fa\u4e9b\u5efa\u8bae\uff0c\u8c22\u8c22\u3002<\/p>\n<\/p><\/div>\n<div> <b>\u5927\u4f6c\u6709\u8a71\u8aaa<\/b> (<span>3<\/span>)        <\/div>\n<div> <\/div>\n<\/p><\/div>\n<\/p><\/div>\n<ul>\n<li data-pid=\"255451\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : xivisi <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u6211\u7684 gentoo \u8f6f\u8def\u7531\u91c7\u7528 teamd \u5b9e\u73b0\u53cc\u4e07\u5146 \u805a\u5408\u6210\u4e3a 20G \u548c \u652f\u6301\u805a\u5408\u7684\u4e07\u5146\u4ea4\u6362\u673a\u4e92\u8054                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"255452\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : lqs <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u4e4b\u524d\u7528\u8fc7\u4e00\u4e2a\u5f88 low \u4f46\u80fd work \u7684\u65b9\u6cd5\uff1a\u5199\u4e2a\u811a\u672c\u6bcf 0.1 \u79d2\u5207\u6362\u4e00\u6b21\u8def\u7531                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"255453\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u4e3b<\/span> <span>\u8cc7\u6df1\u5927\u4f6c : Archeb <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             @lqs \u4ed6\u5de5\u4f5c\uff0c\u611f\u8c22\uff01<\/p>\n<p>\u4eca\u5929\u5c1d\u8bd5\u4e86\u8d70 lo+iptables \u6253\u6807\uff0c\u592a\u5751\u4eba\u4e86..<br \/>\u76f4\u63a5 0.1s \u5207\u6362\u8def\u7531 \u5b8c\u4e8b&#8230;                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li>\n","protected":false},"excerpt":{"rendered":"<p>Linux \uff08OpenWRT\uff09\u4e0b\u5982&hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[],"tags":[],"_links":{"self":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts\/112242"}],"collection":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=112242"}],"version-history":[{"count":0,"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts\/112242\/revisions"}],"wp:attachment":[{"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=112242"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=112242"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=112242"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}