{"id":100472,"date":"2026-09-04T19:04:16","date_gmt":"2026-09-04T11:04:16","guid":{"rendered":"https:\/\/www.wsisp.com\/helps\/100472.html"},"modified":"2026-09-04T19:04:16","modified_gmt":"2026-09-04T11:04:16","slug":"linux-io%e6%a8%a1%e5%9e%8b%e4%b8%8eepoll%e5%a4%9a%e8%b7%af%e5%a4%8d%e7%94%a8%ef%bd%9ctcp%e9%ab%98%e5%b9%b6%e5%8f%91%e6%9c%8d%e5%8a%a1%e5%99%a8%e5%8e%9f%e7%90%86","status":"publish","type":"post","link":"https:\/\/www.wsisp.com\/helps\/100472.html","title":{"rendered":"Linux IO\u6a21\u578b\u4e0eepoll\u591a\u8def\u590d\u7528\uff5cTCP\u9ad8\u5e76\u53d1\u670d\u52a1\u5668\u539f\u7406"},"content":{"rendered":"<h3>\u524d\u8a00<\/h3>\n<p>\u5f00\u53d1\u7f51\u7edc\u670d\u52a1\u5668&#xff0c;\u6700\u6838\u5fc3\u7684\u96be\u9898\u5c31\u662f\u5982\u4f55\u9ad8\u6548\u5904\u7406\u5927\u91cf\u7684\u5ba2\u6237\u7aef\u5e76\u53d1\u8fde\u63a5\u3002\u4f20\u7edf\u65b9\u6848\u662f\u6bcf\u6765\u4e00\u4e2a\u5ba2\u6237\u7aef\u5c31\u521b\u5efa\u4e00\u6761\u7ebf\u7a0b&#xff0c;\u4f46\u8fde\u63a5\u6570\u91cf\u66b4\u6da8\u4e4b\u540e&#xff0c;\u5927\u91cf\u7ebf\u7a0b\u4f1a\u5e26\u6765\u5de8\u5927\u7684\u5185\u5b58\u5f00\u9500\u4e0eCPU\u8c03\u5ea6\u538b\u529b&#xff0c;\u670d\u52a1\u5668\u6781\u6613\u8fc7\u8f7d\u3002Linux\u4e0b\u4e00\u5171\u5b58\u57284\u79cdIO\u6a21\u578b&#xff0c;IO\u591a\u8def\u590d\u7528\u662f\u5b9e\u73b0\u9ad8\u5e76\u53d1\u7684\u4e3b\u6d41\u6280\u672f&#xff0c;select\u3001poll\u3001epoll\u90fd\u5c5e\u4e8e\u591a\u8def\u590d\u7528&#xff0c;\u5176\u4e2depoll\u6027\u80fd\u6700\u4e3a\u7a81\u51fa&#xff0c;Nginx\u3001Redis\u8fd9\u7c7b\u9ad8\u6027\u80fd\u670d\u52a1\u5e95\u5c42\u90fd\u4f9d\u8d56epoll\u3002\u672c\u7bc7\u68b3\u74064\u7c7bIO\u6a21\u578b&#xff0c;\u8bb2\u89e3\u591a\u8def\u590d\u7528\u6838\u5fc3\u539f\u7406\u4ee5\u53caepoll\u6574\u5957\u5de5\u4f5c\u903b\u8f91&#xff0c;\u5e2e\u52a9\u7406\u89e3TCP\u5e76\u53d1\u670d\u52a1\u5668\u5e95\u5c42\u3002<\/p>\n<h3>\u4e00\u3001TCP\u5e76\u53d1&#xff1a;\u591a\u7ebf\u7a0b\u6a21\u578b<\/h3>\n<p>\u6700\u7b80\u5355\u7684\u5e76\u53d1\u601d\u8def&#xff1a;\u6bcf\u63a5\u5165\u4e00\u4e2a\u65b0\u5ba2\u6237\u7aef&#xff0c;\u65b0\u5efa\u4e00\u6761\u72ec\u7acb\u7ebf\u7a0b\u4e13\u95e8\u8d1f\u8d23\u548c\u5ba2\u6237\u7aef\u901a\u4fe1\u3002<\/p>\n<li>\u4f18\u70b9&#xff1a;\u4e1a\u52a1\u903b\u8f91\u76f4\u89c2&#xff0c;\u7f16\u7801\u7b80\u5355\u3002<\/li>\n<li>\u7f3a\u70b9&#xff1a;\u7ebf\u7a0b\u62e5\u6709\u72ec\u7acb\u6808\u5185\u5b58&#xff0c;\u7cfb\u7edf\u80fd\u591f\u521b\u5efa\u7684\u7ebf\u7a0b\u6570\u91cf\u5b58\u5728\u4e0a\u9650&#xff1b;\u5e76\u53d1\u5ba2\u6237\u7aef\u8fc7\u591a&#xff0c;\u5185\u5b58\u4e0e\u8c03\u5ea6\u538b\u529b\u9661\u589e&#xff0c;\u670d\u52a1\u5668\u5b58\u5728\u5d29\u6e83\u98ce\u9669\u3002<\/li>\n<li>\u5de5\u7a0b\u4f18\u5316&#xff1a;\u901a\u5e38\u642d\u914d\u7ebf\u7a0b\u6c60\u4f7f\u7528&#xff0c;\u9884\u5148\u521b\u5efa\u597d\u4e00\u6279\u7ebf\u7a0b\u505a\u8d44\u6e90\u590d\u7528&#xff0c;\u907f\u514d\u9891\u7e41\u521b\u5efa\u9500\u6bc1\u7ebf\u7a0b&#xff0c;\u7f13\u89e3\u6027\u80fd\u538b\u529b\u3002<\/li>\n<p>\u5c40\u9650&#xff1a;\u7ebf\u7a0b\u6c60\u53ea\u80fd\u7f13\u89e3\u95ee\u9898&#xff0c;\u65e0\u6cd5\u652f\u6491\u4e0a\u4e07\u89c4\u6a21\u7684\u6d77\u91cf\u8fde\u63a5&#xff0c;\u8fd9\u65f6\u5c31\u8981\u4f9d\u9760IO\u591a\u8def\u590d\u7528\u3002<\/p>\n<h3>\u4e8c\u3001Linux\u56db\u79cdIO\u6a21\u578b<\/h3>\n<h4>1. \u963b\u585eIO<\/h4>\n<p>\u5f53\u8fdb\u7a0b\u53d1\u8d77IO\u8c03\u7528&#xff0c;\u5982\u679c\u6ca1\u6709\u5c31\u7eea\u6570\u636e&#xff0c;\u64cd\u4f5c\u7cfb\u7edf\u76f4\u63a5\u5c06\u8fdb\u7a0b\u6302\u8d77&#xff0c;\u8ba9\u51faCPU\u8d44\u6e90&#xff0c;\u4e0d\u4f1a\u6d88\u8017CPU&#xff1b;\u7b49\u5230\u6570\u636e\u51c6\u5907\u5b8c\u6210\u4e4b\u540e&#xff0c;\u8c03\u7528\u624d\u4f1a\u8fd4\u56de\u3002<\/p>\n<ul>\n<li>\u4f18\u70b9&#xff1a;CPU\u5229\u7528\u7387\u9ad8&#xff0c;\u65e0\u6570\u636e\u65f6\u4e0d\u5360\u7528CPU\u3002<\/li>\n<li>\u7f3a\u70b9&#xff1a;\u4e00\u6761\u7ebf\u7a0b\u540c\u4e00\u65f6\u523b\u53ea\u80fd\u5904\u7406\u4e00\u4e2a\u6587\u4ef6\u63cf\u8ff0\u7b26&#xff0c;\u60f3\u8981\u5904\u7406\u5927\u91cf\u8fde\u63a5\u5c31\u9700\u8981\u5927\u91cf\u7ebf\u7a0b\u3002<\/li>\n<\/ul>\n<h4>2. \u975e\u963b\u585eIO<\/h4>\n<p>\u628a\u6587\u4ef6\u63cf\u8ff0\u7b26\u8bbe\u7f6e\u6210\u975e\u963b\u585e\u6a21\u5f0f\u3002\u8c03\u7528\u8bfb\u5199\u63a5\u53e3&#xff0c;\u6ca1\u6709\u6570\u636e\u7684\u65f6\u5019\u4e0d\u4f1a\u963b\u585e&#xff0c;\u76f4\u63a5\u8fd4\u56de\u9519\u8bef\u3002\u5e94\u7528\u7a0b\u5e8f\u9700\u8981\u4e0d\u505c\u5faa\u73af\u8c03\u7528\u7cfb\u7edf\u63a5\u53e3&#xff0c;\u8f6e\u8be2\u68c0\u67e5\u662f\u5426\u6709\u6570\u636e\u5230\u6765\u3002<\/p>\n<ul>\n<li>\u4f18\u70b9&#xff1a;\u5355\u7ebf\u7a0b\u53ef\u4ee5\u7ba1\u7406\u591a\u4e2afd\u3002<\/li>\n<li>\u7f3a\u70b9&#xff1a;\u8f6e\u8be2\u4f1a\u6301\u7eed\u5360\u7528CPU&#xff0c;\u5373\u4fbf\u6ca1\u6709\u6570\u636e\u4e5f\u8981\u4e0d\u65ad\u6267\u884c\u4ee3\u7801&#xff0c;CPU\u5360\u7528\u5f88\u9ad8&#xff0c;\u5b9e\u9645\u9879\u76ee\u5f88\u5c11\u5355\u72ec\u4f7f\u7528\u3002<\/li>\n<\/ul>\n<h4>3. \u4fe1\u53f7\u9a71\u52a8IO<\/h4>\n<p>\u5c5e\u4e8e\u5f02\u6b65IO\u7684\u96cf\u5f62\u3002<\/p>\n<li>\u5c06\u6587\u4ef6\u63cf\u8ff0\u7b26\u8bbe\u7f6e\u4fe1\u53f7\u9a71\u52a8IO&#xff0c;\u5411\u5185\u6838\u5b8c\u6210\u6ce8\u518c&#xff1b;<\/li>\n<li>\u7531\u5185\u6838\u8d1f\u8d23\u76d1\u63a7fd\u4e0a\u662f\u5426\u53d1\u751fIO\u4e8b\u4ef6&#xff1b;<\/li>\n<li>\u4e8b\u4ef6\u5c31\u7eea\u4e4b\u540e&#xff0c;\u5185\u6838\u5411\u8fdb\u7a0b\u53d1\u9001SIGIO\u4fe1\u53f7&#xff1b;<\/li>\n<li>\u7528\u6237\u8fdb\u7a0b\u6355\u83b7\u8fd9\u4e2a\u4fe1\u53f7&#xff0c;\u5728\u4fe1\u53f7\u5904\u7406\u51fd\u6570\u4e2d\u5b8c\u6210\u8bfb\u5199\u5904\u7406\u3002<\/li>\n<p>\u7f3a\u70b9&#xff1a;\u4fe1\u53f7\u673a\u5236\u4e0d\u53ef\u9760&#xff0c;\u4e8b\u4ef6\u5bb9\u6613\u4e22\u5931&#xff1b;\u4e1a\u52a1\u5199\u5728\u4fe1\u53f7\u5904\u7406\u51fd\u6570\u6781\u6613\u4ea7\u751fbug&#xff0c;\u51e0\u4e4e\u4e0d\u4f1a\u5728\u6b63\u5f0f\u9879\u76ee\u4f7f\u7528\u3002<\/p>\n<h4>4. IO\u591a\u8def\u590d\u7528<\/h4>\n<p>\u6838\u5fc3\u601d\u60f3&#xff1a;\u5355\u7ebf\u7a0b&#xff0c;\u59d4\u6258\u5185\u6838\u540c\u65f6\u76d1\u89c6\u4e00\u5927\u6279\u6587\u4ef6\u63cf\u8ff0\u7b26\u3002\u53ea\u8981\u96c6\u5408\u4e2d\u4efb\u610f\u4e00\u4e2afd\u4e8b\u4ef6\u5c31\u7eea&#xff0c;\u51fd\u6570\u5c31\u8fd4\u56de&#xff0c;\u7528\u6237\u7a0b\u5e8f\u518d\u53bb\u5904\u7406\u5df2\u7ecf\u5c31\u7eea\u7684fd\u3002<\/p>\n<p>\u4ee3\u8868\u5b9e\u73b0&#xff1a;select\u3001poll\u3001epoll\u3002<\/p>\n<h5>select<\/h5>\n<p>select\u63a5\u6536\u4e00\u7ec4\u6587\u4ef6\u63cf\u8ff0\u7b26\u96c6\u5408&#xff0c;\u96c6\u5408\u5185\u4efb\u610ffd\u4ea7\u751f\u4e8b\u4ef6&#xff0c;select\u5c31\u89e3\u9664\u963b\u585e\u8fd4\u56de\u3002<\/p>\n<p>select\u4f1a\u76f4\u63a5\u4fee\u6539\u4f20\u5165\u7684fd\u96c6\u5408&#xff1a;\u4f1a\u6e05\u9664\u6389\u6ca1\u6709\u4e8b\u4ef6\u53d1\u751f\u7684fd&#xff0c;\u96c6\u5408\u91cc\u9762\u53ea\u4f1a\u4fdd\u7559\u5c31\u7eea\u7684fd\u3002\u6240\u4ee5\u6bcf\u4e00\u8f6e\u5faa\u73af&#xff0c;\u90fd\u5fc5\u987b\u91cd\u65b0\u88c5\u586bfd\u96c6\u5408\u3002<\/p>\n<p>\u914d\u5957\u64cd\u4f5c\u5b8f&#xff1a;<\/p>\n<ul>\n<li>FD_ZERO&#xff1a;\u6e05\u7a7a\u6574\u4e2afd\u96c6\u5408<\/li>\n<li>FD_SET&#xff1a;\u628a\u6307\u5b9afd\u52a0\u5165\u96c6\u5408<\/li>\n<li>FD_CLR&#xff1a;\u5c06\u6307\u5b9afd\u4ece\u96c6\u5408\u79fb\u9664<\/li>\n<li>FD_ISSET&#xff1a;\u5224\u65adfd\u662f\u5426\u8fd8\u5728\u5c31\u7eea\u96c6\u5408\u5185<\/li>\n<\/ul>\n<p>select\u51fd\u6570\u53c2\u6570\u89e3\u8bfb&#xff1a;<\/p>\n<li>nfds&#xff1a;\u96c6\u5408\u5185\u6700\u5927\u7684\u6587\u4ef6\u63cf\u8ff0\u7b26\u6570\u503c\u518d\u52a01&#xff1b;<\/li>\n<li>readfds&#xff1a;\u76d1\u542c\u8bfb\u4e8b\u4ef6\u7684fd\u96c6\u5408&#xff1b;<\/li>\n<li>writefds&#xff1a;\u76d1\u542c\u5199\u4e8b\u4ef6\u7684fd\u96c6\u5408&#xff1b;<\/li>\n<li>exceptfds&#xff1a;\u76d1\u542c\u5f02\u5e38\u4e8b\u4ef6\u96c6\u5408&#xff1b;<\/li>\n<li>timeout&#xff1a;\u8d85\u65f6\u65f6\u95f4&#xff0c;\u4f20\u5165NULL\u4ee3\u8868\u6c38\u4e45\u963b\u585e\u7b49\u5f85\u3002<\/li>\n<p>\u8fd4\u56de\u503c\u542b\u4e49&#xff1a;<\/p>\n<ul>\n<li>\u5927\u4e8e0&#xff1a;\u5df2\u7ecf\u5c31\u7eea\u7684\u6587\u4ef6\u63cf\u8ff0\u7b26\u6570\u91cf&#xff1b;<\/li>\n<li>-1&#xff1a;\u8c03\u7528\u51fa\u9519&#xff1b;<\/li>\n<li>0&#xff1a;\u8d85\u65f6&#xff0c;\u5168\u7a0b\u6ca1\u6709\u4efb\u4f55\u4e8b\u4ef6\u4ea7\u751f\u3002<\/li>\n<\/ul>\n<p>select\u7684\u56fa\u6709\u77ed\u677f<\/p>\n<li>fd\u96c6\u5408\u5b58\u5728\u6700\u5927\u6570\u91cf\u9650\u5236&#xff1b;<\/li>\n<li>\u6bcf\u6b21\u8c03\u7528\u90fd\u9700\u8981\u628afd\u96c6\u5408\u4ece\u7528\u6237\u6001\u62f7\u8d1d\u5230\u5185\u6838\u6001&#xff1b;<\/li>\n<li>\u8fd4\u56de\u4e4b\u540e&#xff0c;\u7528\u6237\u7a0b\u5e8f\u5fc5\u987b\u904d\u5386\u6574\u4e2a\u96c6\u5408&#xff0c;\u81ea\u5df1\u5224\u65ad\u54ea\u4e00\u4e2afd\u53d1\u751f\u4e8b\u4ef6\u3002<\/li>\n<h3>\u4e09\u3001epoll&#xff1a;Linux\u9ad8\u6027\u80fd\u591a\u8def\u590d\u7528<\/h3>\n<p>epoll\u662fLinux\u72ec\u6709\u7684\u591a\u8def\u590d\u7528\u5b9e\u73b0&#xff0c;\u89e3\u51b3select\u7684\u6027\u80fd\u7f3a\u9677\u3002\u5185\u6838\u5185\u90e8\u7ef4\u62a4\u7ea2\u9ed1\u6811&#xff0c;\u7528\u6765\u5b58\u50a8\u6240\u6709\u9700\u8981\u76d1\u542c\u7684\u6587\u4ef6\u63cf\u8ff0\u7b26\u3002\u4e00\u5171\u4e09\u4e2a\u6838\u5fc3\u63a5\u53e3&#xff1a;epoll_create\u3001epoll_ctl\u3001epoll_wait\u3002<\/p>\n<h4>1. epoll_create<\/h4>\n<p>\u529f\u80fd&#xff1a;\u521b\u5efaepoll\u5b9e\u4f8b&#xff0c;\u5728\u5185\u6838\u751f\u6210\u4e8b\u4ef6\u76d1\u542c\u8868\u3002<\/p>\n<ul>\n<li>size&#xff1a;\u65e9\u671f\u7528\u4e8e\u63d0\u793a\u5185\u6838\u4e8b\u4ef6\u8868\u9884\u4f30\u5927\u5c0f&#xff0c;\u65b0\u7248Linux\u4e2d\u8be5\u53c2\u6570\u5df2\u7ecf\u88ab\u5ffd\u7565\u3002<\/li>\n<li>\u8fd4\u56de\u503c&#xff1a;\u6210\u529f\u8fd4\u56deepoll\u81ea\u8eab\u7684\u6587\u4ef6\u63cf\u8ff0\u7b26epfd&#xff1b;\u5931\u8d25\u8fd4\u56de-1\u3002<\/li>\n<\/ul>\n<h4>2. epoll_ctl<\/h4>\n<p>\u4e13\u95e8\u64cd\u4f5cepoll\u5185\u6838\u4e8b\u4ef6\u8868&#xff0c;\u5b9e\u73b0\u6dfb\u52a0\u3001\u4fee\u6539\u3001\u5220\u9664\u76d1\u542c\u4e8b\u4ef6\u3002<\/p>\n<p>\u53c2\u6570&#xff1a;<\/p>\n<li>epfd&#xff1a;epoll\u5b9e\u4f8b\u7684fd&#xff0c;epoll_create\u7684\u8fd4\u56de\u7ed3\u679c&#xff1b;<\/li>\n<li>op&#xff1a;\u64cd\u4f5c\u7c7b\u578b\n<ul>\n<li>EPOLL_CTL_ADD&#xff1a;\u5411\u5185\u6838\u4e8b\u4ef6\u8868\u65b0\u589efd\u4e0e\u76d1\u542c\u4e8b\u4ef6<\/li>\n<li>EPOLL_CTL_MOD&#xff1a;\u4fee\u6539\u5df2\u7ecf\u6ce8\u518cfd\u7684\u76d1\u542c\u4e8b\u4ef6<\/li>\n<li>EPOLL_CTL_DEL&#xff1a;\u4ece\u4e8b\u4ef6\u8868\u5220\u9664fd<\/li>\n<\/ul>\n<\/li>\n<li>fd&#xff1a;\u5f85\u64cd\u4f5c\u7684\u6587\u4ef6\u63cf\u8ff0\u7b26&#xff1b;<\/li>\n<li>event&#xff1a;epoll_event\u7ed3\u6784\u4f53&#xff0c;\u6307\u5b9a\u76d1\u542c\u4ec0\u4e48\u4e8b\u4ef6&#xff0c;\u540c\u65f6\u643a\u5e26\u81ea\u5b9a\u4e49\u7528\u6237\u6570\u636e\u3002<\/li>\n<p>\u8fd4\u56de&#xff1a;\u6210\u529f\u8fd4\u56de0&#xff0c;\u5931\u8d25\u8fd4\u56de-1\u3002<\/p>\n<p>epoll_event\u7ed3\u6784&#xff1a;\u5185\u90e8\u5305\u542b\u4e8b\u4ef6\u6807\u8bb0events&#xff0c;\u4ee5\u53ca\u8054\u5408\u4f53data\u3002data.fd\u7528\u6765\u4fdd\u5b58\u6587\u4ef6\u63cf\u8ff0\u7b26&#xff0c;epoll_wait\u8fd4\u56de\u4e8b\u4ef6\u7684\u65f6\u5019&#xff0c;\u4f1a\u539f\u6837\u628adata\u8fd4\u56de\u7ed9\u7528\u6237&#xff0c;\u4e1a\u52a1\u4f9d\u9760\u8fd9\u4e2afd\u5b9a\u4f4d\u5c31\u7eea\u8fde\u63a5\u3002<\/p>\n<p>\u5e38\u7528\u4e8b\u4ef6\u6807\u5fd7&#xff1a;<\/p>\n<ul>\n<li>EPOLLIN&#xff1a;\u8bfb\u4e8b\u4ef6&#xff0c;\u63a5\u6536\u7f13\u51b2\u533a\u6709\u53ef\u8bfb\u6570\u636e&#xff1b;\u65b0\u5ba2\u6237\u7aef\u8fde\u63a5\u5230\u6765\u4e5f\u4f1a\u89e6\u53d1\u8be5\u4e8b\u4ef6&#xff1b;<\/li>\n<li>EPOLLOUT&#xff1a;\u5199\u4e8b\u4ef6&#xff0c;\u53d1\u9001\u7f13\u51b2\u533a\u6709\u7a7a\u4f59\u7a7a\u95f4&#xff0c;\u53ef\u4ee5\u5411\u5916\u53d1\u9001\u6570\u636e&#xff1b;<\/li>\n<li>EPOLLET&#xff1a;\u5f00\u542f\u8fb9\u7f18\u89e6\u53d1\u6a21\u5f0f&#xff1b;\u9ed8\u8ba4\u662f\u6c34\u5e73\u89e6\u53d1LT\u3002<\/li>\n<\/ul>\n<p>\u91cd\u8981\u5751\u70b9&#xff1a;\u8c03\u7528epoll_ctl\u6dfb\u52a0fd\u7684\u65f6\u5019&#xff0c;event.data.fd\u5fc5\u987b\u548c\u7b2c\u4e09\u4e2a\u4f20\u5165\u53c2\u6570fd\u4fdd\u6301\u4e00\u81f4&#xff0c;\u5426\u5219epoll_wait\u62ff\u5230\u9519\u8beffd&#xff0c;\u4e1a\u52a1\u903b\u8f91\u5b8c\u5168\u9519\u4e71\u3002<\/p>\n<h4>3. epoll_wait<\/h4>\n<p>\u963b\u585e\u7b49\u5f85IO\u4e8b\u4ef6&#xff0c;\u5185\u6838\u5c06\u5c31\u7eea\u4e8b\u4ef6\u62f7\u8d1d\u5230\u7528\u6237\u7a7a\u95f4\u6570\u7ec4\u3002<\/p>\n<p>\u53c2\u6570&#xff1a;<\/p>\n<li>epfd&#xff1a;epoll\u5b9e\u4f8bfd&#xff1b;<\/li>\n<li>events&#xff1a;\u7528\u6237\u6570\u7ec4\u9996\u5730\u5740&#xff0c;\u5185\u6838\u5c06\u5c31\u7eea\u4e8b\u4ef6\u62f7\u8d1d\u5230\u6b64\u6570\u7ec4&#xff1b;<\/li>\n<li>maxevents&#xff1a;\u6570\u7ec4\u6700\u5927\u5bb9\u91cf&#xff1b;<\/li>\n<li>timeout&#xff1a;\u8d85\u65f6\u6beb\u79d2&#xff0c;\u4f20-1\u4ee3\u8868\u6c38\u4e45\u963b\u585e\u7b49\u5f85\u4e8b\u4ef6\u3002<\/li>\n<p>\u8fd4\u56de\u503c&#xff1a;<\/p>\n<ul>\n<li>\u5927\u4e8e0&#xff1a;\u672c\u6b21\u5c31\u7eea\u7684fd\u6570\u91cfnready&#xff0c;\u5faa\u73af\u53ea\u904d\u53860 ~ nready-1&#xff0c;\u4e0d\u8981\u904d\u5386\u6574\u4e2a\u6570\u7ec4&#xff1b;<\/li>\n<li>-1&#xff1a;\u63a5\u53e3\u8c03\u7528\u51fa\u9519&#xff1b;<\/li>\n<li>0&#xff1a;\u8d85\u65f6&#xff0c;\u6ca1\u6709\u4efb\u4f55\u4e8b\u4ef6\u53d1\u751f\u3002<\/li>\n<\/ul>\n<h3>\u56db\u3001LT\u6c34\u5e73\u89e6\u53d1 \u4e0e ET\u8fb9\u7f18\u89e6\u53d1<\/h3>\n<li>\n<p>LT\u6c34\u5e73\u89e6\u53d1&#xff08;\u9ed8\u8ba4\u6a21\u5f0f&#xff09;<\/p>\n<p>\u53ea\u8981\u7f13\u51b2\u533a\u8fd8\u6709\u672a\u8bfb\u5b8c\u7684\u6570\u636e&#xff0c;\u6bcf\u4e00\u6b21epoll_wait\u90fd\u4f1a\u4e0a\u62a5\u8be5\u4e8b\u4ef6\u3002\u5c31\u7b97\u672c\u6b21\u6ca1\u6709\u8bfb\u5b8c\u5168\u90e8\u6570\u636e&#xff0c;\u4e0b\u4e00\u8f6eepoll_wait\u4f9d\u65e7\u4f1a\u901a\u77e5\u3002\u7f16\u7801\u7b80\u5355&#xff0c;\u4e0d\u5bb9\u6613\u4e22\u5931\u4e8b\u4ef6\u3002<\/p>\n<\/li>\n<li>\n<p>ET\u8fb9\u7f18\u89e6\u53d1 EPOLLET<\/p>\n<p>\u53ea\u6709IO\u72b6\u6001\u53d1\u751f\u6539\u53d8\u7684\u90a3\u4e00\u77ac\u95f4&#xff0c;\u624d\u901a\u77e5\u4e00\u6b21\u3002\u4f8b\u5982\u65b0\u6570\u636e\u5230\u8fbe&#xff0c;\u53ea\u4f1a\u89e6\u53d1\u4e00\u6b21\u901a\u77e5&#xff1b;\u5982\u679c\u672c\u6b21\u6ca1\u6709\u628a\u7f13\u51b2\u533a\u5168\u90e8\u8bfb\u5b8c&#xff0c;\u5269\u4f59\u6570\u636e\u4e0d\u4f1a\u518d\u4ea7\u751f\u4e8b\u4ef6\u901a\u77e5\u3002<\/p>\n<\/li>\n<p>ET\u6a21\u5f0f\u5fc5\u987b\u628asocket\u8bbe\u7f6e\u4e3a\u975e\u963b\u585e&#xff0c;\u5faa\u73af\u8bfb\u53d6\u76f4\u5230\u8bfb\u5230EAGAIN&#xff0c;\u4e00\u6b21\u6027\u8bfb\u5b8c\u7f13\u51b2\u533a\u5168\u90e8\u5185\u5bb9\u3002\u6027\u80fd\u66f4\u9ad8&#xff0c;\u4f46\u7f16\u7801\u590d\u6742\u5ea6\u4e0a\u5347\u3002<\/p>\n<h3>\u4e94\u3001epoll TCP\u670d\u52a1\u5668\u5b8c\u6574\u4e1a\u52a1\u6d41\u7a0b<\/h3>\n<li>\u521b\u5efasocket&#xff0c;bind\u7ed1\u5b9a\u5730\u5740\u3001listen\u76d1\u542c&#xff0c;\u5f97\u5230\u76d1\u542csockfd&#xff1b;<\/li>\n<li>\u8c03\u7528epoll_create\u521b\u5efaepoll\u5b9e\u4f8b&#xff0c;\u62ff\u5230epfd&#xff1b;<\/li>\n<li>\u7ec4\u88c5epoll_event&#xff0c;\u8c03\u7528epoll_ctl(EPOLL_CTL_ADD)&#xff0c;\u628a\u76d1\u542csockfd\u52a0\u5165\u5185\u6838\u4e8b\u4ef6\u8868&#xff1b;<\/li>\n<li>\u5faa\u73af\u8c03\u7528epoll_wait\u963b\u585e\u7b49\u5f85\u4e8b\u4ef6\u5230\u6765&#xff1b;<\/li>\n<li>epoll_wait\u8fd4\u56de\u5c31\u7eea\u6570\u91cfnready&#xff0c;\u5faa\u73af\u904d\u5386\u5c31\u7eea\u4e8b\u4ef6&#xff1a;\n<ul>\n<li>\u5982\u679c\u5c31\u7eeafd\u662f\u76d1\u542csockfd&#xff1a;\u8c03\u7528accept\u83b7\u53d6\u65b0\u5ba2\u6237\u7aefconfd&#xff0c;\u5c06confd\u52a0\u5165epoll\u76d1\u542c&#xff1b;<\/li>\n<li>\u5982\u679c\u662f\u666e\u901a\u5ba2\u6237\u7aefconfd&#xff1a;\u6267\u884cread\u8bfb\u53d6\u6570\u636e&#xff0c;\u5904\u7406\u4e1a\u52a1\u903b\u8f91&#xff1b;<\/li>\n<li>\u6355\u83b7EPOLLHUP\u3001EPOLLERR\u4e8b\u4ef6&#xff1a;\u4ee3\u8868\u5ba2\u6237\u7aef\u65ad\u5f00\u8fde\u63a5&#xff0c;\u628afd\u4eceepoll\u5220\u9664&#xff0c;\u8c03\u7528close\u5173\u95ed\u6587\u4ef6\u63cf\u8ff0\u7b26\u3002<\/li>\n<\/ul>\n<\/li>\n<h3>\u516d\u3001\u5f00\u53d1\u9ad8\u9891\u8e29\u5751\u603b\u7ed3<\/h3>\n<li>\u540c\u4e00\u4e2afd\u91cd\u590d\u6267\u884cEPOLL_CTL_ADD&#xff0c;\u62a5\u9519File exists&#xff0c;\u4e0d\u5141\u8bb8\u91cd\u590d\u6dfb\u52a0&#xff1b;<\/li>\n<li>event.data.fd\u548cepoll_ctl\u7b2c\u4e09\u4e2a\u53c2\u6570fd\u4e0d\u4e00\u81f4&#xff0c;\u62ff\u5230\u9519\u8bef\u6587\u4ef6\u63cf\u8ff0\u7b26&#xff1b;<\/li>\n<li>for\u5faa\u73af\u904d\u5386\u6574\u4e2amaxevents\u6570\u7ec4&#xff0c;\u800c\u4e0d\u662f\u53ea\u904d\u5386nready\u4e2a\u5c31\u7eea\u4e8b\u4ef6&#xff0c;\u8bfb\u53d6\u5230\u6570\u7ec4\u5185\u7684\u5783\u573e\u968f\u673a\u503c&#xff1b;<\/li>\n<li>ET\u8fb9\u7f18\u89e6\u53d1\u4e0bsocket\u5fd8\u8bb0\u8bbe\u7f6e\u975e\u963b\u585e&#xff0c;\u7f13\u51b2\u533a\u6570\u636e\u8bfb\u53d6\u4e0d\u5e72\u51c0&#xff1b;<\/li>\n<li>\u5ba2\u6237\u7aef\u65ad\u5f00\u6ca1\u6709\u6355\u83b7EPOLLHUP&#xff0c;\u6ca1\u6709\u4eceepoll\u79fb\u9664fd&#xff0c;\u9020\u6210\u6587\u4ef6\u63cf\u8ff0\u7b26\u6cc4\u9732\u3002<\/li>\n<h3>\u5c0f\u7ed3<\/h3>\n<p>IO\u591a\u8def\u590d\u7528\u672c\u8d28\u662f\u5355\u7ebf\u7a0b\u59d4\u6258\u5185\u6838\u6279\u91cf\u76d1\u63a7\u5927\u91cf\u6587\u4ef6\u63cf\u8ff0\u7b26\u3002<\/p>\n<ul>\n<li>select\u5b9e\u73b0\u7b80\u5355&#xff0c;\u4f46\u662f\u6027\u80fd\u4e0a\u9650\u4f4e&#xff0c;\u5b58\u5728fd\u6570\u91cf\u9650\u5236&#xff1b;<\/li>\n<li>epoll\u4f9d\u9760\u5185\u6838\u7ea2\u9ed1\u6811\u3001\u4e8b\u4ef6\u56de\u8c03\u673a\u5236&#xff0c;\u5728\u6d77\u91cf\u8fde\u63a5\u573a\u666f\u6027\u80fd\u4f18\u5f02&#xff0c;\u662fLinux\u7f51\u7edc\u5f00\u53d1\u5fc5\u987b\u638c\u63e1\u7684\u6280\u672f\u3002<\/li>\n<\/ul>\n<p>\u6ce8\u610f&#xff1a;\u591a\u8def\u590d\u7528\u53ea\u662f\u4f18\u5316IO\u7b49\u5f85\u8fc7\u7a0b&#xff0c;\u5185\u90e8read\/write\u4f9d\u65e7\u5c5e\u4e8e\u540c\u6b65IO&#xff0c;\u5e76\u4e0d\u662f\u771f\u6b63\u7684\u5f02\u6b65IO\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u524d\u8a00<br \/>\n\u5f00\u53d1\u7f51\u7edc\u670d\u52a1\u5668&#xff0c;\u6700\u6838\u5fc3\u7684\u96be\u9898\u5c31\u662f\u5982\u4f55\u9ad8\u6548\u5904\u7406\u5927\u91cf\u7684\u5ba2\u6237\u7aef\u5e76\u53d1\u8fde\u63a5\u3002\u4f20\u7edf\u65b9\u6848\u662f\u6bcf\u6765\u4e00\u4e2a\u5ba2\u6237\u7aef\u5c31\u521b\u5efa\u4e00\u6761\u7ebf\u7a0b&#xff0c;\u4f46\u8fde\u63a5\u6570\u91cf\u66b4\u6da8\u4e4b\u540e&#xff0c;\u5927\u91cf\u7ebf\u7a0b\u4f1a\u5e26\u6765\u5de8\u5927\u7684\u5185\u5b58\u5f00\u9500\u4e0eCPU\u8c03\u5ea6\u538b\u529b&#xff0c;\u670d\u52a1\u5668\u6781\u6613\u8fc7\u8f7d\u3002Linux\u4e0b\u4e00\u5171\u5b58\u57284\u79cdIO\u6a21\u578b&#xff0c;IO\u591a\u8def\u590d\u7528\u662f\u5b9e\u73b0\u9ad8\u5e76\u53d1\u7684\u4e3b\u6d41\u6280\u672f&#xff0c;select\u3001poll\u3001epoll\u90fd\u5c5e\u4e8e\u591a\u8def\u590d\u7528&#xff0c;\u5176\u4e2depoll\u6027\u80fd\u6700\u4e3a\u7a81\u51fa&#xff0c;Nginx\u3001Redis\u8fd9\u7c7b<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[58,205,43],"topic":[],"class_list":["post-100472","post","type-post","status-publish","format-standard","hentry","category-server","tag-linux","tag-tcp-ip","tag-43"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v20.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Linux IO\u6a21\u578b\u4e0eepoll\u591a\u8def\u590d\u7528\uff5cTCP\u9ad8\u5e76\u53d1\u670d\u52a1\u5668\u539f\u7406 - \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\/100472.html\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Linux IO\u6a21\u578b\u4e0eepoll\u591a\u8def\u590d\u7528\uff5cTCP\u9ad8\u5e76\u53d1\u670d\u52a1\u5668\u539f\u7406 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"og:description\" content=\"\u524d\u8a00 \u5f00\u53d1\u7f51\u7edc\u670d\u52a1\u5668&#xff0c;\u6700\u6838\u5fc3\u7684\u96be\u9898\u5c31\u662f\u5982\u4f55\u9ad8\u6548\u5904\u7406\u5927\u91cf\u7684\u5ba2\u6237\u7aef\u5e76\u53d1\u8fde\u63a5\u3002\u4f20\u7edf\u65b9\u6848\u662f\u6bcf\u6765\u4e00\u4e2a\u5ba2\u6237\u7aef\u5c31\u521b\u5efa\u4e00\u6761\u7ebf\u7a0b&#xff0c;\u4f46\u8fde\u63a5\u6570\u91cf\u66b4\u6da8\u4e4b\u540e&#xff0c;\u5927\u91cf\u7ebf\u7a0b\u4f1a\u5e26\u6765\u5de8\u5927\u7684\u5185\u5b58\u5f00\u9500\u4e0eCPU\u8c03\u5ea6\u538b\u529b&#xff0c;\u670d\u52a1\u5668\u6781\u6613\u8fc7\u8f7d\u3002Linux\u4e0b\u4e00\u5171\u5b58\u57284\u79cdIO\u6a21\u578b&#xff0c;IO\u591a\u8def\u590d\u7528\u662f\u5b9e\u73b0\u9ad8\u5e76\u53d1\u7684\u4e3b\u6d41\u6280\u672f&#xff0c;select\u3001poll\u3001epoll\u90fd\u5c5e\u4e8e\u591a\u8def\u590d\u7528&#xff0c;\u5176\u4e2depoll\u6027\u80fd\u6700\u4e3a\u7a81\u51fa&#xff0c;Nginx\u3001Redis\u8fd9\u7c7b\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wsisp.com\/helps\/100472.html\" \/>\n<meta property=\"og:site_name\" content=\"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\" \/>\n<meta property=\"article:published_time\" content=\"2026-09-04T11:04:16+00:00\" \/>\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=\"3 \u5206\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/100472.html\",\"url\":\"https:\/\/www.wsisp.com\/helps\/100472.html\",\"name\":\"Linux IO\u6a21\u578b\u4e0eepoll\u591a\u8def\u590d\u7528\uff5cTCP\u9ad8\u5e76\u53d1\u670d\u52a1\u5668\u539f\u7406 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3\",\"isPartOf\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#website\"},\"datePublished\":\"2026-09-04T11:04:16+00:00\",\"dateModified\":\"2026-09-04T11:04:16+00:00\",\"author\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41\"},\"breadcrumb\":{\"@id\":\"https:\/\/www.wsisp.com\/helps\/100472.html#breadcrumb\"},\"inLanguage\":\"zh-Hans\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.wsisp.com\/helps\/100472.html\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/www.wsisp.com\/helps\/100472.html#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u9996\u9875\",\"item\":\"https:\/\/www.wsisp.com\/helps\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Linux IO\u6a21\u578b\u4e0eepoll\u591a\u8def\u590d\u7528\uff5cTCP\u9ad8\u5e76\u53d1\u670d\u52a1\u5668\u539f\u7406\"}]},{\"@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":"Linux IO\u6a21\u578b\u4e0eepoll\u591a\u8def\u590d\u7528\uff5cTCP\u9ad8\u5e76\u53d1\u670d\u52a1\u5668\u539f\u7406 - \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\/100472.html","og_locale":"zh_CN","og_type":"article","og_title":"Linux IO\u6a21\u578b\u4e0eepoll\u591a\u8def\u590d\u7528\uff5cTCP\u9ad8\u5e76\u53d1\u670d\u52a1\u5668\u539f\u7406 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","og_description":"\u524d\u8a00 \u5f00\u53d1\u7f51\u7edc\u670d\u52a1\u5668&#xff0c;\u6700\u6838\u5fc3\u7684\u96be\u9898\u5c31\u662f\u5982\u4f55\u9ad8\u6548\u5904\u7406\u5927\u91cf\u7684\u5ba2\u6237\u7aef\u5e76\u53d1\u8fde\u63a5\u3002\u4f20\u7edf\u65b9\u6848\u662f\u6bcf\u6765\u4e00\u4e2a\u5ba2\u6237\u7aef\u5c31\u521b\u5efa\u4e00\u6761\u7ebf\u7a0b&#xff0c;\u4f46\u8fde\u63a5\u6570\u91cf\u66b4\u6da8\u4e4b\u540e&#xff0c;\u5927\u91cf\u7ebf\u7a0b\u4f1a\u5e26\u6765\u5de8\u5927\u7684\u5185\u5b58\u5f00\u9500\u4e0eCPU\u8c03\u5ea6\u538b\u529b&#xff0c;\u670d\u52a1\u5668\u6781\u6613\u8fc7\u8f7d\u3002Linux\u4e0b\u4e00\u5171\u5b58\u57284\u79cdIO\u6a21\u578b&#xff0c;IO\u591a\u8def\u590d\u7528\u662f\u5b9e\u73b0\u9ad8\u5e76\u53d1\u7684\u4e3b\u6d41\u6280\u672f&#xff0c;select\u3001poll\u3001epoll\u90fd\u5c5e\u4e8e\u591a\u8def\u590d\u7528&#xff0c;\u5176\u4e2depoll\u6027\u80fd\u6700\u4e3a\u7a81\u51fa&#xff0c;Nginx\u3001Redis\u8fd9\u7c7b","og_url":"https:\/\/www.wsisp.com\/helps\/100472.html","og_site_name":"\u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","article_published_time":"2026-09-04T11:04:16+00:00","author":"admin","twitter_card":"summary_large_image","twitter_misc":{"\u4f5c\u8005":"admin","\u9884\u8ba1\u9605\u8bfb\u65f6\u95f4":"3 \u5206"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wsisp.com\/helps\/100472.html","url":"https:\/\/www.wsisp.com\/helps\/100472.html","name":"Linux IO\u6a21\u578b\u4e0eepoll\u591a\u8def\u590d\u7528\uff5cTCP\u9ad8\u5e76\u53d1\u670d\u52a1\u5668\u539f\u7406 - \u7f51\u7855\u4e92\u8054\u5e2e\u52a9\u4e2d\u5fc3","isPartOf":{"@id":"https:\/\/www.wsisp.com\/helps\/#website"},"datePublished":"2026-09-04T11:04:16+00:00","dateModified":"2026-09-04T11:04:16+00:00","author":{"@id":"https:\/\/www.wsisp.com\/helps\/#\/schema\/person\/358e386c577a3ab51c4493330a20ad41"},"breadcrumb":{"@id":"https:\/\/www.wsisp.com\/helps\/100472.html#breadcrumb"},"inLanguage":"zh-Hans","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wsisp.com\/helps\/100472.html"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/www.wsisp.com\/helps\/100472.html#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u9996\u9875","item":"https:\/\/www.wsisp.com\/helps"},{"@type":"ListItem","position":2,"name":"Linux IO\u6a21\u578b\u4e0eepoll\u591a\u8def\u590d\u7528\uff5cTCP\u9ad8\u5e76\u53d1\u670d\u52a1\u5668\u539f\u7406"}]},{"@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\/100472","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=100472"}],"version-history":[{"count":0,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/posts\/100472\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/media?parent=100472"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/categories?post=100472"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/tags?post=100472"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.wsisp.com\/helps\/wp-json\/wp\/v2\/topic?post=100472"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}