{"id":2360,"date":"2015-11-30T00:48:32","date_gmt":"2015-11-29T15:48:32","guid":{"rendered":"http:\/\/tech.akat.info\/?p=2360"},"modified":"2015-11-30T00:49:28","modified_gmt":"2015-11-29T15:49:28","slug":"apache%e8%a8%ad%e5%ae%9a%e9%a0%85%e7%9b%ae%e4%bd%9c%e6%88%90%e4%b8%ad","status":"publish","type":"post","link":"https:\/\/tech.akat.info\/?p=2360","title":{"rendered":"apache\u8a2d\u5b9a\u9805\u76ee(\u4f5c\u6210\u4e2d)"},"content":{"rendered":"<h1>\u8a2d\u5b9a\u52d8\u6240<\/h1>\n<p>\u3044\u304b\u306b\u30b5\u30fc\u30d0\u306e\u30b9\u30da\u30c3\u30af\u3092\u4f7f\u3044\u5207\u308b\u3053\u3068\u304c\u3067\u304d\u308b\u3088\u3046\u306b\u3001\u8a2d\u5b9a\u3059\u308b\u304b\u304c\u30dd\u30a4\u30f3\u30c8<br \/>\n\u3082\u3057\u30ea\u30af\u30a8\u30b9\u30c8\u904e\u591a\u3068\u306a\u3063\u305f\u5834\u5408\u306f\u3001\u51e6\u7406\u3057\u304d\u308c\u306a\u3044\u30ea\u30af\u30a8\u30b9\u30c8\u306f\u5f85\u3061\u884c\u5217\u306b\u3044\u308c\u3066<br \/>\n\u5f85\u3061\u884c\u5217\u6570\u3092\u8d85\u3048\u308b\u3068\u3001\u305d\u306e\u5f8c\u306e\u30ea\u30af\u30a8\u30b9\u30c8\u306b\u5bfe\u3057\u3066\u30a8\u30e9\u30fc\u3092\u8fd4\u5374\u3059\u308b<\/p>\n<h1>\u30a4\u30f3\u30b9\u30c8\u30fc\u30eb<\/h1>\n<pre class=\"brush: plain; title: ; notranslate\" title=\"\">\r\nroot@ubuntu1204:\/home\/shimizu# cat \/etc\/lsb-release\r\nDISTRIB_ID=Ubuntu\r\nDISTRIB_RELEASE=12.04\r\nDISTRIB_CODENAME=precise\r\nDISTRIB_DESCRIPTION=&quot;Ubuntu 12.04.5 LTS&quot;\r\n\r\nroot@ubuntu1204:\/home\/shimizu# aptitude install apache2-mpm-event\r\n...\r\n\r\nroot@ubuntu1204:\/home\/shimizu# apache2 -V\r\nServer version: Apache\/2.2.22 (Ubuntu)\r\nServer built:   Jul 24 2015 17:25:43\r\nServer's Module Magic Number: 20051115:30\r\nServer loaded:  APR 1.4.6, APR-Util 1.3.12\r\nCompiled using: APR 1.4.6, APR-Util 1.3.12\r\nArchitecture:   64-bit\r\nServer MPM:     Event\r\n  threaded:     yes (fixed thread count)\r\n    forked:     yes (variable process count)\r\n...\r\n\r\n<\/pre>\n<h1>MPM\uff1aevent<\/h1>\n<p>worker\u3068\u306e\u9055\u3044\u306fKeep-Alive(\u6301\u7d9a\u7684\u63a5\u7d9a)\u306e\u51e6\u7406\u65b9\u6cd5<br \/>\nworker\u306fKeep-Alive\u306e\u305f\u3081\u306b\u30b9\u30ec\u30c3\u30c9\u3092\u5f85\u6a5f\u3055\u305b\u308b\u304c<br \/>\nevent\u306fKeep-Alive\u7528\u306b\u5225\u306e\u30b9\u30ec\u30c3\u30c9\u306b\u5272\u308a\u632f\u308b<\/p>\n<h1>\u30c7\u30d5\u30a9\u30eb\u30c8\u72b6\u6cc1\u78ba\u8a8d<\/h1>\n<pre class=\"brush: plain; title: \u30d7\u30ed\u30bb\u30b9\u72b6\u614b; notranslate\" title=\"\u30d7\u30ed\u30bb\u30b9\u72b6\u614b\">\r\nroot@ubuntu1204:\/etc\/apache2# ps afx | egrep &quot;&#x5B;a]pache|&#x5B;C]OMMAND&quot;\r\n  PID TTY      STAT   TIME COMMAND\r\n59190 ?        Ss     0:00 \/usr\/sbin\/apache2 -k start\r\n59195 ?        S      0:00  \\_ \/usr\/sbin\/apache2 -k start\r\n59196 ?        Sl     0:00  \\_ \/usr\/sbin\/apache2 -k start\r\n59197 ?        Sl     0:00  \\_ \/usr\/sbin\/apache2 -k start\r\n\r\nroot@ubuntu1204:\/etc\/apache2# ps -efLl | egrep &quot;&#x5B;C]MD|&#x5B;a]pache&quot;\r\nF S UID        PID  PPID   LWP  C NLWP PRI  NI ADDR SZ WCHAN  STIME TTY          TIME CMD\r\n1 S root     59190     1 59190  0    1  80   0 - 15390 poll_s 12:08 ?        00:00:00 \/usr\/sbin\/apache2 -k start\r\n5 S www-data 59195 59190 59195  0    1  80   0 - 15323 wait_f 12:08 ?        00:00:00 \/usr\/sbin\/apache2 -k start\r\n5 S www-data 59196 59190 59196  0   27  80   0 - 104035 pipe_w 12:08 ?       00:00:00 \/usr\/sbin\/apache2 -k start\r\n1 S www-data 59196 59190 59204  0   27  80   0 - 104035 futex_ 12:08 ?       00:00:00 \/usr\/sbin\/apache2 -k start\r\n...(\u4e0a\u3068\u540c\u3058\u30b9\u30ec\u30c3\u30c9\u304c\u5408\u8a0825\u500b)\r\n1 S www-data 59196 59190 59229  0   27  80   0 - 104035 ep_pol 12:08 ?       00:00:00 \/usr\/sbin\/apache2 -k start\r\n5 S www-data 59197 59190 59197  0   27  80   0 - 87631 pipe_w 12:08 ?        00:00:00 \/usr\/sbin\/apache2 -k start\r\n1 S www-data 59197 59190 59200  0   27  80   0 - 87631 futex_ 12:08 ?        00:00:00 \/usr\/sbin\/apache2 -k start\r\n...(\u4e0a\u3068\u540c\u3058\u30b9\u30ec\u30c3\u30c9\u304c\u5408\u8a0825\u500b)\r\n1 S www-data 59197 59190 59251  0   27  80   0 - 87631 ep_pol 12:08 ?        00:00:00 \/usr\/sbin\/apache2 -k start\r\n<\/pre>\n<pre class=\"brush: plain; title: \u521d\u671f\u8a2d\u5b9a\u3068\u8aac\u660e; notranslate\" title=\"\u521d\u671f\u8a2d\u5b9a\u3068\u8aac\u660e\">\r\n&lt;IfModule mpm_event_module&gt;\r\n    # StartServers \u2266 MaxClients \/ ThreadsPerChild \u3067\u306a\u3051\u308c\u3070\u306a\u3089\u306a\u3044\r\n    # MinSpareThreads \/ ThreadsPerChild \uff5e MaxSpareThreads \/ ThreadsPerChild \r\n    StartServers          2\r\n    # \u30a2\u30a4\u30c9\u30eb\u306a\u30b9\u30ec\u30c3\u30c9\u6570\u306e\u6700\u5c0f\u5024\r\n    MinSpareThreads      25\r\n    # \u30a2\u30a4\u30c9\u30eb\u306a\u30b9\u30ec\u30c3\u30c9\u6570\u306e\u6700\u5927\u5024\r\n    MaxSpareThreads      75\r\n    # \u5b50\u30d7\u30ed\u30bb\u30b9\u6bce\u306e\u30b9\u30ec\u30c3\u30c9\u6570\uff08ThreadsPerChild\uff09\u306e\u8a2d\u5b9a\u53ef\u80fd\u306a\u4e0a\u9650\u5024\r\n    ThreadLimit          64\r\n    # \u5b50\u30d7\u30ed\u30bb\u30b9\u6bce\u306b\u751f\u6210\u3055\u308c\u308b\u30b9\u30ec\u30c3\u30c9\u6570\r\n    ThreadsPerChild      25\r\n    # \u6700\u5927\u540c\u6642\u30ea\u30af\u30a8\u30b9\u30c8\u6570\r\n    MaxClients          150\r\n    MaxRequestsPerChild   0\r\n&lt;\/IfModule&gt;\r\n<\/pre>\n<h2>ps\u898b\u65b9<\/h2>\n<p>LWP\uff1a\u8efd\u91cf\u30d7\u30ed\u30bb\u30b9(light weight process)\u307e\u305f\u306f\u30b9\u30ec\u30c3\u30c9ID<br \/>\nPPID\uff1a\u89aa\u30d7\u30ed\u30bb\u30b9\u306e\u30d7\u30ed\u30bb\u30b9 ID<br \/>\nNLWP\uff1a\u30d7\u30ed\u30bb\u30b9\u306b\u304a\u3051\u308b lwp(\u30b9\u30ec\u30c3\u30c9)\u306e\u6570<br \/>\nS(PROCESS STATE CODES)\uff1a\u30d7\u30ed\u30bb\u30b9\u72b6\u614b<br \/>\n\u3000S\uff1a\u5272\u308a\u8fbc\u307f\u53ef\u80fd\u306a\u30b9\u30ea\u30fc\u30d7\u72b6\u614b<br \/>\n\u3000s\uff1a\u30bb\u30c3\u30b7\u30e7\u30f3\u30ea\u30fc\u30c0<br \/>\n\u3000l\uff1a\u30de\u30eb\u30c1\u30b9\u30ec\u30c3\u30c9<br \/>\nF(PROCESS FLAGS)\uff1a\u30d7\u30ed\u30bb\u30b9\u306e\u30d5\u30e9\u30b0<br \/>\n\u30001\uff1aforked but didn&#8217;t exec<br \/>\n\u30004\uff1aused super-user privileges<br \/>\n\u30005\uff1a1+4<br \/>\nWCHAN\uff1a\u30b9\u30ea\u30fc\u30d7\u3057\u3066\u3044\u308b\u30ab\u30fc\u30cd\u30eb\u95a2\u6570\u540d<\/p>\n<h1>\u3044\u308d\u3044\u308d\u8a66\u3057\u3066\u307f\u308b<\/h1>\n<p>@todo<br \/>\nab -n 5000 -c 500<\/p>\n<h1>\u53c2\u8003URL<\/h1>\n<p><a href=\"http:\/\/wordpress.honobono-life.info\/lin-base\/ps%E3%82%B3%E3%83%9E%E3%83%B3%E3%83%89%E3%81%A7%E3%82%B9%E3%83%AC%E3%83%83%E3%83%89%E3%81%AB%E9%96%A2%E3%81%99%E3%82%8B%E6%83%85%E5%A0%B1%E3%82%92%E8%A1%A8%E7%A4%BA%E3%81%99%E3%82%8B%E3%81%AB%E3%81%AF\/\">ps\u30b3\u30de\u30f3\u30c9\u3067\u30b9\u30ec\u30c3\u30c9\u306b\u95a2\u3059\u308b\u60c5\u5831\u3092\u8868\u793a\u3059\u308b\u306b\u306f\uff1f<\/a><br \/>\n<a href=\"http:\/\/heartbeats.jp\/hbblog\/2015\/02\/apache-mpm.html\">Apache HTTP Server: MPM\u30d1\u30e9\u30e1\u30fc\u30bf \u30c1\u30fc\u30c8\u30b7\u30fc\u30c8<\/a><br \/>\n<a href=\"http:\/\/blog.kamata-net.com\/archives\/005389.html\">Apache\u306e\u30c1\u30e5\u30fc\u30cb\u30f3\u30b0\uff08\u6027\u80fd\u7de8\uff09<\/a><br \/>\n \u30d5\u30a1\u30a4\u30eb\u30c7\u30a3\u30b9\u30af\u30ea\u30d7\u30bf\u304c\u554f\u984c\u3067\u30b5\u30fc\u30d0\u30b9\u30da\u30c3\u30af\u3092\u4f7f\u3044\u5207\u308c\u3066\u3044\u306a\u3044\u53ef\u80fd\u6027\u3082<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u8a2d\u5b9a\u52d8\u6240 \u3044\u304b\u306b\u30b5\u30fc\u30d0\u306e\u30b9\u30da\u30c3\u30af\u3092\u4f7f\u3044\u5207\u308b\u3053\u3068\u304c\u3067\u304d\u308b\u3088\u3046\u306b\u3001\u8a2d\u5b9a\u3059\u308b\u304b\u304c\u30dd\u30a4\u30f3\u30c8 \u3082\u3057\u30ea\u30af\u30a8\u30b9\u30c8\u904e\u591a\u3068\u306a\u3063\u305f\u5834\u5408\u306f\u3001\u51e6\u7406\u3057\u304d\u308c\u306a\u3044\u30ea\u30af\u30a8\u30b9\u30c8\u306f\u5f85\u3061\u884c\u5217\u306b\u3044\u308c\u3066 \u5f85\u3061\u884c\u5217\u6570\u3092\u8d85\u3048\u308b\u3068\u3001\u305d\u306e\u5f8c\u306e\u30ea\u30af\u30a8\u30b9\u30c8\u306b\u5bfe\u3057\u3066\u30a8\u30e9\u30fc\u3092\u8fd4 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"categories":[17],"tags":[],"_links":{"self":[{"href":"https:\/\/tech.akat.info\/index.php?rest_route=\/wp\/v2\/posts\/2360"}],"collection":[{"href":"https:\/\/tech.akat.info\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/tech.akat.info\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/tech.akat.info\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/tech.akat.info\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=2360"}],"version-history":[{"count":3,"href":"https:\/\/tech.akat.info\/index.php?rest_route=\/wp\/v2\/posts\/2360\/revisions"}],"predecessor-version":[{"id":2363,"href":"https:\/\/tech.akat.info\/index.php?rest_route=\/wp\/v2\/posts\/2360\/revisions\/2363"}],"wp:attachment":[{"href":"https:\/\/tech.akat.info\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=2360"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/tech.akat.info\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=2360"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/tech.akat.info\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=2360"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}