{"id":2838,"date":"2011-04-03T19:26:56","date_gmt":"2011-04-03T11:26:56","guid":{"rendered":"http:\/\/edsionte.com\/techblog\/?p=2838"},"modified":"2011-09-26T20:04:58","modified_gmt":"2011-09-26T12:04:58","slug":"linux2-6%e8%bf%9b%e7%a8%8b%e8%b0%83%e5%ba%a6%e5%88%86%e6%9e%901-%e5%9f%ba%e6%9c%ac%e5%8e%9f%e7%90%86","status":"publish","type":"post","link":"http:\/\/edsionte.com\/techblog\/archives\/2838","title":{"rendered":"Linux2.6\u8fdb\u7a0b\u8c03\u5ea6\u5206\u6790(1)-\u8c03\u5ea6\u7b56\u7565"},"content":{"rendered":"<p>\u5bf9\u4e8e\u5206\u65f6\u64cd\u4f5c\u7cfb\u7edf\u800c\u8a00\uff0c\u8868\u9762\u4e0a\u770b\u8d77\u6765\u662f\u591a\u4e2a\u8fdb\u7a0b\u540c\u65f6\u5728\u6267\u884c\uff0c\u800c\u5728\u7cfb\u7edf\u5185\u90e8\u5219\u8fdb\u884c\u7740\u4ece\u4e00\u4e2a\u8fdb\u7a0b\u5230\u53e6\u4e00\u4e2a\u8fdb\u7a0b\u7684\u5207\u6362\u52a8\u4f5c\u3002\u8fd9\u6837\u7684\u8fdb\u7a0b\u5e76\u53d1\u6267\u884c\u6d89\u53ca\u5230\u8fdb\u7a0b\u5207\u6362\uff08process switch\uff09\u548c\u8fdb\u7a0b\u8c03\u5ea6\uff08process scheduling\uff09\u4e24\u5927\u95ee\u9898\u3002\u672c\u6587\u4e3b\u8981\u8bf4\u660eLinux2.6\u4e2d\u7684<strong>\u666e\u901a\u8fdb\u7a0b<\/strong>\u8c03\u5ea6\u7b56\u7565\uff08\u5b9e\u65f6\u8fdb\u7a0b\u548c\u666e\u901a\u8fdb\u7a0b\u5728\u8c03\u5ea6\u4e0a\u7a0d\u6709\u4e0d\u540c\uff09\u95ee\u9898\uff0c\u5373\u7cfb\u7edf\u4f55\u65f6\u8fdb\u884c\u8fdb\u7a0b\u5207\u6362\u4ee5\u53ca\u9009\u62e9\u54ea\u4e00\u4e2a\u8fdb\u7a0b\u8fdb\u884c\u5207\u6362\u3002<\/p>\n<h3>1.\u8c03\u5ea6\u7b56\u7565<\/h3>\n<p>\u7406\u60f3\u7684\u8fdb\u7a0b\u8c03\u5ea6\u76ee\u6807\u5e94\u8be5\u662f\uff1a\u8fdb\u7a0b\u54cd\u5e94\u65f6\u95f4\u5c3d\u53ef\u80fd\u7684\u5feb\uff0c\u540e\u53f0\u4f5c\u4e1a\u541e\u5410\u91cf\u9ad8\uff0c\u907f\u514d\u67d0\u4e9b\u8fdb\u7a0b\u51fa\u73b0\u9965\u997f\u73b0\u8c61\uff0c\u5305\u62ec\u4f4e\u4f18\u5148\u7ea7\u5728\u5185\u7684\u6240\u6709\u8fdb\u7a0b\u90fd\u6709\u88ab\u8c03\u5ea6\u7684\u53ef\u80fd\u3002\u7531\u6b64\u770b\u6765\uff0c\u8fdb\u7a0b\u8c03\u5ea6\u7684\u5de5\u4f5c\u5c31\u662f\u8981\u5904\u7406\u597d\u8fd9\u51e0\u4e2a\u65b9\u9762\u7684\u534f\u8c03\u5173\u7cfb\uff0c\u4f7f\u8fdb\u7a0b\u8c03\u5ea6\u7684\u7efc\u5408\u6027\u80fd\u8fbe\u5230\u6700\u4f73\u3002<\/p>\n<p>\u4e0e\u8fdb\u7a0b\u8c03\u5ea6\u6700\u4e3a\u5bc6\u5207\u7684\u56e0\u7d20\u662f\u8fdb\u7a0b\u7684\u4f18\u5148\u7ea7\uff0c\u8fdb\u7a0b\u4f18\u5148\u7ea7\u901a\u8fc7\u4e00\u4e2a\u6570\u503c\u6765\u5b9e\u73b0\uff0c\u6bcf\u4e2a\u8fdb\u7a0b\u90fd\u4e0e\u4e00\u4e2a\u503c\u76f8\u5173\u8054\u3002\u8c03\u5ea6\u7a0b\u5e8f\u6839\u636e\u8fdb\u7a0b\u7684\u4f18\u5148\u7ea7\u5c06CPU\u9002\u5f53\u7684\u5206\u914d\u7ed9\u67d0\u4e00\u4e2a\u8fdb\u7a0b\u3002\u8fdb\u7a0b\u7684\u4f18\u5148\u7ea7\u53c8\u8ddf\u8fdb\u7a0b\u7684\u8bb8\u591a\u56e0\u7d20\u6709\u5173\uff0c\u63a5\u4e0b\u6765\u6211\u4eec\u5c06\u4f9d\u6b21\u5206\u6790\u8fd9\u4e9b\u56e0\u7d20\u4e0e\u8fdb\u7a0b\u4f18\u5148\u7ea7\u7684\u5173\u7cfb\u3002<\/p>\n<h4>1.1\u8fdb\u7a0b\u7684\u5206\u7c7b<\/h4>\n<p>\u8fdb\u7a0b\u53ef\u4ee5\u88ab\u5206\u4e3a\u4e24\u79cd\u7c7b\u578b\uff1aI\/O\u6d88\u8017\u578b\u548cCPU\u6d88\u8017\u578b\u3002\u524d\u79cd\u7c7b\u578b\u7684\u8fdb\u7a0b\u9891\u7e41\u4f7f\u7528I\/O\u8bbe\u5907\uff0c\u5e76\u4e14\u5927\u90e8\u5206\u65f6\u95f4\u5904\u4e8e\u7b49\u5f85\u72b6\u6001\uff0c\u4ee5\u5f97\u5230\u65b0\u7684I\/O\u8bf7\u6c42\uff0c\u6bd4\u5982\u952e\u76d8\u6d3b\u52a8\u7b49\u3002\u540e\u4e00\u79cd\u7c7b\u578b\u7684\u8fdb\u7a0b\u5219\u5927\u90e8\u5206\u65f6\u95f4\u90fd\u5728\u5360\u7528CPU\uff0c\u5bf9I\/O\u8bbe\u5907\u5e76\u6ca1\u6709\u8fc7\u591a\u7684\u9700\u6c42\u3002<\/p>\n<p>\u4e3a\u4e86\u4f7f\u7cfb\u7edf\u6709\u8f83\u5f3a\u7684\u54cd\u5e94\u80fd\u529b\uff0cI\/O\u6d88\u8017\u578b\u8fdb\u7a0b\u5fc5\u987b\u5f88\u5feb\u80fd\u88ab\u5524\u9192\uff0c\u4ee5\u5b9e\u73b0\u8fdb\u7a0b\u7684\u5207\u6362\u3002\u5426\u5219\uff0c\u7528\u6237\u4f1a\u611f\u5230\u7cfb\u7edf\u53cd\u5e94\u8fdf\u949d\u3002\u5bf9\u4e8eCPU\u6d88\u8017\u578b\u8fdb\u7a0b\uff0c\u7531\u4e8e\u5b83\u4eec\u5e38\u5e38\u4f4d\u4e8e\u540e\u53f0\u8fd0\u884c\uff0c\u5e76\u4e14\u6ca1\u6709\u8fc7\u591a\u7684I\/O\u9700\u6c42\uff0c\u56e0\u6b64\u7cfb\u7edf\u5e76\u4e0d\u9700\u8981\u5bf9\u8fd9\u7c7b\u8fdb\u7a0b\u505a\u51fa\u5feb\u901f\u53cd\u5e94\u3002<\/p>\n<p>\u6b63\u5982\u4e0a\u9762\u6240\u8bf4\u7684\uff0c\u8c03\u5ea6\u7a0b\u5e8f\u901a\u5e38\u8981\u5904\u7406\u597d\u8fd9\u4e24\u7c7b\u8fdb\u7a0b\u4e4b\u95f4\u7684\u8c03\u5ea6\u5173\u7cfb\uff1a\u7cfb\u7edf\u65e2\u8981\u6709\u8fc5\u901f\u7684\u54cd\u5e94\u80fd\u529b\uff0c\u53c8\u8981\u6709\u6700\u5927\u7684CPU\u5229\u7528\u7387\uff08\u9ad8\u541e\u5410\u91cf\uff09\u3002\u8fd9\u79cd\u6ee1\u8db3\u5173\u7cfb\u5176\u5b9e\u662f\u77db\u76fe\u7684\uff0c\u5982\u679c\u7cfb\u7edf\u8981\u8fbe\u5230\u6700\u5927\u5229\u7528\u7387\uff0c\u90a3\u4e48CPU\u5c31\u4f1a\u88ab\u4e00\u76f4\u5360\u7528\uff0c\u8fd9\u6837\u5c31\u4e0d\u80fd\u5bf9I\/O\u8bf7\u6c42\u505a\u51fa\u8fc5\u901f\u54cd\u5e94\u3002\u8c03\u5ea6\u7a0b\u5e8f\u4e3a\u4e86\u8c03\u548c\u8fd9\u79cd\u51b2\u7a81\uff0c\u901a\u5e38\u4f1a\u503e\u5411\u4e8eI\/O\u6d88\u8017\u578b\u8fdb\u7a0b\u3002\u4e5f\u5c31\u662f\u8bf4\uff0c\u8c03\u5ea6\u7a0b\u5e8f\u4f1a\u4f18\u5148\u8c03\u7528\u8fd9\u7c7b\u8fdb\u7a0b\u4ee5\u63d0\u9ad8\u7cfb\u7edf\u7684\u54cd\u5e94\u80fd\u529b\uff0c\u800c\u5c3d\u91cf\u5c06CPU\u6d88\u8017\u578b\u8fdb\u7a0b\u538b\u540e\u6267\u884c\u3002\u4f46\u8fd9\u5e76\u4e0d\u610f\u5473\u7740\u8fd9\u7c7b\u8fdb\u7a0b\u5c31\u88ab\u8c03\u5ea6\u7a0b\u5e8f\u5ffd\u7565\u3002<\/p>\n<h4>1.2\u65f6\u95f4\u7247<\/h4>\n<p>Linux\u7684\u8c03\u5ea6\u662f\u57fa\u4e8e\u5206\u65f6\u6280\u672f\u7684\uff0c\u591a\u4e2a\u8fdb\u7a0b\u4ee5\u201c\u65f6\u95f4\u591a\u8def\u590d\u7528\u201d\u7684\u5f62\u5f0f\u8fd0\u884c\uff0cCPU\u7684\u65f6\u95f4\u88ab\u5212\u5206\u6210\u4e00\u5c0f\u6bb5\uff0c\u5373\u6240\u8c13\u7684\u65f6\u95f4\u7247\uff08slice\uff09\u3002\u6bcf\u4e2a\u8fdb\u7a0b\u90fd\u4f1a\u5f97\u5230\u4e00\u4e2a\u65f6\u95f4\u7247\uff0c\u5728\u5177\u4f53\u67d0\u4e2a\u65f6\u95f4\u7247\u5185\uff0c\u4e00\u4e2a\u8fdb\u7a0b\u4f1a\u72ec\u4eabCPU\u65f6\u95f4\u3002\u5982\u679c\u8be5\u8fdb\u7a0b\u5728\u8fd9\u4e2a\u65f6\u95f4\u7247\u5185\u6ca1\u6709\u8fd0\u884c\u5b8c\u6bd5\uff0c\u8c03\u5ea6\u7a0b\u5e8f\u5c31\u4f1a\u5207\u6362\u8be5\u8fdb\u7a0b\u4f7f\u5f97\u5176\u4ed6\u62e5\u6709\u65f6\u95f4\u7247\u7684\u8fdb\u7a0b\u8fd0\u884c\u3002<\/p>\n<p>\u65f6\u95f4\u7247\u7684\u5212\u5206\u5bf9\u7cfb\u7edf\u6765\u8bf4\u4e5f\u662f\u4e00\u4ef6\u96be\u4e8b\uff0c\u65e2\u4e0d\u80fd\u8fc7\u957f\u53c8\u4e0d\u80fd\u8fc7\u77ed\u3002\u8fc7\u957f\u7684\u65f6\u95f4\u7247\u4f1a\u5bfc\u81f4\u7cfb\u7edf\u7684\u54cd\u5e94\u80fd\u529b\u4e0b\u964d\uff1b\u800c\u8fc7\u77ed\u7684\u65f6\u95f4\u7247\u4f1a\u5bfc\u81f4\u7cfb\u7edf\u9891\u7e41\u53d1\u751f\u8fdb\u7a0b\u5207\u6362\uff0c\u7531\u6b64\u5c06\u5e26\u6765\u4e0d\u5fc5\u8981\u7684\u5904\u7406\u5668\u6d88\u8017\u3002\u663e\u7136\uff0cI\/O\u6d88\u8017\u578b\u8fdb\u7a0b\u5e0c\u671b\u65f6\u95f4\u7247\u8d8a\u77ed\u8d8a\u597d\uff0c\u8fd9\u6837\u90a3\u4e9b\u7b49\u5f85I\/O\u7684\u8fdb\u7a0b\u5c31\u80fd\u88ab\u8fc5\u901f\u5207\u6362\uff1b\u800cCPU\u6d88\u8017\u578b\u8fdb\u7a0b\u5219\u5e0c\u671b\u65f6\u95f4\u7247\u8d8a\u957f\u8d8a\u597d\uff0c\u8fd9\u6837\u5b83\u4eec\u5c31\u53ef\u4ee5\u4e00\u76f4\u5360\u7528CPU\u3002\u56e0\u6b64\uff0cI\/O\u6d88\u8017\u578b\u8fdb\u7a0b\u548cCPU\u6d88\u8017\u578b\u8fdb\u7a0b\u7684\u77db\u76fe\u518d\u4e00\u6b21\u663e\u73b0\u51fa\u6765\u3002<\/p>\n<p>Linux\u8c03\u5ea6\u7a0b\u5e8f\u89e3\u51b3\u8fd9\u79cd\u77db\u76fe\u7684\u65b9\u6cd5\u662f\uff0c\u63d0\u4f9b\u4e00\u4e2a\u8f83\u957f\u7684\u9ed8\u8ba4\u65f6\u95f4\u7247\uff0c\u4f46\u662f\u5374\u63d0\u9ad8\u4ea4\u4e92\u8fdb\u7a0b\u7684\u4f18\u5148\u7ea7\uff0c\u4ee5\u4f7f\u5f97\u8fd9\u4e9b\u8fdb\u7a0b\u8fd0\u884c\u7684\u66f4\u9891\u7e41\u3002\u5728Linux\u7684\u8c03\u5ea6\u7b97\u6cd5\u4e2d\uff0c\u6bcf\u4e2a\u8fdb\u7a0b\u5728\u8bde\u751f\u65f6\u603b\u662f\u7ee7\u627f\u7236\u8fdb\u7a0b\u4e00\u534a\u7684\u65f6\u95f4\u7247\uff0c\u800c\u4e4b\u540e\u7684\u65f6\u95f4\u7247\u5219\u662f\u8c03\u5ea6\u7a0b\u5e8f\u6839\u636e\u8fdb\u7a0b\u7684\u9759\u6001\u4f18\u5148\u7ea7\u800c\u5206\u914d\u3002<\/p>\n<h4>1.3\u4f18\u5148\u7ea7<\/h4>\n<p>\u6211\u4eec\u4e0a\u9762\u8bf4\u8fc7\uff0c\u8c03\u5ea6\u7a0b\u5e8f\u5728\u9009\u53d6\u4e0b\u4e00\u4e2a\u6267\u884c\u7684\u8fdb\u7a0b\u65f6\u4f9d\u636e\u7684\u662f\u8fdb\u7a0b\u7684\u4f18\u5148\u7ea7\u3002\u901a\u8fc7\u4e0a\u9762\u5bf9\u8fdb\u7a0b\u7684\u5212\u5206\u53ef\u4ee5\u770b\u51fa\uff0c\u4e0d\u540c\u7c7b\u578b\u7684\u8fdb\u7a0b\u5e94\u8be5\u6709\u4e0d\u540c\u7684\u4f18\u5148\u7ea7\u3002\u6bcf\u4e2a\u8fdb\u7a0b\u4e0e\u751f\u4ff1\u6765\uff08\u5373\u4ece\u7236\u8fdb\u7a0b\u90a3\u91cc\u7ee7\u627f\u800c\u6765\uff09\u90fd\u6709\u4e00\u4e2a\u4f18\u5148\u7ea7\uff0c\u6211\u4eec\u5c06\u5176\u79f0\u4e3a\u9759\u6001\u4f18\u5148\u7ea7\u3002\u666e\u901a\u8fdb\u7a0b\u7684\u9759\u6001\u4f18\u5148\u7ea7\u8303\u56f4\u4ece100\u5230139\uff0c100\u4e3a\u6700\u9ad8\u4f18\u5148\u7ea7\uff0c139\u4e3a\u6700\u4f4e\u4f18\u5148\u7ea7\u3002<\/p>\n<p>\u5f53\u8fdb\u7a0b\u7528\u5b8c\u4e86\u65f6\u95f4\u7247\u540e\uff0c\u7cfb\u7edf\u5c31\u4f1a\u4e3a\u8be5\u8fdb\u7a0b\u5206\u914d\u65b0\u7684\u65f6\u95f4\u7247\uff08\u5373\u57fa\u672c\u65f6\u95f4\u7247\uff09\uff0c<strong>\u9759\u6001\u4f18\u5148\u7ea7\u672c\u8d28\u4e0a\u51b3\u5b9a\u4e86\u65f6\u95f4\u7247\u5206\u914d\u7684\u5927\u5c0f<\/strong>\u3002\u9759\u6001\u4f18\u5148\u7ea7\u548c\u57fa\u672c\u65f6\u95f4\u7247\u7684\u5173\u7cfb\u5982\u4e0b\uff1a<\/p>\n<p><strong>\u9759\u6001\u4f18\u5148\u7ea7&lt;120\uff0c\u57fa\u672c\u65f6\u95f4\u7247=max((140-\u9759\u6001\u4f18\u5148\u7ea7)*20, MIN_TIMESLICE)<br \/>\n\u9759\u6001\u4f18\u5148\u7ea7&gt;=120\uff0c\u57fa\u672c\u65f6\u95f4\u7247=max((140-\u9759\u6001\u4f18\u5148\u7ea7)*5, MIN_TIMESLICE)<\/strong><\/p>\n<p>\u5176\u4e2dMIN_TIMESLICE\u4e3a\u7cfb\u7edf\u89c4\u5b9a\u7684\u6700\u5c0f\u65f6\u95f4\u7247\u3002\u4ece\u8be5\u8ba1\u7b97\u516c\u5f0f\u53ef\u4ee5\u770b\u51fa\uff0c\u9759\u6001\u4f18\u5148\u7ea7\u8d8a\u9ad8\uff08\u503c\u8d8a\u4f4e\uff09\uff0c\u8fdb\u7a0b\u5f97\u5230\u7684\u65f6\u95f4\u7247\u8d8a\u957f\u3002\u5176\u7ed3\u679c\u662f\uff0c\u4f18\u5148\u7ea7\u9ad8\u7684\u8fdb\u7a0b\u4f1a\u83b7\u5f97\u66f4\u957f\u7684\u65f6\u95f4\u7247\uff0c\u800c\u4f18\u5148\u7ea7\u4f4e\u7684\u8fdb\u7a0b\u5f97\u5230\u7684\u65f6\u95f4\u7247\u5219\u8f83\u77ed\u3002<\/p>\n<p>\u8fdb\u7a0b\u9664\u4e86\u62e5\u6709\u9759\u6001\u4f18\u5148\u7ea7\u5916\uff0c\u8fd8\u6709\u52a8\u6001\u4f18\u5148\u7ea7\uff0c\u5176\u53d6\u503c\u8303\u56f4\u662f100\u5230139\u3002<strong>\u5f53\u8c03\u5ea6\u7a0b\u5e8f\u9009\u62e9\u65b0\u8fdb\u7a0b\u8fd0\u884c\u65f6\u5c31\u4f1a\u4f7f\u7528\u8fdb\u7a0b\u7684\u52a8\u6001\u4f18\u5148\u7ea7<\/strong>\uff0c\u52a8\u6001\u4f18\u5148\u7ea7\u548c\u9759\u6001\u4f18\u5148\u7ea7\u7684\u5173\u7cfb\u53ef\u53c2\u8003\u4e0b\u9762\u7684\u516c\u5f0f\uff1a<\/p>\n<p><strong>\u52a8\u6001\u4f18\u5148\u7ea7=max(100 , min(\u9759\u6001\u4f18\u5148\u7ea7 &#8211; bonus + 5) , 139)<\/strong><\/p>\n<p>\u4ece\u4e0a\u9762\u770b\u51fa\uff0c\u52a8\u6001\u4f18\u5148\u7ea7\u7684\u751f\u6210\u662f\u4ee5\u9759\u6001\u4f18\u5148\u7ea7\u4e3a\u57fa\u7840\uff0c\u518d\u52a0\u4e0a\u76f8\u5e94\u7684\u60e9\u7f5a\u6216\u5956\u52b1(bonus)\u3002\u8fd9\u4e2abonus\u5e76\u4e0d\u662f\u968f\u673a\u7684\u4ea7\u751f\uff0c\u800c\u662f\u6839\u636e\u8fdb\u7a0b\u8fc7\u53bb\u7684\u5e73\u5747\u7761\u7720\u65f6\u95f4\u505a\u76f8\u5e94\u7684\u60e9\u7f5a\u6216\u5956\u52b1\u3002<\/p>\n<p>\u6240\u8c13\u5e73\u5747\u7761\u7720\u65f6\u95f4\uff08sleep_avg\uff0c\u4f4d\u4e8etask_struct\u7ed3\u6784\u4e2d\uff09\u5c31\u662f\u8fdb\u7a0b\u5728\u7761\u7720\u72b6\u6001\u6240\u6d88\u8017\u7684\u603b\u65f6\u95f4\u6570\uff0c\u8fd9\u91cc\u7684\u5e73\u5747\u5e76\u4e0d\u662f\u76f4\u63a5\u5bf9\u65f6\u95f4\u6c42\u5e73\u5747\u6570\u3002\u5e73\u5747\u7761\u7720\u65f6\u95f4\u968f\u7740\u8fdb\u7a0b\u7684\u7761\u7720\u800c\u589e\u957f\uff0c\u968f\u7740\u8fdb\u7a0b\u7684\u8fd0\u884c\u800c\u51cf\u5c11\u3002\u56e0\u6b64\uff0c\u5e73\u5747\u7761\u7720\u65f6\u95f4\u8bb0\u5f55\u4e86\u8fdb\u7a0b\u7761\u7720\u548c\u6267\u884c\u7684\u65f6\u95f4\uff0c\u5b83\u662f\u7528\u6765\u5224\u65ad\u8fdb\u7a0b\u4ea4\u4e92\u6027\u5f3a\u5f31\u7684\u5173\u952e\u6570\u636e\u3002\u5982\u679c\u4e00\u4e2a\u8fdb\u7a0b\u7684\u5e73\u5747\u7761\u7720\u65f6\u95f4\u5f88\u5927\uff0c\u90a3\u4e48\u5b83\u5f88\u53ef\u80fd\u662f\u4e00\u4e2a\u4ea4\u4e92\u6027\u5f88\u5f3a\u7684\u8fdb\u7a0b\u3002\u53cd\u4e4b\uff0c\u5982\u679c\u4e00\u4e2a\u8fdb\u7a0b\u7684\u5e73\u5747\u7761\u7720\u65f6\u95f4\u5f88\u5c0f\uff0c\u90a3\u4e48\u5b83\u5f88\u53ef\u80fd\u4e00\u76f4\u5728\u6267\u884c\u3002\u53e6\u5916\uff0c\u5e73\u5747\u7761\u7720\u65f6\u95f4\u4e5f\u8bb0\u5f55\u7740\u8fdb\u7a0b\u5f53\u524d\u7684\u4ea4\u4e92\u72b6\u6001\uff0c\u6709\u5f88\u5feb\u7684\u53cd\u5e94\u901f\u5ea6\u3002\u6bd4\u5982\u4e00\u4e2a\u8fdb\u7a0b\u5728\u67d0\u4e00\u5c0f\u6bb5\u65f6\u95f4\u4ea4\u4e92\u6027\u5f88\u5f3a\uff0c\u90a3\u4e48sleep_avg\u5c31\u6709\u53ef\u80fd\u66b4\u6da8\uff08\u5f53\u7136\u5b83\u4e0d\u80fd\u8d85\u8fc7MAX_SLEEP_AVG\uff09\uff0c\u4f46\u5982\u679c\u4e4b\u540e\u90fd\u4e00\u76f4\u5904\u4e8e\u6267\u884c\u72b6\u6001\uff0c\u90a3\u4e48sleep_avg\u5c31\u53c8\u53ef\u80fd\u4e00\u76f4\u9012\u51cf\u3002<\/p>\n<p>\u7406\u89e3\u4e86\u5e73\u5747\u7761\u7720\u65f6\u95f4\uff0c\u90a3\u4e48bonus\u7684\u542b\u4e49\u4e5f\u5c31\u663e\u800c\u6613\u89c1\u4e86\u3002\u4ea4\u4e92\u6027\u5f3a\u7684\u8fdb\u7a0b\u4f1a\u5f97\u5230\u8c03\u5ea6\u7a0b\u5e8f\u7684\u5956\u52b1\uff08bonus\u4e3a\u6b63\uff09\uff0c\u800c\u90a3\u4e9b\u4e00\u76f4\u9738\u5360CPU\u7684\u8fdb\u7a0b\u4f1a\u5f97\u5230\u76f8\u5e94\u7684\u60e9\u7f5a\uff08bonus\u4e3a\u8d1f\uff09\u3002\u5176\u5b9ebonus\u76f8\u5f53\u4e8e\u5e73\u5747\u7761\u7720\u65f6\u95f4\u7684\u7f29\u5f71\uff0c\u6b64\u65f6\u53ea\u662f\u5c06sleep_avg\u8c03\u6574\u6210bonus\u6570\u503c\u8303\u56f4\u5185\u7684\u5927\u5c0f\u3002<\/p>\n<p><em><strong>\u53c2\u8003\uff1a<\/strong><\/em><\/p>\n<p><em><strong>1.\u6df1\u5165\u7406\u89e3LINUX\u5185\u6838(\u7b2c\u4e09\u7248) \uff1b\uff08\u7f8e\uff09\u535a\u97e6\uff0c\u897f\u65af\u7279 \u8457\uff1b \u9648\u8389\u541b \u5f20\u743c\u58f0 \u5f20\u5b8f\u4f1f\u8bd1\uff1b \u4e2d\u56fd\u7535\u529b\u51fa\u7248\u793e\uff1b<\/strong><\/em><\/p>\n<p><em><strong>2.Linux\u5185\u6838\u8bbe\u8ba1\u4e0e\u5b9e\u73b0\uff1b\uff08\u7f8e\uff09\u62c9\u8299\uff08Love\uff0cR.\uff09\u8457\uff0c\u9648\u8389\u541b \u7b49\u8bd1\uff1b\u673a\u68b0\u5de5\u4e1a\u51fa\u7248\u793e\uff1b<\/strong><\/em><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u5bf9\u4e8e\u5206\u65f6\u64cd\u4f5c\u7cfb\u7edf\u800c\u8a00\uff0c\u8868\u9762\u4e0a\u770b\u8d77\u6765\u662f\u591a\u4e2a\u8fdb\u7a0b\u540c\u65f6\u5728\u6267\u884c\uff0c\u800c\u5728\u7cfb\u7edf\u5185\u90e8\u5219\u8fdb\u884c\u7740\u4ece\u4e00\u4e2a\u8fdb\u7a0b\u5230\u53e6\u4e00\u4e2a\u8fdb\u7a0b\u7684\u5207\u6362\u52a8\u4f5c\u3002 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[110],"tags":[134,108,183,212],"class_list":["post-2838","post","type-post","status-publish","format-standard","hentry","category-linux","tag-kernel","tag-linux","tag-183","tag-212"],"views":9125,"_links":{"self":[{"href":"http:\/\/edsionte.com\/techblog\/wp-json\/wp\/v2\/posts\/2838","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/edsionte.com\/techblog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/edsionte.com\/techblog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/edsionte.com\/techblog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/edsionte.com\/techblog\/wp-json\/wp\/v2\/comments?post=2838"}],"version-history":[{"count":0,"href":"http:\/\/edsionte.com\/techblog\/wp-json\/wp\/v2\/posts\/2838\/revisions"}],"wp:attachment":[{"href":"http:\/\/edsionte.com\/techblog\/wp-json\/wp\/v2\/media?parent=2838"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/edsionte.com\/techblog\/wp-json\/wp\/v2\/categories?post=2838"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/edsionte.com\/techblog\/wp-json\/wp\/v2\/tags?post=2838"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}