{"id":21392,"date":"2025-04-19T04:31:45","date_gmt":"2025-04-18T20:31:45","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/21392.html"},"modified":"2025-04-19T04:31:45","modified_gmt":"2025-04-18T20:31:45","slug":"%e3%80%90%e5%bc%b9%e6%80%a7%e8%ae%a1%e7%ae%97%e3%80%91%e5%bc%b9%e6%80%a7%e8%a3%b8%e9%87%91%e5%b1%9e%e6%9c%8d%e5%8a%a1%e5%99%a8%e5%92%8c%e7%a5%9e%e9%be%99%e8%99%9a%e6%8b%9f%e5%8c%96%ef%bc%88%e4%b8%89","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/21392.html","title":{"rendered":"\u3010\u5f39\u6027\u8ba1\u7b97\u3011\u5f39\u6027\u88f8\u91d1\u5c5e\u670d\u52a1\u5668\u548c\u795e\u9f99\u865a\u62df\u5316\uff08\u4e09\uff09\uff1a\u5f39\u6027\u88f8\u91d1\u5c5e\u6280\u672f"},"content":{"rendered":"<p>\u300a<font color=\"#e47542\">\u5f39\u6027\u88f8\u91d1\u5c5e\u670d\u52a1\u5668<\/font>\u300b\u7cfb\u5217&#xff0c;\u5171\u5305\u542b\u4ee5\u4e0b\u6587\u7ae0&#xff1a;<\/p>\n<ul>\n<li>\u5f39\u6027\u88f8\u91d1\u5c5e\u670d\u52a1\u5668\u548c\u795e\u9f99\u865a\u62df\u5316&#xff08;\u4e00&#xff09;&#xff1a;\u529f\u80fd\u7279\u70b9<\/li>\n<li>\u5f39\u6027\u88f8\u91d1\u5c5e\u670d\u52a1\u5668\u548c\u795e\u9f99\u865a\u62df\u5316&#xff08;\u4e8c&#xff09;&#xff1a;\u9002\u7528\u573a\u666f<\/li>\n<li>\u5f39\u6027\u88f8\u91d1\u5c5e\u670d\u52a1\u5668\u548c\u795e\u9f99\u865a\u62df\u5316&#xff08;\u4e09&#xff09;&#xff1a;\u5f39\u6027\u88f8\u91d1\u5c5e\u6280\u672f<\/li>\n<\/ul>\n<p>&#x1f60a; \u5982\u679c\u60a8\u89c9\u5f97\u8fd9\u7bc7\u6587\u7ae0\u6709\u7528 \u2714\ufe0f \u7684\u8bdd&#xff0c;\u8bf7\u7ed9\u535a\u4e3b\u4e00\u4e2a\u4e00\u952e\u4e09\u8fde &#x1f680;&#x1f680;&#x1f680; \u5427 &#xff08;\u70b9\u8d5e &#x1f9e1;\u3001\u5173\u6ce8 &#x1f49b;\u3001\u6536\u85cf &#x1f49a;&#xff09;&#xff01;&#xff01;&#xff01;\u60a8\u7684\u652f\u6301 &#x1f496;&#x1f496;&#x1f496; \u5c06\u6fc0\u52b1 &#x1f525; \u535a\u4e3b\u8f93\u51fa\u66f4\u591a\u4f18\u8d28\u5185\u5bb9&#xff01;&#xff01;&#xff01;<\/p>\n<\/p>\n<h4>\n<p>    \u5f39\u6027\u88f8\u91d1\u5c5e\u670d\u52a1\u5668\u548c\u795e\u9f99\u865a\u62df\u5316&#xff08;\u4e09&#xff09;&#xff1a;\u5f39\u6027\u88f8\u91d1\u5c5e\u6280\u672f<br \/>\n  <\/h4>\n<ul>\n<li>1.\u4f20\u7edf KVM \u865a\u62df\u5316\u7cfb\u7edf\u7684\u95ee\u9898<\/li>\n<li>\n<ul>\n<li>1.1 CPU \u8ba1\u7b97\u7279\u6027\u635f\u5931<\/li>\n<li>1.2 \u8d44\u6e90\u4e89\u62a2\u4e0d\u53ef\u907f\u514d<\/li>\n<li>1.3 I\/O \u6027\u80fd\u74f6\u9888<\/li>\n<\/ul>\n<\/li>\n<li>2.\u5f39\u6027\u88f8\u91d1\u5c5e\u6280\u672f\u5b9e\u73b0<\/li>\n<li>\n<ul>\n<li>2.1 VPC \u548c EBS \u4e91\u76d8\u63a5\u5165<\/li>\n<li>2.2 \u5b9e\u73b0\u5927\u91cf\u5f39\u6027\u7f51\u5361&#xff08;ENI&#xff09;\u548c EBS \u4e91\u76d8\u8bbe\u5907\u63a5\u5165<\/li>\n<\/ul>\n<\/li>\n<li>3.X-Dragon Hypervisor \u57fa\u4e8e\u795e\u9f99\u7684\u8f6f\u786c\u4e00\u4f53\u7684\u865a\u62df\u5316\u6280\u672f<\/li>\n<li>\n<ul>\n<li>3.1 \u81ea\u7814\u865a\u62df CPU \u8c03\u5ea6\u5668 \u2014\u2014 VOS<\/li>\n<li>3.2 \u5185\u5b58\u4f18\u5316&#xff1a;\u5185\u5b58\u5206\u914d\u5668 VMEM \u4e0e\u7528\u6237\u6001 QEMU \u5185\u5b58\u7626\u8eab<\/li>\n<li>3.3 \u865a\u62df\u5316\u8fd0\u884c\u52a0\u901f<\/li>\n<li>3.4 \u6781\u901f\u542f\u52a8<\/li>\n<li>3.5 \u7269\u7406\u673a CPU \u5168\u4f9b\u7ed9\u865a\u62df\u673a<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<h2>1.\u4f20\u7edf KVM \u865a\u62df\u5316\u7cfb\u7edf\u7684\u95ee\u9898<\/h2>\n<p>2003 \u5e74&#xff0c;Xen \u5728 SOSP \u53d1\u8868 Xen and the Art of Virtualization&#xff0c;\u62c9\u5f00\u4e86 x86 \u5e73\u53f0\u865a\u62df\u5316\u6280\u672f\u7684\u5927\u5e55\u30022006 \u5e74&#xff0c;AWS \u53d1\u5e03 EC2&#xff08;Elastic Compute Cloud&#xff09;&#xff0c;\u540c\u5e74\u53d1\u5e03 S3&#xff08;Simple Storage Service&#xff09;&#xff0c;\u62c9\u5f00\u4e86\u516c\u5171\u4e91\u670d\u52a1\u7684\u5927\u5e55\u3002EC2 \u7684\u6838\u5fc3\u6b63\u662f\u57fa\u4e8e Xen \u865a\u62df\u5316\u6280\u672f\u3002\u865a\u62df\u5316\u6280\u672f\u8d4b\u4e88\u4e86 EC2 \u6838\u5fc3\u4ea7\u54c1\u4ef7\u503c \u2014\u2014 <font color=\"#e47542\">\u5f39\u6027<\/font>&#xff0c;\u540c\u65f6\u865a\u62df\u5316\u6280\u672f\u7ed9\u7f51\u7edc\u865a\u62df\u5316\u3001\u5b58\u50a8\u865a\u62df\u5316&#xff0c;\u548c\u7ba1\u63a7\u7cfb\u7edf\u63d0\u4f9b\u4e86\u4e1a\u52a1\u90e8\u7f72\u70b9\u3002<\/p>\n<p>&#x1f680; SOSP&#xff08;Symposium on Operating Systems Principles&#xff0c;<font color=\"#e47542\">\u64cd\u4f5c\u7cfb\u7edf\u539f\u7406\u7814\u8ba8\u4f1a<\/font>&#xff09;&#xff1a;\u64cd\u4f5c\u7cfb\u7edf&#xff08;OS&#xff09;\u9886\u57df\u6709\u4e24\u4e2a\u56fd\u9645\u9876\u5c16\u4f1a\u8bae&#xff1a;SOSP \u548c OSDI&#xff0c;SOSP \u53ea\u5728\u5947\u6570\u5e74\u53ec\u5f00&#xff0c;OSDI \u53ea\u5728\u5076\u6570\u5e74\u53ec\u5f00\u3002<\/p>\n<p>\u7b2c\u4e00\u4ee3\u865a\u62df\u5316\u6280\u672f\u7684\u7279\u5f81\u662f&#xff1a;Xen \/ KVM &#043; \u8f6f\u4ef6 network vSwitch &#043; \u8f6f\u4ef6 storage initiator &#043; \u7ba1\u63a7\u7b49 All on Xeon\u3002\u8fd9\u4ee3\u6280\u672f\u7684\u75db\u70b9\u548c\u601d\u8003&#xff0c;\u5982\u4e0b\u56fe\u6240\u793a\u3002<\/p>\n<p>&#x1f680; <font color=\"#e47542\">\u8f6f\u4ef6\u7f51\u7edc vSwitch<\/font>&#xff08;\u865a\u62df\u4ea4\u6362\u673a&#xff09;\u662f\u4e00\u79cd\u5728\u865a\u62df\u5316\u73af\u5883\u4e2d\u8fd0\u884c\u7684\u8f6f\u4ef6\u4ea4\u6362\u673a&#xff0c;\u7528\u4e8e\u8fde\u63a5\u865a\u62df\u673a&#xff08;VM&#xff09;\u548c\u7269\u7406\u7f51\u7edc\u8bbe\u5907\u3002\u5b83\u6a21\u62df\u7269\u7406\u4ea4\u6362\u673a\u7684\u529f\u80fd&#xff0c;\u5141\u8bb8\u865a\u62df\u673a\u4e4b\u95f4\u4ee5\u53ca\u865a\u62df\u673a\u4e0e\u5916\u90e8\u7f51\u7edc\u4e4b\u95f4\u7684\u901a\u4fe1\u3002 &#x1f680; <font color=\"#e47542\">\u8f6f\u4ef6\u5b58\u50a8 Initiator<\/font>&#xff08;\u5b58\u50a8\u542f\u52a8\u5668&#xff09;\u662f\u4e00\u79cd\u5728\u4e3b\u673a\u6216\u865a\u62df\u673a\u4e0a\u8fd0\u884c\u7684\u8f6f\u4ef6&#xff0c;\u7528\u4e8e\u53d1\u8d77\u4e0e\u5b58\u50a8\u8bbe\u5907&#xff08;\u5982 SAN \u6216 NAS&#xff09;\u7684\u901a\u4fe1\u3002\u5b83\u901a\u8fc7\u7279\u5b9a\u7684\u5b58\u50a8\u534f\u8bae&#xff08;\u5982 iSCSI\u3001Fibre Channel \u7b49&#xff09;\u4e0e\u5b58\u50a8\u76ee\u6807&#xff08;Target&#xff09;\u8fdb\u884c\u4ea4\u4e92&#xff0c;\u4f7f\u4e3b\u673a\u80fd\u591f\u8bbf\u95ee\u8fdc\u7a0b\u5b58\u50a8\u8d44\u6e90\u3002<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/04\/20250418203143-6802b6af69421.png\" alt=\"\u5728\u8fd9\u91cc\u63d2\u5165\u56fe\u7247\u63cf\u8ff0\" \/><\/p>\n<h3>1.1 CPU \u8ba1\u7b97\u7279\u6027\u635f\u5931<\/h3>\n<p>\u4f17\u6240\u5468\u77e5&#xff0c;IaaS \u516c\u5171\u4e91\u6280\u672f\u7684\u6838\u5fc3\u662f Intel \u81f3\u5f3a\u5904\u7406\u5668 VT \u7b49 <font color=\"#e47542\">\u786c\u4ef6\u8f85\u52a9\u865a\u62df\u5316\u6280\u672f<\/font>&#xff08;Hardware-assisted virtualization&#xff09;&#xff0c;\u914d\u5408\u4e3b\u6d41\u865a\u62df\u5316\u7cfb\u7edf\u8f6f\u4ef6&#xff08;KVM \/ Xen \/ VMware ESXi \u7b49&#xff09;&#xff0c;\u5b9e\u73b0\u4e86 IaaS \u5f39\u6027\u8ba1\u7b97&#xff1b;\u5ba2\u6237\u5219\u662f\u901a\u8fc7 ECS&#xff08;\u6216\u8005 AWS EC2&#xff09;\u8d2d\u4e70\u865a\u62df\u673a&#xff08;VM&#xff09;\u5f62\u5f0f\u7684\u8ba1\u7b97\u8d44\u6e90\u3002<\/p>\n<p>\u5f97\u76ca\u4e8e\u9ad8\u5ea6\u6210\u719f\u7684\u865a\u62df\u5316\u6280\u672f&#xff0c;VM \u5f62\u5f0f\u7684\u8ba1\u7b97\u8d44\u6e90 \u201c<font color=\"#e47542\">\u51e0\u4e4e<\/font>\u201d \u7b49\u4ef7\u4e8e\u5ba2\u6237\u7ebf\u4e0b\u7684\u7269\u7406\u670d\u52a1\u5668\u8d44\u6e90&#xff0c;\u4f46\u662f \u201c<font color=\"#e47542\">\u51e0\u4e4e<\/font>\u201d \u5e76\u4e0d\u662f \u201c<font color=\"#e47542\">\u5b8c\u5168<\/font>\u201d\u3002\u4e00\u4e2a\u5178\u578b\u7684\u6848\u4f8b\u5c31\u662f Intel \u81f3\u5f3a\u5904\u7406\u5668\u7684 VT \u786c\u4ef6\u8f85\u52a9\u865a\u62df\u5316\u80fd\u529b\u4f1a\u88ab\u516c\u5171\u4e91\u670d\u52a1\u63d0\u4f9b\u5546\u7684\u865a\u62df\u5316\u7cfb\u7edf \u201c<font color=\"#e47542\">\u6d88\u8d39\u6389<\/font>\u201d&#xff0c;\u5ba2\u6237\u65e0\u6cd5\u5728\u516c\u5171\u4e91 VM \u5b9e\u4f8b\u4e2d\u518d\u6b21\u90e8\u7f72\u865a\u62df\u5316\u7cfb\u7edf&#xff0c;\u81f4\u4f7f\u4f20\u7edf OpenStack \u548c VMware based workload \u65e0\u6cd5\u5728\u516c\u5171\u4e91\u90e8\u7f72\u3002<\/p>\n<p>\u5ba2\u6237\u5e0c\u671b\u7528\u4e00\u5957 OpenStack \/ VMware \u7edf\u4e00\u7ba1\u7406 <font color=\"#e47542\">\u516c\u5171\u4e91\u7ebf\u4e0a\u8d44\u6e90<\/font> \u548c <font color=\"#e47542\">\u4e13\u6709\u4e91\u7ebf\u4e0b\u8d44\u6e90<\/font>&#xff0c;\u540c\u65f6\u5728\u63a7\u5236\u9762\u548c\u6570\u636e\u9762\u6253\u901a\u7ebf\u4e0a\u7ebf\u4e0b\u8d44\u6e90&#xff0c;\u5728\u517c\u987e\u4e13\u6709\u4e91\u6570\u636e\u5b89\u5168\u3001\u6cd5\u5f8b\u5408\u89c4\u7684\u57fa\u7840\u4e0a&#xff0c;\u5145\u5206\u5229\u7528\u516c\u5171\u4e91\u8ba1\u7b97\u8d44\u6e90\u7684\u5f39\u6027\u80fd\u529b&#xff0c;\u4f46\u662f\u7531\u4e8e Intel \u81f3\u5f3a\u5904\u7406\u5668 VT \u786c\u4ef6\u8f85\u52a9\u865a\u62df\u5316\u80fd\u529b \u201c\u88ab\u6d88\u8d39\u201d&#xff0c;\u4f7f\u5f97\u6b64\u79cd <font color=\"#e47542\">\u6df7\u5408\u4e91\u6280\u672f<\/font> \u5f88\u96be\u5728\u516c\u5171\u4e91\u5b9e\u73b0\u3002\u4e91\u539f\u751f\u5b89\u5168\u5bb9\u5668\u521b\u65b0\u4f9d\u8d56 Intel VT \u786c\u4ef6\u8f85\u52a9\u865a\u62df\u5316\u80fd\u529b\u8f93\u51fa&#xff0c;\u8fd9\u662f\u4f20\u7edf\u865a\u62df\u5316\u65e0\u6cd5\u89e3\u51b3\u7684\u95ee\u9898\u3002<\/p>\n<h3>1.2 \u8d44\u6e90\u4e89\u62a2\u4e0d\u53ef\u907f\u514d<\/h3>\n<p>\u4ee5\u4f20\u7edf\u7684 KVM \u865a\u62df\u5316\u7cfb\u7edf\u4e3a\u4f8b&#xff0c;\u53cc\u8def Skylake&#xff08;96 \u4e2a HT&#xff09;\u8ba1\u7b97\u8d44\u6e90\u7684\u865a\u62df\u5316\u5178\u578b\u90e8\u7f72\u60c5\u51b5\u662f&#xff1a;\u6709 8 \u4e2a HT \u90e8\u7f72\u7f51\u7edc\u865a\u62df\u5316 vSwitch \u548c\u5b58\u50a8\u865a\u62df\u5316&#xff0c;\u5bf9\u5916\u552e\u5356 88 \u4e2a HT \u4f5c\u4e3a vCPU \u8ba1\u7b97\u8d44\u6e90\u3002\u6211\u4eec\u9700\u8981\u6ce8\u610f\u5230&#xff0c;\u5bf9\u5916\u552e\u5356\u7684 88 HT vCPU \u8ba1\u7b97\u8d44\u6e90\u548c 8 HT \u7f51\u7edc \/ \u5b58\u50a8\u865a\u62df\u5316\u662f\u90e8\u7f72\u5728\u540c\u4e00\u7ec4 Skylake CPU \u4e0a\u7684&#xff0c;\u90a3\u4e48\u5982\u4e0b\u5171\u4eab\u8d44\u6e90\u4e89\u62a2\u662f\u4e0d\u53ef\u907f\u514d\u7684\u3002<\/p>\n<ul>\n<li>CPU DDR \u5e26\u5bbd\u3001LLC \u7b49\u5171\u4eab\u8d44\u6e90\u7684\u4e89\u62a2\u3002\u5728\u673a\u5934\u7f51\u7edc\u5e26\u5bbd\u8fc5\u901f\u63d0\u5347\u7684\u5f53\u4e0b&#xff0c;DDR \u5e26\u5bbd\u3001LLC \u7b49\u8d44\u6e90\u4e89\u62a2\u73b0\u8c61\u6108\u53d1\u7a81\u51fa\u3002<\/li>\n<li>\u534a\u865a\u62df\u5316&#xff08;Para-virtualized&#xff09;I\/O \u8bbe\u5907\u6a21\u578b\u7b49\u8d44\u6e90\u4e89\u62a2\u5f15\u5165\u552e\u5356 CPU \u6296\u52a8\u548c\u552e\u5356 I\/O \u6296\u52a8\u3002<\/li>\n<li>\u5b58\u50a8\u548c\u7f51\u7edc\u7b49 I\/O \u5185\u90e8\u5c42\u7ea7\u5316 HQoS \u96be\u4e8e\u5b9e\u65bd\u3002\u4e00\u822c\u800c\u8a00&#xff0c;\u5c42\u7ea7\u5316 HQoS \u662f\u89e3\u51b3\u8d44\u6e90\u4e89\u62a2\u7684\u6709\u6548\u624b\u6bb5&#xff0c;\u7535\u4fe1\u7ea7\u7f51\u7edc\u8bbe\u5907\u4e00\u822c\u4f1a\u90e8\u7f72 HQoS \u8fdb\u884c\u8d44\u6e90\u8c03\u5ea6&#xff0c;\u800c HQoS \u7684\u5178\u578b\u90e8\u7f72\u65b9\u6cd5\u9700\u8981\u901a\u8fc7\u82af\u7247\u5b9e\u73b0\u3002<\/li>\n<\/ul>\n<p>&#x1f680; HT \u6307\u7684\u662f Hyper-Threading Technology&#xff08;<font color=\"#e47542\">\u8d85\u7ebf\u7a0b\u6280\u672f<\/font>&#xff09;&#xff0c;\u8fd9\u662f\u82f1\u7279\u5c14&#xff08;Intel&#xff09;\u5f00\u53d1\u7684\u4e00\u79cd\u6280\u672f&#xff0c;\u65e8\u5728\u63d0\u9ad8 CPU \u7684\u5e76\u884c\u5904\u7406\u80fd\u529b\u3002 &#x1f680; \u5c42\u7ea7\u5316 HQoS&#xff08;Hierarchical Quality of Service&#xff0c;<font color=\"#e47542\">\u5206\u5c42\u670d\u52a1\u8d28\u91cf<\/font>&#xff09; \u662f\u4e00\u79cd\u9ad8\u7ea7\u7684\u7f51\u7edc\u6d41\u91cf\u7ba1\u7406\u6280\u672f&#xff0c;\u7528\u4e8e\u5728\u590d\u6742\u7f51\u7edc\u73af\u5883\u4e2d\u5bf9\u4e0d\u540c\u5c42\u6b21\u7684\u6d41\u91cf\u8fdb\u884c\u7cbe\u7ec6\u5316\u7684\u4f18\u5148\u7ea7\u63a7\u5236\u548c\u8d44\u6e90\u5206\u914d\u3002\u5b83\u901a\u8fc7\u591a\u5c42\u7ea7\u7684\u8c03\u5ea6\u548c\u7b56\u7565\u7ba1\u7406&#xff0c;\u786e\u4fdd\u5173\u952e\u4e1a\u52a1\u6d41\u91cf\u7684\u670d\u52a1\u8d28\u91cf&#xff08;QoS&#xff09;&#xff0c;\u540c\u65f6\u4f18\u5316\u7f51\u7edc\u8d44\u6e90\u7684\u5229\u7528\u7387\u3002<\/p>\n<h3>1.3 I\/O \u6027\u80fd\u74f6\u9888<\/h3>\n<p>\u4f20\u7edf KVM \u865a\u62df\u5316\u7cfb\u7edf\u7531&#xff08;<font color=\"#e47542\">\u8ba1\u7b97\u865a\u62df\u5316<\/font>&#xff09;QEMU-KVM &#043; &#xff08;<font color=\"#e47542\">\u7f51\u7edc\u865a\u62df\u5316<\/font>&#xff09;DPDK based vSwitch &#043; &#xff08;<font color=\"#e47542\">\u5b58\u50a8\u865a\u62df\u5316<\/font>&#xff09;SPDK based I\/O initiator \u6784\u6210\u3002<\/p>\n<p>&#x1f680; QEMU \u662f\u4e00\u4e2a\u5f00\u6e90\u7684\u786c\u4ef6\u865a\u62df\u5316\u5de5\u5177&#xff0c;\u4e3b\u8981\u7528\u4e8e\u6a21\u62df\u8ba1\u7b97\u673a\u786c\u4ef6\u73af\u5883&#xff0c;\u652f\u6301\u591a\u79cd\u67b6\u6784&#xff08;\u5982 x86\u3001ARM\u3001PowerPC \u7b49&#xff09;\u3002\u5b83\u53ef\u4ee5\u5355\u72ec\u4f7f\u7528&#xff0c;\u4e5f\u53ef\u4ee5\u4e0e KVM&#xff08;Kernel-based Virtual Machine&#xff09;\u7ed3\u5408&#xff0c;\u63d0\u4f9b\u9ad8\u6548\u7684\u865a\u62df\u5316\u89e3\u51b3\u65b9\u6848\u3002 &#x1f680; DPDK&#xff08;Data Plane Development Kit&#xff09;\u662f\u4e00\u4e2a\u5f00\u6e90\u7684\u7528\u6237\u6001\u7f51\u7edc\u6570\u636e\u5e73\u9762\u5f00\u53d1\u5de5\u5177\u5305&#xff0c;\u65e8\u5728\u52a0\u901f\u6570\u636e\u5305\u5904\u7406\u6027\u80fd\u3002\u5b83\u901a\u8fc7\u7ed5\u8fc7\u64cd\u4f5c\u7cfb\u7edf\u5185\u6838&#xff0c;\u76f4\u63a5\u5728\u7528\u6237\u6001\u5904\u7406\u7f51\u7edc\u6570\u636e\u5305&#xff0c;\u663e\u8457\u63d0\u9ad8\u4e86\u7f51\u7edc\u5e94\u7528\u7684\u6027\u80fd\u3002 &#x1f680; SPDK&#xff08;Storage Performance Development Kit&#xff09;\u662f\u4e00\u4e2a\u5f00\u6e90\u7684\u7528\u6237\u6001\u5b58\u50a8\u6027\u80fd\u5f00\u53d1\u5de5\u5177\u5305&#xff0c;\u4e13\u6ce8\u4e8e\u52a0\u901f\u5b58\u50a8\u5e94\u7528\u7684\u6027\u80fd\u3002\u5b83\u901a\u8fc7\u5c06\u5b58\u50a8 I\/O \u64cd\u4f5c\u8f6c\u79fb\u5230\u7528\u6237\u6001&#xff0c;\u51cf\u5c11\u5185\u6838\u5f00\u9500&#xff0c;\u4ece\u800c\u63d0\u5347\u5b58\u50a8\u6027\u80fd\u3002<\/p>\n<p>\u5728 Intel \u5f15\u5165 VT \u786c\u4ef6\u865a\u62df\u5316\u652f\u6301\u540e&#xff0c;\u914d\u5408 KVM\u3001Xen \u7b49\u865a\u62df\u5316\u7cfb\u7edf\u8f6f\u4ef6&#xff0c;\u7531 CPU \u6307\u4ee4\u5904\u7406\u7684\u6570\u636e\u9762\u548c KVM \u7b49\u865a\u62df\u5316\u7cfb\u7edf\u8f6f\u4ef6\u5f62\u6210\u4e86\u63a7\u5236\u9762\u53ca\u5f02\u5e38\u5904\u7406\u8def\u5f84&#xff0c;\u6b64\u79cd\u8f6f\u786c\u4ef6\u534f\u540c\u8bbe\u8ba1\u65e2\u5b9e\u73b0\u4e86 CPU \u548c\u5185\u5b58\u865a\u62df\u5316\u7684\u6570\u636e\u8def\u5f84\u7684\u6700\u5c0f\u5f00\u9500&#xff0c;\u53c8\u4fdd\u7559\u4e86 KVM \u63a7\u5236\u8def\u5f84\u548c\u5f02\u5e38\u5904\u7406\u8def\u5f84\u7684\u9ad8\u5ea6\u7075\u6d3b\u6027\u3002<\/p>\n<p>\u540c\u5904\u4e8e\u6570\u636e\u8def\u5f84\u7684\u5b58\u50a8\u865a\u62df\u5316\u548c\u7f51\u7edc\u865a\u62df\u5316\u867d\u7136\u901a\u8fc7 DPDK \u548c SPDK \u7b49\u6280\u672f\u63a5\u8fd1\u4e86\u8f6f\u4ef6\u4f18\u5316\u7684\u6280\u672f\u6781\u9650&#xff0c;\u4f46\u662f\u4ecd\u7136\u65e0\u6cd5\u548c\u82af\u7247\u7684\u52a0\u901f\u6027\u80fd\u5ab2\u7f8e\u3002\u7279\u522b\u662f\u5728\u7f51\u7edc\u541e\u5410\u5411 100GbE \u6f14\u8fdb\u7684\u8fc7\u7a0b\u4e2d&#xff0c;\u4ea4\u6362\u7f51\u7edc\u7684\u5e26\u5bbd\u80fd\u529b\u548c Intel \u81f3\u5f3a\u5904\u7406\u5668\u7684\u5904\u7406\u80fd\u529b\u95f4\u7684\u5dee\u8ddd\u9010\u6e10\u62c9\u5927&#xff0c;\u5728\u4f20\u7edf KVM \u865a\u62df\u5316\u7cfb\u7edf\u4e0b&#xff0c;\u901a\u8fc7 DPDK\u3001SPDK \u7b49\u7eaf\u8f6f\u4ef6\u8fdb\u884c I\/O \u6027\u80fd\u4f18\u5316\u7684\u74f6\u9888\u65e5\u6e10\u51f8\u663e\u3002<\/p>\n<h2>2.\u5f39\u6027\u88f8\u91d1\u5c5e\u6280\u672f\u5b9e\u73b0<\/h2>\n<p>\u7b2c\u4e00\u4ee3\u865a\u62df\u5316\u6280\u672f\u7684\u4e1a\u52a1\u75db\u70b9&#xff0c;\u50ac\u751f\u4e86\u7b2c\u4e8c\u4ee3\u865a\u62df\u5316\u6280\u672f\u7684\u4ea7\u751f&#xff0c;\u5f39\u6027\u88f8\u91d1\u5c5e\u4ea7\u54c1\u4e5f\u5e94\u8fd0\u800c\u751f\u3002\u90a3\u4e48\u7b2c\u4e8c\u4ee3\u865a\u62df\u5316\u6280\u672f\u5177\u5907\u54ea\u4e9b\u7279\u5f81\u5462&#xff1f;<\/p>\n<ul>\n<li>1\ufe0f\u20e3 \u5168\u90e8 I\/O \u8bbe\u5907\u901a\u8fc7 VT-d \u8bbe\u5907\u76f4\u901a\u6a21\u5f0f\u8fdb\u5165 VM&#xff0c;\u4ee5\u6b64\u51cf\u5c11 para-virtualization I\/O \u534a\u865a\u62df\u5316\u5f00\u9500\u3002<\/li>\n<li>2\ufe0f\u20e3 \u968f\u7740 VT-d \u8bbe\u5907\u76f4\u901a\u7684\u5f15\u5165&#xff0c;\u7f51\u7edc\u865a\u62df\u5316\u548c\u5b58\u50a8\u865a\u62df\u5316\u9700\u8981\u4e00\u4e2a\u65b0\u7684\u4e1a\u52a1\u90e8\u7f72\u70b9\u3002<\/li>\n<li>3\ufe0f\u20e3 VT-d \u8bbe\u5907\u76f4\u901a\u5f15\u5165\u540e&#xff0c;SR-IOV \u7b49\u6280\u672f\u5374\u65e0\u6cd5\u8fbe\u5230\u548c\u4f20\u7edf QEMU PV \u8bbe\u5907\u4e00\u6837\u7684\u7075\u6d3b\u6027&#xff0c;I\/O \u786c\u4ef6\u865a\u62df\u5316\u50ac\u751f Intel scalable IOV \u7684\u4e1a\u52a1\u8bc9\u6c42\u3002<\/li>\n<li>4\ufe0f\u20e3 \u968f\u7740\u5b58\u50a8\u865a\u62df\u5316\u548c\u7f51\u7edc\u865a\u62df\u5316\u65b0\u7684\u4e1a\u52a1\u90e8\u7f72\u70b9\u7684\u4ea7\u751f&#xff0c;\u8fd9\u4e2a\u4e1a\u52a1\u90e8\u7f72\u70b9\u5f88\u663e\u7136\u9700\u8981\u9488\u5bf9\u8ba1\u7b97\u3001\u7f51\u7edc\u3001\u5b58\u50a8\u3001\u5b89\u5168\u7b49 IaaS \u6838\u5fc3\u4e1a\u52a1\u90e8\u7f72\u5b9a\u5236\u5316\u82af\u7247\u52a0\u901f\u3002<\/li>\n<li>5\ufe0f\u20e3 \u540c\u65f6\u652f\u6301\u4f20\u7edf VM\u3001\u5f39\u6027\u88f8\u91d1\u5c5e\u670d\u52a1\u5668\u3001\u5b89\u5168\u5bb9\u5668\u7b49 IaaS \u6700\u65b0\u4e1a\u52a1\u8bc9\u6c42\u3002<\/li>\n<\/ul>\n<p>&#x1f680; SR-IOV&#xff08;Single Root I\/O Virtualization&#xff0c;<font color=\"#e47542\">\u5355\u6839 I\/O \u865a\u62df\u5316<\/font>&#xff09; \u662f\u4e00\u79cd\u786c\u4ef6\u865a\u62df\u5316\u6280\u672f&#xff0c;\u5141\u8bb8\u5355\u4e2a\u7269\u7406\u8bbe\u5907&#xff08;\u5982\u7f51\u5361\u6216\u5b58\u50a8\u63a7\u5236\u5668&#xff09;\u88ab\u865a\u62df\u5316\u4e3a\u591a\u4e2a\u865a\u62df\u8bbe\u5907&#xff0c;\u5e76\u76f4\u63a5\u5206\u914d\u7ed9\u591a\u4e2a\u865a\u62df\u673a&#xff08;VM&#xff09;\u4f7f\u7528\u3002SR-IOV \u901a\u8fc7\u786c\u4ef6\u7ea7\u522b\u7684\u865a\u62df\u5316&#xff0c;\u663e\u8457\u63d0\u5347\u4e86\u865a\u62df\u673a\u7684 I\/O \u6027\u80fd&#xff0c;\u540c\u65f6\u51cf\u5c11\u4e86 Hypervisor&#xff08;\u865a\u62df\u5316\u7ba1\u7406\u7a0b\u5e8f&#xff09;\u7684\u5e72\u9884\u3002 &#x1f680; Intel Scalable IOV&#xff08;Scalable I\/O Virtualization&#xff0c;<font color=\"#e47542\">\u53ef\u6269\u5c55 I\/O \u865a\u62df\u5316<\/font>&#xff09; \u662f Intel \u63d0\u51fa\u7684\u4e00\u79cd\u65b0\u4e00\u4ee3 I\/O \u865a\u62df\u5316\u6280\u672f&#xff0c;\u65e8\u5728\u89e3\u51b3\u4f20\u7edf SR-IOV \u5728\u53ef\u6269\u5c55\u6027\u548c\u7075\u6d3b\u6027\u65b9\u9762\u7684\u5c40\u9650\u6027\u3002Scalable IOV \u901a\u8fc7\u66f4\u7ec6\u7c92\u5ea6\u7684\u8d44\u6e90\u5206\u914d\u548c\u7ba1\u7406&#xff0c;\u652f\u6301\u66f4\u5927\u89c4\u6a21\u7684\u865a\u62df\u5316\u73af\u5883&#xff0c;\u540c\u65f6\u4f18\u5316\u6027\u80fd\u548c\u8d44\u6e90\u5229\u7528\u7387\u3002<\/p>\n<p>\u7b80\u800c\u8a00\u4e4b&#xff0c;Hypervisor \u7684\u4e3b\u8981\u7ec4\u4ef6\u5168\u90e8\u4e0b\u6c89\u8fdb\u5165\u4e00\u4e2a\u5b9a\u5236\u8ba1\u7b97\u8282\u70b9&#xff0c;\u8be5\u5b9a\u5236\u8ba1\u7b97\u8282\u70b9\u5b8c\u6210 I\/O \u8bbe\u5907\u865a\u62df\u5316\u3001\u7f51\u7edc\u865a\u62df\u5316\u3001\u5b58\u50a8\u865a\u62df\u5316\u548c\u7ba1\u63a7\u90e8\u7f72&#xff0c;\u4ee5\u53ca\u5b89\u5168\u7279\u6027\u90e8\u7f72\u7b49\u3002<\/p>\n<p>\u800c\u4e3b\u673a\u4fa7&#xff0c;\u9488\u5bf9\u516c\u5171\u4e91\u7684\u9700\u6c42&#xff0c;\u4ece\u8ba1\u7b97\u548c\u5185\u5b58\u539f\u6765\u7684 QUME &#043; KVM \u65b9\u5f0f&#xff0c;\u7ecf\u8fc7\u9ad8\u5ea6\u5b9a\u5236\u548c\u7626\u8eab\u540e&#xff0c;\u964d\u4f4e\u4e86\u4e3b\u673a\u8d44\u6e90\u5360\u7528\u5e76\u63d0\u5347\u8ba1\u7b97\u670d\u52a1\u8d28\u91cf&#xff0c;\u6f14\u5316\u5230\u4e86\u88f8\u91d1\u5c5e\u67b6\u6784\u3002<\/p>\n<p>\u7b2c\u4e8c\u4ee3\u865a\u62df\u5316\u6280\u672f\u4f7f\u5f39\u6027\u88f8\u91d1\u5c5e\u7684\u4ea7\u54c1\u843d\u5730\u6210\u4e3a\u53ef\u80fd\u3002\u963f\u91cc\u4e91\u5728 2017 \u5e74 10 \u6708\u4e3e\u884c\u7684\u676d\u5dde\u4e91\u6816\u5927\u4f1a\u4e0a\u6b63\u5f0f\u53d1\u5e03\u5f39\u6027\u88f8\u91d1\u5c5e\u4ea7\u54c1&#xff0c;\u540c\u5e74 11 \u6708&#xff0c;AWS reinvent \u53d1\u5e03 EC 2 \u7248\u672c\u5f39\u6027\u88f8\u91d1\u5c5e\u4ea7\u54c1\u3002\u4e2d\u7f8e\u516c\u5171\u4e91\u670d\u52a1\u63d0\u4f9b\u5546\u53ef\u4ee5\u8bf4\u5728\u5f39\u6027\u88f8\u91d1\u5c5e\u7684\u4ea7\u54c1\u5b9a\u4e49\u3001\u4ea7\u54c1\u9002\u7528\u573a\u666f\u548c\u6280\u672f\u4e0a\u6b8a\u9014\u540c\u5f52\u3002<font color=\"#e47542\">\u5f39\u6027\u88f8\u91d1\u5c5e\u7684\u6838\u5fc3\u4ea7\u54c1\u6280\u672f\u903b\u8f91&#xff1a;\u901a\u8fc7\u6280\u672f\u521b\u65b0&#xff0c;\u4f7f\u666e\u901a\u7269\u7406\u670d\u52a1\u5668\u5177\u5907\u865a\u62df\u673a\u7684\u5f39\u6027\u548c\u4f7f\u7528\u4f53\u9a8c<\/font>\u3002<\/p>\n<p>\u6b63\u662f\u6709\u4e86\u8fd9\u4e2a\u903b\u8f91&#xff0c;\u6211\u4eec\u53ef\u4ee5\u63a8\u6f14\u51fa\u6280\u672f\u521b\u65b0\u7684\u7a81\u7834\u70b9&#xff1a;<font color=\"#e47542\">\u901a\u8fc7\u8f6f\u786c\u4e00\u4f53\u5316\u7684\u6280\u672f\u624b\u6bb5&#xff0c;\u8ba9\u666e\u901a\u7269\u7406\u670d\u52a1\u5668\u80fd\u591f\u65e0\u7f1d\u63a5\u5165\u4e91\u5e73\u53f0\u7684\u7ba1\u63a7\u7cfb\u7edf\u3001VPC \u4e91\u7f51\u7edc\u548c EBS \u4e91\u76d8<\/font>\u3002<\/p>\n<h3>2.1 VPC \u548c EBS \u4e91\u76d8\u63a5\u5165<\/h3>\n<p>\u6211\u4eec\u77e5\u9053\u5728\u865a\u62df\u5316\u6280\u672f\u4e2d&#xff0c;\u865a\u62df\u673a\u662f\u901a\u8fc7 Virtio \u5b9e\u73b0\u7f51\u7edc\u548c\u5b58\u50a8 I\/O \u8bbe\u5907\u7684&#xff1b;\u540c\u65f6&#xff0c;\u6211\u4eec\u6ce8\u610f\u5230&#xff0c;Virtio \u8fd9\u4e2a\u534a\u865a\u62df\u5316\u8bbe\u5907\u6a21\u578b\u5b9e\u9645\u4e0a\u662f\u4e25\u683c\u6309\u7167 \u201c\u771f\u5b9e\u201d PCIe \u8bbe\u5907\u89c4\u8303\u7684\u5b9a\u4e49\u800c\u5b9e\u73b0\u7684 I\/O \u8bbe\u5907\u3002\u4e5f\u5c31\u662f\u8bf4&#xff0c;Virtio \u534a\u865a\u62df\u5316\u8bbe\u5907\u5b8c\u5168\u53ef\u4ee5\u901a\u8fc7\u82af\u7247\u5b9e\u73b0\u3002<\/p>\n<p>&#x1f680; Virtio \u662f\u4e00\u79cd\u7528\u4e8e\u865a\u62df\u5316\u73af\u5883\u7684 I\/O \u8bbe\u5907\u6807\u51c6\u5316\u6846\u67b6&#xff0c;\u65e8\u5728\u63d0\u9ad8\u865a\u62df\u673a&#xff08;VM&#xff09;\u4e0e\u4e3b\u673a\u4e4b\u95f4\u7f51\u7edc\u3001\u5b58\u50a8\u548c\u5176\u4ed6 I\/O \u8bbe\u5907\u7684\u6027\u80fd\u3002Virtio \u901a\u8fc7\u63d0\u4f9b\u4e00\u7ec4\u901a\u7528\u7684\u865a\u62df\u8bbe\u5907\u63a5\u53e3&#xff0c;\u7b80\u5316\u4e86\u865a\u62df\u673a\u7684 I\/O \u64cd\u4f5c&#xff0c;\u5e76\u51cf\u5c11\u4e86 Hypervisor&#xff08;\u865a\u62df\u5316\u7ba1\u7406\u7a0b\u5e8f&#xff09;\u7684\u5e72\u9884&#xff0c;\u4ece\u800c\u63d0\u5347\u4e86\u865a\u62df\u673a\u7684 I\/O \u6027\u80fd\u3002 &#x1f680; PCIe \u7684\u5168\u79f0\u662f Peripheral Component Interconnect Express&#xff0c;\u4e2d\u6587\u901a\u5e38\u79f0\u4e3a \u9ad8\u901f\u5916\u56f4\u7ec4\u4ef6\u4e92\u8054 \u6216 PCI \u9ad8\u901f\u603b\u7ebf\u3002\u5b83\u662f\u8ba1\u7b97\u673a\u4e2d\u7528\u4e8e\u8fde\u63a5\u9ad8\u901f\u5916\u56f4\u8bbe\u5907&#xff08;\u5982\u663e\u5361\u3001\u7f51\u5361\u3001\u5b58\u50a8\u63a7\u5236\u5668\u7b49&#xff09;\u7684\u603b\u7ebf\u6807\u51c6\u3002<\/p>\n<p>\u5728\u901a\u8fc7\u82af\u7247\u5b9e\u73b0 Virtio \u7684\u65f6\u5019&#xff0c;\u8003\u8651\u5230 VPC \u548c EBS \u4e91\u76d8\u5b9e\u73b0\u7684\u590d\u6742\u5ea6&#xff0c;\u6211\u4eec\u91c7\u7528\u4e86\u65b0\u7684\u6a21\u5f0f&#xff1a;<font color=\"#e47542\">\u8ba9\u82af\u7247\u900f\u4f20 PCIe TLP \u5305\u5230\u53ef\u7f16\u7a0b\u5904\u7406\u5668&#xff0c;\u7136\u540e\u901a\u8fc7\u53ef\u7f16\u7a0b\u5904\u7406\u5668\u590d\u7528 QEMU \u5df2\u6709\u7684\u6210\u719f\u7684 Virtio \u540e\u7aef\u4ee3\u7801\u3002\u6b64\u79cd\u6a21\u5f0f\u80fd\u591f\u6700\u5927\u9650\u5ea6\u5730\u4fdd\u6301\u65e2\u6709\u7684\u865a\u62df\u5316\u67b6\u6784&#xff0c;\u505a\u5230\u4e91\u5e73\u53f0\u7ba1\u63a7\u7cfb\u7edf\u3001VPC \u7cfb\u7edf\u3001EBS \u4e91\u76d8\u7cfb\u7edf\u7684 \u201c\u96f6\u4fee\u6539\u201d\u3002<\/font><\/p>\n<ul>\n<li>\u82af\u7247\u900f\u4f20 PCIe TLP \u5305&#xff1a;\n<ul>\n<li>\u786c\u4ef6\u82af\u7247&#xff08;\u5982\u7f51\u5361\u6216\u5b58\u50a8\u63a7\u5236\u5668&#xff09;\u53ef\u4ee5\u76f4\u63a5\u5c06 PCIe TLP \u6570\u636e\u5305\u4f20\u9012\u7ed9\u4e00\u4e2a\u53ef\u7f16\u7a0b\u5904\u7406\u5668&#xff08;\u5982 FPGA \u6216\u667a\u80fd\u7f51\u5361&#xff09;\u3002<\/li>\n<li>\u8fd9\u6837&#xff0c;\u786c\u4ef6\u8bbe\u5907\u7684\u6570\u636e\u53ef\u4ee5\u76f4\u63a5\u88ab\u865a\u62df\u673a\u8bbf\u95ee&#xff0c;\u800c\u4e0d\u9700\u8981\u7ecf\u8fc7 Hypervisor \u7684\u8f6f\u4ef6\u6a21\u62df\u5c42\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\u901a\u8fc7\u53ef\u7f16\u7a0b\u5904\u7406\u5668\u590d\u7528 Virtio \u540e\u7aef\u4ee3\u7801&#xff1a;\n<ul>\n<li>\u53ef\u7f16\u7a0b\u5904\u7406\u5668&#xff08;\u5982 FPGA \u6216\u667a\u80fd\u7f51\u5361&#xff09;\u53ef\u4ee5\u8fd0\u884c Virtio \u7684\u540e\u7aef\u4ee3\u7801\u3002<\/li>\n<li>Virtio \u540e\u7aef\u4ee3\u7801\u662f Hypervisor \u4e2d\u5df2\u7ecf\u6210\u719f\u7684\u4ee3\u7801&#xff0c;\u7528\u4e8e\u5904\u7406\u865a\u62df\u673a\u7684 I\/O \u8bf7\u6c42\u3002<\/li>\n<li>\u901a\u8fc7\u590d\u7528\u8fd9\u4e9b\u4ee3\u7801&#xff0c;\u865a\u62df\u673a\u53ef\u4ee5\u76f4\u63a5\u4f7f\u7528 Virtio \u63a5\u53e3\u4e0e\u786c\u4ef6\u901a\u4fe1&#xff0c;\u800c\u4e0d\u9700\u8981\u4fee\u6539\u73b0\u6709\u7684 Virtio \u5b9e\u73b0\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\u4fdd\u6301\u65e2\u6709\u865a\u62df\u5316\u67b6\u6784&#xff1a;\n<ul>\n<li>\u8fd9\u79cd\u65b9\u5f0f\u4e0d\u9700\u8981\u5bf9\u73b0\u6709\u7684\u865a\u62df\u5316\u67b6\u6784&#xff08;\u5982 QEMU\u3001KVM&#xff09;\u8fdb\u884c\u4fee\u6539\u3002<\/li>\n<li>\u865a\u62df\u673a\u4ecd\u7136\u901a\u8fc7 Virtio \u63a5\u53e3\u4e0e\u786c\u4ef6\u901a\u4fe1&#xff0c;Hypervisor \u4ecd\u7136\u8d1f\u8d23\u7ba1\u7406\u865a\u62df\u673a\u3002<\/li>\n<\/ul>\n<\/li>\n<li>\u201c\u96f6\u4fee\u6539\u201d&#xff1a;\n<ul>\n<li>\u4e91\u5e73\u53f0\u7684\u7ba1\u63a7\u7cfb\u7edf\u3001VPC&#xff08;\u865a\u62df\u79c1\u6709\u4e91&#xff09;\u7cfb\u7edf\u3001EBS&#xff08;\u4e91\u76d8&#xff09;\u7cfb\u7edf\u90fd\u4e0d\u9700\u8981\u4fee\u6539\u3002<\/li>\n<li>\u8fd9\u610f\u5473\u7740\u73b0\u6709\u7684\u4e91\u5e73\u53f0\u53ef\u4ee5\u65e0\u7f1d\u652f\u6301\u8fd9\u79cd\u65b0\u7684\u786c\u4ef6\u52a0\u901f\u65b9\u5f0f\u3002<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<h3>2.2 \u5b9e\u73b0\u5927\u91cf\u5f39\u6027\u7f51\u5361&#xff08;ENI&#xff09;\u548c EBS \u4e91\u76d8\u8bbe\u5907\u63a5\u5165<\/h3>\n<p>VT-x \/ KVM \u865a\u62df\u5316\u6280\u672f\u5177\u6709\u5929\u7136\u6280\u672f\u4f18\u52bf&#xff0c;\u652f\u6301\u5927\u91cf\u7f51\u7edc\u548c\u5b58\u50a8\u8bbe\u5907\u3002\u800c\u5f39\u6027\u88f8\u91d1\u5c5e\u4ea7\u54c1\u7684\u6838\u5fc3\u51fa\u53d1\u70b9\u5c31\u662f\u8981\u517c\u5177\u865a\u62df\u673a\u548c\u4f20\u7edf\u7269\u7406\u673a\u7684\u4f18\u70b9\u3002\u865a\u62df\u673a\u5bf9\u5927\u91cf\u7f51\u7edc\u8bbe\u5907\u548c\u5b58\u50a8\u8bbe\u5907\u7684\u652f\u6301&#xff0c;\u5fc5\u987b\u5728\u5f39\u6027\u88f8\u91d1\u5c5e\u4ea7\u54c1\u4e2d\u4e88\u4ee5\u5b9e\u73b0\u3002<\/p>\n<p>\u5728\u591a\u79cd\u89c4\u683c\u7684\u7f51\u5361\u548c\u5b58\u50a8 PCIe I\/O \u8bbe\u5907\u63a5\u5165\u65f6&#xff0c;\u6839\u636e PCIe \u89c4\u8303\u6709\u4e24\u4e2a\u65b9\u6cd5&#xff1a;<\/p>\n<ul>\n<li>1\ufe0f\u20e3 \u901a\u8fc7\u591a\u7ea7 PCIe switch \u6269\u5c55&#xff0c;\u5b9e\u73b0\u5927\u91cf PCIe switch downstream port&#xff0c;\u7136\u540e\u6bcf\u4e2a PCIe switch downstream port \u6302\u8f7d\u4e00\u4e2a PCIe I\/O \u8bbe\u5907&#xff1b;<\/li>\n<li>2\ufe0f\u20e3 \u901a\u8fc7 PCIe SR-IOV \u6280\u672f&#xff0c;\u652f\u6301\u5927\u91cf PCIe virtual function&#xff08;VF&#xff09;\u8bbe\u5907\u3002<\/li>\n<\/ul>\n<p>&#x1f680; PCIe Switch Downstream Port \u662f\u6307 PCIe \u4ea4\u6362\u673a&#xff08;PCIe Switch&#xff09;\u4e0a \u8fde\u63a5\u4e0b\u6e38\u8bbe\u5907 \u7684\u7aef\u53e3\u3002 &#x1f680; PCIe Virtual Function&#xff08;VF&#xff0c;<font color=\"#e47542\">\u865a\u62df\u529f\u80fd<\/font>&#xff09; \u662f SR-IOV \u6280\u672f\u4e2d\u7684\u4e00\u4e2a\u6838\u5fc3\u6982\u5ff5\u3002\u5b83\u5141\u8bb8\u5c06\u4e00\u4e2a\u7269\u7406 PCIe \u8bbe\u5907&#xff08;\u5982\u7f51\u5361\u6216\u5b58\u50a8\u63a7\u5236\u5668&#xff09;\u865a\u62df\u5316\u4e3a\u591a\u4e2a\u72ec\u7acb\u7684\u865a\u62df\u8bbe\u5907&#xff0c;\u6bcf\u4e2a\u865a\u62df\u8bbe\u5907\u53ef\u4ee5\u76f4\u63a5\u5206\u914d\u7ed9\u4e00\u4e2a\u865a\u62df\u673a&#xff08;VM&#xff09;\u4f7f\u7528&#xff0c;\u4ece\u800c\u5b9e\u73b0\u786c\u4ef6\u8d44\u6e90\u7684\u9ad8\u6548\u5171\u4eab\u548c\u6027\u80fd\u4f18\u5316\u3002<\/p>\n<p>\u8fdb\u4e00\u6b65\u5bf9\u6bd4\u865a\u62df\u673a I\/O \u8bbe\u5907&#xff0c;\u6211\u4eec\u53ef\u4ee5\u770b\u5230 <font color=\"#e47542\">\u8bbe\u5907\u7684\u70ed\u63d2\u62d4<\/font>\u3001<font color=\"#e47542\">Guest OS \u7684\u96f6\u4fb5\u5165<\/font> \u662f\u516c\u5171\u4e91 IaaS \u4ea7\u54c1\u7684\u521a\u9700\u3002\u53ea\u6709\u901a\u8fc7\u591a\u7ea7 PCIe switch \u6269\u5c55\u6a21\u5f0f&#xff0c;\u624d\u80fd\u901a\u8fc7 PCIe native hotplug \u6280\u672f\u6807\u51c6&#xff0c;\u5b9e\u73b0\u4e0a\u8ff0\u548c\u865a\u62df\u673a\u4e00\u81f4\u7684\u8bbe\u5907\u70ed\u63d2\u62d4\u548c Guest OS \u96f6\u4fb5\u5165\u3002<\/p>\n<p>&#x1f680; PCIe Native Hotplug \u662f\u6307 PCIe \u8bbe\u5907\u5728\u4e0d\u5173\u95ed\u7cfb\u7edf\u7535\u6e90\u7684\u60c5\u51b5\u4e0b&#xff0c;\u80fd\u591f\u88ab\u5b89\u5168\u5730\u63d2\u5165\u6216\u79fb\u9664 \u7684\u529f\u80fd\u3002\u8fd9\u79cd\u529f\u80fd\u5141\u8bb8\u7528\u6237\u6216\u7ba1\u7406\u5458\u5728\u7cfb\u7edf\u8fd0\u884c\u65f6\u52a8\u6001\u6dfb\u52a0\u6216\u79fb\u9664 PCIe \u8bbe\u5907&#xff08;\u5982\u663e\u5361\u3001\u7f51\u5361\u3001NVMe SSD \u7b49&#xff09;&#xff0c;\u800c\u65e0\u9700\u91cd\u542f\u7cfb\u7edf\u3002<\/p>\n<p>\u4ea7\u54c1\u9700\u6c42\u660e\u786e\u540e&#xff0c;\u6211\u4eec\u521b\u65b0\u6027\u5730\u901a\u8fc7\u82af\u7247 RTL \u5b9e\u73b0\u4e86\u5168\u7403\u7b2c\u4e00\u4e2a\u7247\u4e0a\u591a\u7ea7 PCIe switch \u6269\u5c55&#xff0c;\u5f53\u524d\u6700\u591a\u80fd\u591f\u652f\u6301 63 \u4e2a\u8bbe\u5907&#xff0c;\u4ee5\u6b64\u5b9e\u73b0\u5927\u6570\u91cf\u89c4\u683c\u7684\u7f51\u7edc ENI \u548c\u5b58\u50a8 EBS \u4e91\u76d8 PCIe I\/O \u8bbe\u5907\u63a5\u5165&#xff1b;\u540c\u65f6\u7531\u4e8e\u652f\u6301\u539f\u751f PCIe \u539f\u751f\u70ed\u63d2\u62d4\u80fd\u529b&#xff0c;\u4fdd\u8bc1\u4e86 Guest OS \u7684\u96f6\u4fb5\u5165&#xff0c;\u4ee5\u53ca\u5ba2\u6237\u5728 Open API \u548c\u63a7\u5236\u53f0\u7b49\u65b9\u9762\u548c\u865a\u62df\u673a\u4e00\u81f4\u7684\u4f7f\u7528\u4f53\u9a8c\u3002<\/p>\n<h2>3.X-Dragon Hypervisor \u57fa\u4e8e\u795e\u9f99\u7684\u8f6f\u786c\u4e00\u4f53\u7684\u865a\u62df\u5316\u6280\u672f<\/h2>\n<p>\u5728\u963f\u91cc\u4e91\u795e\u9f99\u786c\u4ef6\u5e73\u53f0\u4e0b&#xff0c;\u865a\u62df\u5316\u67b6\u6784\u4e5f\u505a\u4e86\u76f8\u5e94\u7684\u5347\u7ea7&#xff0c;\u4f7f\u8ba1\u7b97\u865a\u62df\u5316\u90e8\u5206\u7684\u67b6\u6784\u66f4\u52a0\u6e05\u6670\u7b80\u6377&#xff0c;\u8ba9\u865a\u62df\u673a\u80fd\u63d0\u4f9b\u63a5\u8fd1\u7269\u7406\u673a\u7684\u6027\u80fd\u3002\u5982\u4e0b\u56fe\u6240\u793a&#xff0c;\u795e\u9f99\u865a\u62df\u5316\u67b6\u6784\u7684\u4e3b\u8981\u7279\u70b9\u662f&#xff1a;<\/p>\n<ul>\n<li>1\ufe0f\u20e3 I\/O \u94fe\u8def\u4ece\u4f20\u7edf\u7684\u901a\u8fc7\u8f6f\u4ef6\u5b9e\u73b0\u8f6c\u53d8\u4e3a\u901a\u8fc7\u786c\u4ef6\u548c\u76f4\u901a\u8bbe\u5907\u5b9e\u73b0&#xff1b;<\/li>\n<li>2\ufe0f\u20e3 \u5b58\u50a8\u865a\u62df\u5316\u3001\u7f51\u7edc\u865a\u62df\u5316\u90fd\u5728 MOC \u5361\u4e0a\u5b9e\u73b0&#xff1b;<\/li>\n<li>3\ufe0f\u20e3 \u540c\u65f6\u5c06\u7ba1\u63a7\u7cfb\u7edf\u3001\u76d1\u63a7\u7a0b\u5e8f\u7b49\u90fd\u4e0b\u6c89\u5230 MOC \u5361\u4e0a\u3002<\/li>\n<li>4\ufe0f\u20e3 \u5728\u63d0\u4f9b\u8ba1\u7b97\u670d\u52a1\u7684\u7269\u7406\u673a\u4e0a&#xff0c;\u53ea\u8fd0\u884c\u81ea\u5df1\u88c1\u526a\u7684 Linux \u64cd\u4f5c\u7cfb\u7edf\u548c\u8f7b\u91cf\u5316\u7684\u865a\u62df\u673a\u76d1\u63a7\u5668\u3002<\/li>\n<\/ul>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/04\/20250418203143-6802b6afb8cd8.png\" alt=\"\u5728\u8fd9\u91cc\u63d2\u5165\u56fe\u7247\u63cf\u8ff0\" \/> \u795e\u9f99\u865a\u62df\u5316\u67b6\u6784\u6bd4\u8d77\u4f20\u7edf\u7684 KVM \u865a\u62df\u5316\u7684\u5173\u952e\u4f18\u5316\u6280\u672f\u70b9\u7b80\u8981\u63cf\u8ff0\u5982\u4e0b\u3002<\/p>\n<h3>3.1 \u81ea\u7814\u865a\u62df CPU \u8c03\u5ea6\u5668 \u2014\u2014 VOS<\/h3>\n<p>VOS&#xff08;VM-Oriented Scheduler&#xff09;\u662f\u9762\u5411\u865a\u62df\u673a\u7684\u8c03\u5ea6\u5668&#xff0c;\u662f\u963f\u91cc\u4e91\u5728\u795e\u9f99\u5e73\u53f0\u4e0a\u81ea\u7814\u7684\u8c03\u5ea6\u5668&#xff0c;\u51cf\u5c11\u4e86\u865a\u62df CPU \u8c03\u5ea6\u5f00\u9500&#xff0c;\u540c\u65f6\u5c06\u5176\u4ed6\u63a7\u5236\u9762\u7684\u4f5c\u4e1a\u8c03\u5ea6\u7ed9\u865a\u62df CPU \u5e26\u6765\u7684\u4e89\u62a2\u4e0b\u964d\u4e00\u4e2a\u6570\u91cf\u7ea7\u7814\u53d1\u7684\u66f4\u52a0\u7a33\u5b9a\u548c\u9ad8\u6548\u7684\u8ba1\u7b97\u865a\u62df\u5316\u4ea7\u54c1\u3002\u5982\u4e0b\u56fe\u6240\u793a&#xff0c;VOS \u8c03\u5ea6\u5668\u5b9e\u73b0\u7684\u662f\u975e\u516c\u5e73\u8c03\u5ea6&#xff08;\u4e0e\u5185\u6838\u4e2d\u7684 CFS \u8c03\u5ea6\u5668\u4e0d\u540c&#xff09;&#xff0c;\u8ba9\u865a\u62df CPU \u7ebf\u7a0b\u5177\u6709\u66f4\u9ad8\u6267\u884c\u4f18\u5148\u7ea7&#xff0c;\u4fdd\u8bc1\u5ba2\u6237\u8d2d\u4e70\u7684\u865a\u62df\u673a\u7684\u8ba1\u7b97\u6027\u80fd&#xff0c;\u800c\u63a7\u5236\u9762\u7684\u4f5c\u4e1a\u8c03\u5ea6\u6267\u884c\u88ab\u5b89\u6392\u5728\u9884\u5148\u8bbe\u5b9a\u7684\u4e00\u4e2a\u8f83\u4f4e\u4f18\u5148\u7ea7\u548c\u9884\u8bbe\u65f6\u95f4\u7247\u4e2d\u6295\u673a\u6267\u884c&#xff0c;\u800c\u4e14\u63a7\u5236\u9762\u7684\u4f5c\u4e1a\u662f\u53ef\u4ee5\u88ab\u5185\u6838\u6001\u62a2\u5360\u7684\u3002 <img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/04\/20250418203144-6802b6b033e93.png\" alt=\"\u5728\u8fd9\u91cc\u63d2\u5165\u56fe\u7247\u63cf\u8ff0\" \/> \u901a\u8fc7 VOS \u8c03\u5ea6\u5668&#xff0c;\u865a\u62df CPU \u7684\u8c03\u5ea6\u5ef6\u8fdf\u4f4e\u5230\u6beb\u79d2\u7ea7&#xff1b;\u901a\u8fc7 ping flood \u6765\u6d4b\u8bd5\u7f51\u7edc ping \u7684\u5ef6\u65f6\u6296\u52a8&#xff0c;\u6296\u52a8\u4e0b\u964d\u5230\u4e86\u767e\u4e07\u5206\u4e4b\u4e00\u5de6\u53f3&#xff08;\u5373 ping \u4e00\u767e\u4e07\u4e2a\u62a5\u6587\u53ea\u9047\u5230 1 \u4e2a\u62a5\u6587\u5ef6\u8fdf\u7684\u6bd4\u4f8b\u6bd4\u5747\u503c\u660e\u663e\u504f\u5927&#xff09;&#xff0c;\u6296\u52a8\u6bd4\u4e4b\u524d\u7684\u67b6\u6784\u4e0b\u964d\u4e86\u4e24\u4e2a\u6570\u91cf\u7ea7\u3002\u5728\u7269\u7406\u673a\u4e0a\u6267\u884c\u7684\u63a7\u5236\u9762\u7684\u4f5c\u4e1a\u5305\u62ec&#xff1a;\u865a\u62df\u673a\u751f\u547d\u5468\u671f\u7ba1\u7406\u3001QEMU \u63a7\u5236\u7ebf\u7a0b\u3001\u5199\u65e5\u5fd7\u3001\u76d1\u63a7\u6267\u884c\u3001\u5305\u62ec\u70ed\u5347\u7ea7 \/ \u70ed\u8fc1\u79fb\u5728\u5185\u7684\u8fd0\u7ef4\u64cd\u4f5c&#xff0c;\u5728 VOS \u7684\u7ba1\u7406\u4e0b&#xff0c;\u6b63\u5728\u8fd0\u884c\u7684\u865a\u62df CPU \u7684\u5e72\u6270\u88ab\u63a7\u5236\u5728\u4e00\u4e2a\u975e\u5e38\u4f4e\u7684\u6c34\u5e73&#xff0c;\u865a\u62df\u673a\u7684\u8ba1\u7b97\u7a33\u5b9a\u6027\u5927\u5e45\u63d0\u5347\u3002<\/p>\n<h3>3.2 \u5185\u5b58\u4f18\u5316&#xff1a;\u5185\u5b58\u5206\u914d\u5668 VMEM \u4e0e\u7528\u6237\u6001 QEMU \u5185\u5b58\u7626\u8eab<\/h3>\n<p>\u5185\u5b58\u5206\u914d\u5668 VMEM \u662f\u963f\u91cc\u4e91\u7814\u53d1\u7684\u7528\u4e8e\u865a\u62df\u673a\u5185\u5b58\u5206\u914d\u7684\u5206\u914d\u5668&#xff0c;\u53ef\u4ee5\u5927\u5e45\u51cf\u5c11\u5185\u6838\u7ef4\u62a4\u7684\u5185\u5b58\u9875\u8868\u7b49\u5f00\u9500&#xff08;\u5f00\u9500\u4ece\u4ee5\u524d\u7684 <span class=\"katex--inline\"><span class=\"katex\"><span class=\"katex-mathml\"> <\/p>\n<p>         1.5 <\/p>\n<p>         % <\/p>\n<p>        1.5\\\\% <\/p>\n<p>    <\/span><span class=\"katex-html\"><span class=\"base\"><span class=\"strut\" style=\"height: 0.8056em;vertical-align: -0.0556em\"><\/span><span class=\"mord\">1.5%<\/span><\/span><\/span><\/span><\/span> \u5de6\u53f3\u4e0b\u964d\u5230 <span class=\"katex--inline\"><span class=\"katex\"><span class=\"katex-mathml\"> <\/p>\n<p>         0.1 <\/p>\n<p>         % <\/p>\n<p>        0.1\\\\% <\/p>\n<p>    <\/span><span class=\"katex-html\"><span class=\"base\"><span class=\"strut\" style=\"height: 0.8056em;vertical-align: -0.0556em\"><\/span><span class=\"mord\">0.1%<\/span><\/span><\/span><\/span><\/span> \u5de6\u53f3&#xff09;&#xff0c;\u652f\u6301 1GB \u7684\u5927\u9875\u8fdb\u4e00\u6b65\u51cf\u5c11 EPT \u5f00\u9500&#xff0c;\u5b9e\u73b0\u4e86\u901a\u8fc7 vMCE \u5bf9\u786c\u4ef6\u9519\u8bef\u7684\u5185\u5b58\u9875\u8fdb\u884c\u9694\u79bb\u3002<\/p>\n<p>\u5728\u5185\u5b58\u65b9\u9762&#xff0c;\u6211\u4eec\u901a\u8fc7 QEMU \u5bf9\u5176\u8fdb\u884c\u7626\u8eab&#xff0c;\u5c06\u5355\u4e2a\u865a\u62df\u673a\u7684 QEMU \u8fdb\u7a0b\u5185\u5b58\u5f00\u9500\u964d\u4f4e\u5230 5MB \u4ee5\u5185&#xff0c;\u901a\u8fc7\u5168\u65b0\u8bbe\u8ba1\u7684\u7528\u6237\u6001\u5185\u5b58\u5206\u914d\u5668\u907f\u514d\u4e86\u5185\u5b58\u788e\u7247&#xff0c;\u540c\u65f6\u5bf9\u4e0d\u5e38\u7528\u7684\u5185\u5b58\u8d44\u6e90\u8fdb\u884c\u5ef6\u8fdf\u5206\u914d\u3002<\/p>\n<p>\u901a\u8fc7\u8fd9\u4e24\u79cd\u5185\u5b58\u4f18\u5316\u624b\u6bb5&#xff0c;\u795e\u9f99\u865a\u62df\u5316\u7684\u67b6\u6784\u6bd4\u4f20\u7edf KVM \u865a\u62df\u5316\u8282\u7701\u4e86\u7ea6 10%\u7684\u5185\u5b58\u3002<\/p>\n<h3>3.3 \u865a\u62df\u5316\u8fd0\u884c\u52a0\u901f<\/h3>\n<p>\u901a\u8fc7\u786c\u4ef6\u52a0\u901f\u865a\u62df\u673a\u4e2d\u7684 HLT \u548c MWAIT \u6307\u4ee4&#xff0c;\u4f7f\u5176\u5524\u9192\u5ef6\u8fdf\u4e0e\u7269\u7406\u673a\u51e0\u4e4e\u4e00\u6837\u3002\u540c\u65f6\u5c06\u5b9a\u65f6\u5668\u8fdb\u884c\u786c\u4ef6\u865a\u62df\u5316&#xff0c;\u5728\u865a\u62df\u673a\u4e2d\u8bbf\u95ee\u5b9a\u65f6\u5668\u4e0d\u4f1a\u518d\u89e6\u53d1 VMEXIT&#xff0c;\u4ece\u800c\u63d0\u5347\u865a\u62df\u673a\u6027\u80fd\u3002\u901a\u8fc7\u8fd9\u4e9b\u4f18\u5316&#xff0c;\u8fdb\u7a0b\u8c03\u5ea6\u6027\u80fd\u5f97\u5230\u4e86\u8f83\u5927\u63d0\u9ad8&#xff0c;\u4e0b\u56fe\u7684\u8c03\u5ea6\u5ef6\u8fdf\u5b9e\u6d4b\u6570\u636e\u5c55\u793a\u7684\u662f\u5728\u67d0\u6b21\u6d4b\u8bd5\u4e2d&#xff0c;\u8c03\u5ea6\u4e24\u767e\u4e07\u4e2a\u8fdb\u7a0b&#xff0c;\u5e76\u7edf\u8ba1\u6bcf\u6b21\u8c03\u5ea6\u7684\u5ef6\u8fdf\u7684\u7ed3\u679c\u3002\u53ef\u4ee5\u770b\u5230&#xff0c;\u5ef6\u8fdf\u6709 <span class=\"katex--inline\"><span class=\"katex\"><span class=\"katex-mathml\"> <\/p>\n<p>         15 <\/p>\n<p>         % <\/p>\n<p>        15\\\\% <\/p>\n<p>    <\/span><span class=\"katex-html\"><span class=\"base\"><span class=\"strut\" style=\"height: 0.8056em;vertical-align: -0.0556em\"><\/span><span class=\"mord\">15%<\/span><\/span><\/span><\/span><\/span> \u7684\u4e0b\u964d\u3002\u56fe\u4e2d\u7684 g5.4xlarge \u5b9e\u4f8b\u662f\u4e4b\u524d\u7684 KVM \u67b6\u6784\u7684 ECS \u865a\u62df\u673a\u5b9e\u4f8b\u89c4\u683c&#xff0c;g6.4xlarge \u662f\u795e\u9f99\u786c\u4ef6\u5e73\u53f0\u4e0b\u7ecf\u8fc7\u4f18\u5316\u7684 ECS \u865a\u62df\u673a\u5b9e\u4f8b\u89c4\u683c\u3002<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/04\/20250418203144-6802b6b0916d2.png\" alt=\"\u5728\u8fd9\u91cc\u63d2\u5165\u56fe\u7247\u63cf\u8ff0\" \/><\/p>\n<p>&#x1f680; HLT&#xff08;Halt&#xff09; \u548c MWAIT&#xff08;Monitor Wait&#xff09;\u662f x86 \u67b6\u6784\u4e2d\u7684\u4e24\u6761 CPU \u6307\u4ee4&#xff0c;\u7528\u4e8e\u7ba1\u7406\u5904\u7406\u5668\u7684\u529f\u8017\u548c\u72b6\u6001\u3002\u5b83\u4eec\u7684\u4e3b\u8981\u76ee\u7684\u662f\u5728 CPU \u7a7a\u95f2\u65f6\u964d\u4f4e\u529f\u8017&#xff0c;\u540c\u65f6\u4fdd\u6301\u5bf9\u4e8b\u4ef6\u7684\u5feb\u901f\u54cd\u5e94\u80fd\u529b\u3002<\/p>\n<h3>3.4 \u6781\u901f\u542f\u52a8<\/h3>\n<p>\u4e3a\u4e86\u8ba9\u865a\u62df\u673a\u52a0\u901f\u542f\u52a8&#xff0c;\u6211\u4eec\u5bf9\u795e\u9f99\u865a\u62df\u5316\u67b6\u6784\u4e5f\u505a\u4e86\u5f88\u591a\u4f18\u5316\u3002<\/p>\n<ul>\n<li>\u9996\u5148\u662f\u8d44\u6e90\u7684\u5feb\u901f\u5206\u914d&#xff0c;\u5305\u62ec\u5b9e\u73b0\u591a\u7ebf\u7a0b\u7684\u521d\u59cb\u5316\u3001\u865a\u62df\u673a\u5185\u5b58\u9875\u5206\u914d\u65f6\u7684\u6279\u5904\u7406\u5316\u3002<\/li>\n<li>\u540c\u65f6\u5bf9\u865a\u62df\u673a\u4f9d\u8d56\u7684\u56fa\u4ef6\u8fdb\u884c\u88c1\u526a\u3001\u91cd\u6784\u3001\u4f18\u5316&#xff0c;\u4f7f\u865a\u62df\u673a\u5b9e\u73b0\u6beb\u79d2\u7ea7\u52a0\u8f7d\u3002<\/li>\n<li>\u6211\u4eec\u8fd8\u5bf9\u4e00\u4e9b\u7279\u6b8a\u7684\u5e94\u7528\u573a\u666f\u5e94\u7528\u4e86\u5185\u90e8\u79f0\u4e3a vmfork \u7684\u6280\u672f&#xff0c;\u8ba9\u865a\u62df\u673a\u80fd\u5b9e\u73b0\u79d2\u7ea7\u7684\u5feb\u901f\u590d\u5236\u3002<\/li>\n<\/ul>\n<h3>3.5 \u7269\u7406\u673a CPU \u5168\u4f9b\u7ed9\u865a\u62df\u673a<\/h3>\n<p>\u5728\u4f20\u7edf\u7684 KVM \u865a\u62df\u5316\u67b6\u6784\u4e0b&#xff0c;\u5bbf\u4e3b\u673a\u7684 CPU \u8d44\u6e90\u662f\u4e0d\u53ef\u80fd\u5168\u90e8\u4f9b\u7ed9\u865a\u62df\u673a\u4f7f\u7528\u7684&#xff0c;\u4e00\u822c\u8fd8\u8981\u9884\u7559 CPU \u6838&#xff0c;\u7528\u4e8e\u7f51\u7edc\u865a\u62df\u5316\u8f6f\u4ef6\u3001\u5b58\u50a8\u865a\u62df\u5316\u8f6f\u4ef6\u3001\u7ba1\u63a7\u7cfb\u7edf\u3001\u76d1\u63a7\u811a\u672c\u7b49\u7684\u8ba1\u7b97\u8d44\u6e90\u5f00\u9500\u3002<\/p>\n<p>\u5728\u795e\u9f99\u67b6\u6784\u4e0b&#xff0c;\u7f51\u7edc\u865a\u62df\u5316\u548c\u5b58\u50a8\u865a\u62df\u5316\u90fd\u901a\u8fc7\u786c\u4ef6\u865a\u62df\u5316\u7684\u65b9\u5f0f\u4e0b\u6c89\u5230\u4e00\u5f20 MOC \u5361\u4e0a&#xff0c;\u540c\u65f6\u7ba1\u63a7\u7cfb\u7edf\u548c\u7edd\u5927\u90e8\u5206\u76d1\u63a7\u811a\u672c\u90fd\u4e0b\u6c89\u5230 MOC \u5361\u4e0a\u8fd0\u884c&#xff0c;\u8fd9\u6837\u7269\u7406\u673a CPU \u8d44\u6e90\u5c31\u53ef\u4ee5\u5168\u90e8\u901a\u8fc7\u865a\u62df\u5316\u7684\u65b9\u5f0f\u5206\u914d\u7ed9\u865a\u62df\u673a\u4f7f\u7528\u3002\u7ecf\u8fc7\u8bc4\u4f30&#xff0c;\u901a\u8fc7\u4e0b\u6c89\u8fd9\u90e8\u5206 CPU \u5f00\u9500\u5230 MOC \u5361\u4e0a&#xff0c;\u7269\u7406\u673a\u7684 CPU \u8d44\u6e90\u5229\u7528\u7387\u80fd\u63d0\u9ad8 <span class=\"katex--inline\"><span class=\"katex\"><span class=\"katex-mathml\"> <\/p>\n<p>         10 <\/p>\n<p>         % <\/p>\n<p>        10\\\\% <\/p>\n<p>    <\/span><span class=\"katex-html\"><span class=\"base\"><span class=\"strut\" style=\"height: 0.8056em;vertical-align: -0.0556em\"><\/span><span class=\"mord\">10%<\/span><\/span><\/span><\/span><\/span> \u5de6\u53f3\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb951\u6b21\uff0c\u70b9\u8d5e29\u6b21\uff0c\u6536\u85cf24\u6b21\u30022003 \u5e74\uff0cXen \u5728 SOSP \u53d1\u8868 Xen and the Art of Virtualization\uff0c\u62c9\u5f00\u4e86 x86 \u5e73\u53f0\u865a\u62df\u5316\u6280\u672f\u7684\u5927\u5e55\u30022006 \u5e74\uff0cAWS \u53d1\u5e03 EC2\uff08Elastic Compute Cloud\uff09\uff0c\u540c\u5e74\u53d1\u5e03 S3\uff08Simple Storage Service\uff09\uff0c\u62c9\u5f00\u4e86\u516c\u5171\u4e91\u670d\u52a1\u7684\u5927\u5e55\u3002EC2 \u7684\u6838\u5fc3\u6b63\u662f\u57fa\u4e8e Xen \u865a\u62df\u5316\u6280\u672f\u3002\u865a\u62df\u5316\u6280\u672f\u8d4b\u4e88\u4e86 EC2 \u6838\u5fc3\u4ea7\u54c1\u4ef7\u503c \u2014\u2014 \u5f39\u6027\uff0c\u540c\u65f6\u865a\u62df\u5316\u6280\u672f\u7ed9\u7f51\u7edc\u865a\u62df\u5316\u3001\u5b58\u50a8\u865a\u62df\u5316\uff0c\u548c\u7ba1\u63a7\u7cfb\u7edf\u63d0\u4f9b\u4e86\u4e1a\u52a1\u90e8\u7f72\u70b9\u3002_\u795e\u9f99\u865a\u62df\u5316<\/p>\n","protected":false},"author":2,"featured_media":21388,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[673,97,1652,194,263,1651],"topic":[],"class_list":["post-21392","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-server","tag-kvm","tag-97","tag-1652","tag-194","tag-263","tag-1651"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>\u3010\u5f39\u6027\u8ba1\u7b97\u3011\u5f39\u6027\u88f8\u91d1\u5c5e\u670d\u52a1\u5668\u548c\u795e\u9f99\u865a\u62df\u5316\uff08\u4e09\uff09\uff1a\u5f39\u6027\u88f8\u91d1\u5c5e\u6280\u672f - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.wsisp.com\/helps\/21392.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u3010\u5f39\u6027\u8ba1\u7b97\u3011\u5f39\u6027\u88f8\u91d1\u5c5e\u670d\u52a1\u5668\u548c\u795e\u9f99\u865a\u62df\u5316\uff08\u4e09\uff09\uff1a\u5f39\u6027\u88f8\u91d1\u5c5e\u6280\u672f - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb951\u6b21\uff0c\u70b9\u8d5e29\u6b21\uff0c\u6536\u85cf24\u6b21\u30022003 \u5e74\uff0cXen \u5728 SOSP \u53d1\u8868 Xen and the Art of Virtualization\uff0c\u62c9\u5f00\u4e86 x86 \u5e73\u53f0\u865a\u62df\u5316\u6280\u672f\u7684\u5927\u5e55\u30022006 \u5e74\uff0cAWS \u53d1\u5e03 EC2\uff08Elastic Compute Cloud\uff09\uff0c\u540c\u5e74\u53d1\u5e03 S3\uff08Simple Storage Service\uff09\uff0c\u62c9\u5f00\u4e86\u516c\u5171\u4e91\u670d\u52a1\u7684\u5927\u5e55\u3002EC2 \u7684\u6838\u5fc3\u6b63\u662f\u57fa\u4e8e Xen \u865a\u62df\u5316\u6280\u672f\u3002\u865a\u62df\u5316\u6280\u672f\u8d4b\u4e88\u4e86 EC2 \u6838\u5fc3\u4ea7\u54c1\u4ef7\u503c \u2014\u2014 \u5f39\u6027\uff0c\u540c\u65f6\u865a\u62df\u5316\u6280\u672f\u7ed9\u7f51\u7edc\u865a\u62df\u5316\u3001\u5b58\u50a8\u865a\u62df\u5316\uff0c\u548c\u7ba1\u63a7\u7cfb\u7edf\u63d0\u4f9b\u4e86\u4e1a\u52a1\u90e8\u7f72\u70b9\u3002_\u795e\u9f99\u865a\u62df\u5316\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/21392.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2025-04-18T20:31:45+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/04\/20250418203143-6802b6af69421.png\" \/>\n<meta name=\"author\" content=\"admin\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u4f5c\u8005\" \/>\n\t<meta name=\"twitter:data1\" content=\"admin\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4\" \/>\n\t<meta name=\"twitter:data2\" content=\"5 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/21392.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/21392.html\",\"name\":\"\u3010\u5f39\u6027\u8ba1\u7b97\u3011\u5f39\u6027\u88f8\u91d1\u5c5e\u670d\u52a1\u5668\u548c\u795e\u9f99\u865a\u62df\u5316\uff08\u4e09\uff09\uff1a\u5f39\u6027\u88f8\u91d1\u5c5e\u6280\u672f - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2025-04-18T20:31:45+00:00\",\"dateModified\":\"2025-04-18T20:31:45+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/21392.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/21392.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/21392.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"\u3010\u5f39\u6027\u8ba1\u7b97\u3011\u5f39\u6027\u88f8\u91d1\u5c5e\u670d\u52a1\u5668\u548c\u795e\u9f99\u865a\u62df\u5316\uff08\u4e09\uff09\uff1a\u5f39\u6027\u88f8\u91d1\u5c5e\u6280\u672f\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\",\"url\":\"https:\/\/www.wsisp.com\/helps\/\",\"name\":\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"description\":\"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-Hans\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\",\"name\":\"admin\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"zh-Hans\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"contentUrl\":\"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery\",\"caption\":\"admin\"},\"sameAs\":[\"http:\/\/wp.wsisp.com\"],\"url\":\"https:\/\/www.wsisp.com\/helps\/author\/admin\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"\u3010\u5f39\u6027\u8ba1\u7b97\u3011\u5f39\u6027\u88f8\u91d1\u5c5e\u670d\u52a1\u5668\u548c\u795e\u9f99\u865a\u62df\u5316\uff08\u4e09\uff09\uff1a\u5f39\u6027\u88f8\u91d1\u5c5e\u6280\u672f - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.wsisp.com\/helps\/21392.html","og_locale":"zh_CN","og_type":"article","og_title":"\u3010\u5f39\u6027\u8ba1\u7b97\u3011\u5f39\u6027\u88f8\u91d1\u5c5e\u670d\u52a1\u5668\u548c\u795e\u9f99\u865a\u62df\u5316\uff08\u4e09\uff09\uff1a\u5f39\u6027\u88f8\u91d1\u5c5e\u6280\u672f - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"\u6587\u7ae0\u6d4f\u89c8\u9605\u8bfb951\u6b21\uff0c\u70b9\u8d5e29\u6b21\uff0c\u6536\u85cf24\u6b21\u30022003 \u5e74\uff0cXen \u5728 SOSP \u53d1\u8868 Xen and the Art of Virtualization\uff0c\u62c9\u5f00\u4e86 x86 \u5e73\u53f0\u865a\u62df\u5316\u6280\u672f\u7684\u5927\u5e55\u30022006 \u5e74\uff0cAWS \u53d1\u5e03 EC2\uff08Elastic Compute Cloud\uff09\uff0c\u540c\u5e74\u53d1\u5e03 S3\uff08Simple Storage Service\uff09\uff0c\u62c9\u5f00\u4e86\u516c\u5171\u4e91\u670d\u52a1\u7684\u5927\u5e55\u3002EC2 \u7684\u6838\u5fc3\u6b63\u662f\u57fa\u4e8e Xen \u865a\u62df\u5316\u6280\u672f\u3002\u865a\u62df\u5316\u6280\u672f\u8d4b\u4e88\u4e86 EC2 \u6838\u5fc3\u4ea7\u54c1\u4ef7\u503c \u2014\u2014 \u5f39\u6027\uff0c\u540c\u65f6\u865a\u62df\u5316\u6280\u672f\u7ed9\u7f51\u7edc\u865a\u62df\u5316\u3001\u5b58\u50a8\u865a\u62df\u5316\uff0c\u548c\u7ba1\u63a7\u7cfb\u7edf\u63d0\u4f9b\u4e86\u4e1a\u52a1\u90e8\u7f72\u70b9\u3002_\u795e\u9f99\u865a\u62df\u5316","og_url":"https:\/\/www.wsisp.com\/helps\/21392.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2025-04-18T20:31:45+00:00","og_image":[{"url":"https:\/\/www.wsisp.com\/helps\/wp-content\/uploads\/2025\/04\/20250418203143-6802b6af69421.png"}],"author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"5 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/21392.html","url":"https:\/\/www.wsisp.com\/helps\/21392.html","name":"\u3010\u5f39\u6027\u8ba1\u7b97\u3011\u5f39\u6027\u88f8\u91d1\u5c5e\u670d\u52a1\u5668\u548c\u795e\u9f99\u865a\u62df\u5316\uff08\u4e09\uff09\uff1a\u5f39\u6027\u88f8\u91d1\u5c5e\u6280\u672f - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2025-04-18T20:31:45+00:00","dateModified":"2025-04-18T20:31:45+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/21392.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/21392.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/21392.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"\u3010\u5f39\u6027\u8ba1\u7b97\u3011\u5f39\u6027\u88f8\u91d1\u5c5e\u670d\u52a1\u5668\u548c\u795e\u9f99\u865a\u62df\u5316\uff08\u4e09\uff09\uff1a\u5f39\u6027\u88f8\u91d1\u5c5e\u6280\u672f"}]},{"@type":"WebSite","@id":"https:\/\/www.wsisp.com\/helps\/#website","url":"https:\/\/www.wsisp.com\/helps\/","name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","description":"\u9999\u6e2f\u670d\u52a1\u5668_\u9999\u6e2f\u4e91\u670d\u52a1\u5668\u8d44\u8baf_\u670d\u52a1\u5668\u5e2e\u52a9\u6587\u6863_\u670d\u52a1\u5668\u6559\u7a0b","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wsisp.com\/helps\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"zh-Hans"},{"@type":"Person","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41","name":"admin","image":{"@type":"ImageObject","inLanguage":"zh-Hans","@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/image\/","url":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","contentUrl":"https:\/\/gravatar.wp-china-yes.net\/avatar\/?s=96&d=mystery","caption":"admin"},"sameAs":["http:\/\/wp.wsisp.com"],"url":"https:\/\/www.wsisp.com\/helps\/author\/admin"}]}},"_links":{"self":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/21392","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/comments?post=21392"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/21392\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media\/21388"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=21392"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=21392"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=21392"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=21392"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}