{"id":458,"date":"2013-07-16T15:28:47","date_gmt":"2013-07-16T07:28:47","guid":{"rendered":"http:\/\/blog.marvelplanet.tk\/?p=458"},"modified":"2013-07-16T15:28:47","modified_gmt":"2013-07-16T07:28:47","slug":"vm%e4%b8%8a%e4%b8%8d%e4%ba%86%e7%bd%91%e7%9a%84%e4%b8%80%e4%b8%aa%e5%8e%9f%e5%9b%a0","status":"publish","type":"post","link":"https:\/\/marvelliu.space\/?p=458","title":{"rendered":"VM\u4e0a\u4e0d\u4e86\u7f51\u7684\u4e00\u4e2a\u539f\u56e0"},"content":{"rendered":"<p>Openstack\u4e2dVM\u4e0a\u4e0d\u4e86\u7f51\u6709\u5f88\u591a\u539f\u56e0\uff0c\u4eca\u5929\u9047\u5230\u4e00\u4e2a\uff0c\u5176\u5b9e\u4e4b\u524d\u4e5f\u9047\u5230\u8fc7\uff0c\u53ea\u662f\u4e0d\u719f\u4e86\u624d\u8c03\u8bd5\u4e86\u534a\u5929\uff0c\u60b2\u5267\u3002\u3002\u3002<\/p>\n<p>\u73b0\u8c61\uff1aVM\u8054\u7f51\u901f\u5ea6\u5f88\u6162\uff0c\u4f8b\u5982apt-get update\u80fd\u8fde\u4e0a\u4e3b\u673a\uff0c\u4f46\u662f\u534a\u5929\u4e0b\u8f7d\u4e0d\u4e86\u591a\u5c11\u4e1c\u897f<\/p>\n<p>\u8c03\u8bd5\uff1a\u56e0\u4e3aVM\u80fd\u4e0a\u7f51\uff0c\u6240\u4ee5\u5f00\u59cb\u4ee5\u4e3a\u662fquantum\u7684l3\u95ee\u9898\uff0c\u5728\u547d\u540d\u7a7a\u95f4\u4e0b\u67e5\u770biptables\u548croute\uff0c\u5747\u6ca1\u6709\u95ee\u9898\u3002\u3002<br \/>\nroot@controller:\/usr\/src\/nova# ip netns<br \/>\nqdhcp-eb2fc4cd-d656-4e64-adc2-001d3cfbcebd<br \/>\nqrouter-b4721d20-9d39-4d4d-9c37-f18ecb460d02<br \/>\nqdhcp-77a8d872-103a-4d8c-9f47-bc6ec34a2ff4<br \/>\nqdhcp-faacf658-dae9-4230-8fbc-7cde47c425b1<\/p>\n<p>\u7136\u540e\u7528\u6293\u5305\uff1a<br \/>\nip netns exec qrouter-b4721d20-9d39-4d4d-9c37-f18ecb460d02 tcpdump -i qg-29c30020-2e \uff08\u5916\u7f51\u7f51\u5361\uff09<br \/>\n15:20:00.465882 IP 192.168.19.131 > likho.canonical.com: ICMP 192.168.19.131 unreachable &#8211; need to frag (mtu 1454), length 556<br \/>\n15:20:02.046704 IP likho.canonical.com.http > 192.168.19.131.56147: Flags [.], seq 1:1449, ack 256, win 61, options [nop,nop,TS val 3517237056 ecr 105897], length 1448<br \/>\n15:20:02.046825 IP 192.168.19.131 > likho.canonical.com: ICMP 192.168.19.131 unreachable &#8211; need to frag (mtu 1454), length 556<br \/>\nip netns exec qrouter-b4721d20-9d39-4d4d-9c37-f18ecb460d02 tcpdump -i qr-cd728374-d8 \uff08\u5185\u7f51\u7f51\u5361\uff09<br \/>\n15:20:02.046763 IP likho.canonical.com.http > 10.0.0.4.56147: Flags [.], seq 1:1449, ack 256, win 61, options [nop,nop,TS val 3517237056 ecr 105897], length 1448<br \/>\n15:20:02.046800 IP 10.0.0.4 > likho.canonical.com: ICMP 10.0.0.4 unreachable &#8211; need to frag (mtu 1454), length 556<br \/>\n15:20:02.541472 IP sudice.canonical.com.http > 10.0.0.4.39679: Flags [.], seq 1:1449, ack 258, win 61, options [nop,nop,TS val 1537132828 ecr 105323], length 1448<br \/>\n15:20:02.541502 IP 10.0.0.4 > sudice.canonical.com: ICMP 10.0.0.4 unreachable &#8211; need to frag (mtu 1454), length 556<br \/>\n\u53d1\u73b0\u51fa\u73b0\u5f88\u591aunreachable\u7684\u95ee\u9898\uff0c\u5f00\u59cb\u4ee5\u4e3a\u662f\u5185\u7f51\u6ca1\u7ecf\u8fc7SNAT\u51fa\u53bb\uff0c\u540e\u6765\u624d\u53d1\u73b0\u9519\u8bef\u4fe1\u606f\u91cd\u70b9\u662fneed to frag<\/p>\n<p>\u539f\u56e0\u662fVM\u7684MTU\u592a\u5c0f\u4e86\uff0c\u9700\u8981\u8bbe\u7f6e\u4e00\u4e2a\u5927\u4e00\u4e9b\u7684\u503c\uff0c\u90a3\u4e48\u5904\u7406\u5c31\u5f88\u7b80\u5355\u4e86\uff0c\u76f4\u63a5\u5728VM\u4e2d\u8fd0\u884c\uff1a<br \/>\nifconfig eth0 mtu 1400<\/p>\n<p>DONE<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Openstack\u4e2dVM\u4e0a\u4e0d\u4e86\u7f51\u6709\u5f88\u591a\u539f\u56e0\uff0c\u4eca\u5929\u9047\u5230\u4e00\u4e2a\uff0c\u5176\u5b9e\u4e4b\u524d\u4e5f\u9047\u5230\u8fc7\uff0c\u53ea\u662f\u4e0d\u719f\u4e86\u624d\u8c03\u8bd5\u4e86\u534a\u5929\uff0c\u60b2\u5267\u3002\u3002\u3002 \u73b0\u8c61\uff1aVM\u8054\u7f51\u901f\u5ea6\u5f88\u6162\uff0c\u4f8b\u5982apt-get update\u80fd\u8fde\u4e0a\u4e3b\u673a\uff0c\u4f46\u662f\u534a\u5929\u4e0b\u8f7d\u4e0d\u4e86\u591a\u5c11\u4e1c\u897f \u8c03\u8bd5\uff1a\u56e0\u4e3aVM\u80fd\u4e0a\u7f51\uff0c\u6240\u4ee5\u5f00\u59cb\u4ee5\u4e3a\u662fquantum\u7684l3\u95ee\u9898\uff0c\u5728\u547d\u540d\u7a7a\u95f4\u4e0b\u67e5\u770biptables\u548croute\uff0c\u5747\u6ca1\u6709\u95ee\u9898\u3002\u3002 root@controller:\/usr\/src\/nova# ip netns qdhcp-eb2fc4cd-d656-4e64-adc2-001d3cfbcebd qrouter-b4721d20-9d39-4d4d-9c37-f18ecb460d02 qdhcp-77a8d872-103a-4d8c-9f47-bc6ec34a2ff4 qdhcp-faacf658-dae9-4230-8fbc-7cde47c425b1 \u7136\u540e\u7528\u6293\u5305\uff1a ip netns exec qrouter-b4721d20-9d39-4d4d-9c37-f18ecb460d02 tcpdump -i qg-29c30020-2e \uff08\u5916\u7f51\u7f51\u5361\uff09 15:20:00.465882 IP 192.168.19.131 > likho.canonical.com: ICMP 192.168.19.131 unreachable &#8211; need to frag (mtu 1454), length 556 15:20:02.046704 IP likho.canonical.com.http > 192.168.19.131.56147: Flags [.], seq 1:1449, ack 256, win 61, options [nop,nop,TS val 3517237056 ecr 105897], &hellip; <a href=\"https:\/\/marvelliu.space\/?p=458\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;VM\u4e0a\u4e0d\u4e86\u7f51\u7684\u4e00\u4e2a\u539f\u56e0&#8221;<\/span><\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[21],"tags":[29],"class_list":["post-458","post","type-post","status-publish","format-standard","hentry","category-tech","tag-openstack"],"_links":{"self":[{"href":"https:\/\/marvelliu.space\/index.php?rest_route=\/wp\/v2\/posts\/458","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/marvelliu.space\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/marvelliu.space\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/marvelliu.space\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/marvelliu.space\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=458"}],"version-history":[{"count":1,"href":"https:\/\/marvelliu.space\/index.php?rest_route=\/wp\/v2\/posts\/458\/revisions"}],"predecessor-version":[{"id":459,"href":"https:\/\/marvelliu.space\/index.php?rest_route=\/wp\/v2\/posts\/458\/revisions\/459"}],"wp:attachment":[{"href":"https:\/\/marvelliu.space\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=458"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/marvelliu.space\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=458"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/marvelliu.space\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=458"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}