{"id":62,"date":"2019-07-10T12:43:21","date_gmt":"2019-07-10T03:43:21","guid":{"rendered":"https:\/\/hyandmj.asuscomm.com\/hblog\/?p=62"},"modified":"2021-05-03T19:47:26","modified_gmt":"2021-05-03T10:47:26","slug":"counting-number-of-processes","status":"publish","type":"post","link":"https:\/\/hyandmj.asuscomm.com\/hblog\/?p=62","title":{"rendered":"Counting Number of Processes"},"content":{"rendered":"\n<figure class=\"wp-block-image\"><img loading=\"lazy\" decoding=\"async\" width=\"914\" height=\"279\" src=\"https:\/\/hyandmj.asuscomm.com\/hblog\/wp-content\/uploads\/2019\/07\/load.png\" alt=\"\" class=\"wp-image-80\" srcset=\"https:\/\/hyandmj.asuscomm.com\/hblog\/wp-content\/uploads\/2019\/07\/load.png 914w, https:\/\/hyandmj.asuscomm.com\/hblog\/wp-content\/uploads\/2019\/07\/load-300x92.png 300w, https:\/\/hyandmj.asuscomm.com\/hblog\/wp-content\/uploads\/2019\/07\/load-768x234.png 768w\" sizes=\"auto, (max-width: 914px) 100vw, 914px\" \/><figcaption>\ubcf8\uc778\uc774 \uc5f0\uad6c\uc2e4\uc5d0\uc11c \uc720\uc9c0\ubcf4\uc218 \uc911\uc778 \ubaa8 \uc11c\ubc84\uc758 load average \ubaa8\ub2c8\ud130\ub9c1 \ubaa8\uc2b5<\/figcaption><\/figure>\n\n\n\n<p><code>\/proc\/loadavg<\/code> \ud30c\uc77c\uc744 \uc77d\uc5b4\ubcf4\uba74 \ub2e4\uc74c\uacfc \uac19\uc740 \ub0b4\uc6a9\ubb3c\uc774 \ucd9c\ub825\ub41c\ub2e4.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>$ cat \/proc\/loadavg\n0.15 0.10 0.09 1\/727 30761<\/code><\/pre>\n\n\n\n<p>\uac01 \ub2e4\uc12f \uac1c\uc758 \ud544\ub4dc\uc758 \uc758\ubbf8\ub294 <code>proc<\/code>\uc758 \ub9e4\ub274\uc5bc \ud398\uc774\uc9c0\uc5d0\uc11c \uc124\uba85\uc744 \ucc3e\uc744 \uc218 \uc788\ub2e4.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>$ man proc<\/code><\/pre>\n\n\n\n<p>\uc55e\uc758 \uc138 \uac12\uc740 1\ubd84, 5\ubd84, 15\ubd84 \ub3d9\uc548\uc758 load average \uac12. \ub124 \ubc88\uc9f8\ub294 CPU\uac00 \ud604\uc7ac \uc218\ud589\ud558\uace0 \uc788\ub294 \uc2a4\ub808\ub4dc \uc218\uc640 \ucee4\ub110 \uc2a4\ucf00\uc904\ub7ec \ubaa9\ub85d\uc5d0 \uc788\ub294 \ucd1d \uc2a4\ub808\ub4dc \uc218\ub97c \uc2ac\ub798\uc2dc\ub85c \uad6c\ubd84\ud55c \uac12. \ub9c8\uc9c0\ub9c9\uc73c\ub85c \ub2e4\uc12f \ubc88\uc9f8\ub294 \uac00\uc7a5 \ucd5c\uadfc\uc5d0 \uc2e4\ud589\ud55c \ud504\ub85c\uc138\uc2a4 \uc544\uc774\ub514.<\/p>\n\n\n\n<p>\uadfc\ub370 \uac00\ub9cc\ud788 \ubcf4\ub2c8 \ud504\ub85c\uc138\uc2a4 \uc218\uac00 727\ub77c\ub2c8, \uc0dd\uac01\ubcf4\ub2e4 \ub9ce\uc740 \ud3b8\uc774\ub2e4. \uacbd\ud5d8\uc0c1 \uc77c\ubc18\uc801\uc73c\ub85c \uadf8\ub807\uac8c \ub9ce\uc774 \ub3cc\uc544\uac00\uace0 \uc788\uc9c0\ub294 \uc54a\uc744\ud150\ub370&#8230; \ud558\uc5ec \ub2e4\ub978 \ubc29\ubc95\uc73c\ub85c \ud504\ub85c\uc138\uc2a4 \uc218\ub97c \uce74\uc6b4\ud2b8 \ud574\ubcf4\uc558\ub2e4.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>$ ps ax | wc -l\n300<\/code><\/pre>\n\n\n\n<p>727\ubcf4\ub2e4\ub294 \ud6e8\uc52c \uc791\ub2e4. \uadf8\ub7ec\uace0\ubcf4\ub2c8 <code>loadavg<\/code> \ud30c\uc77c\uc740 thread \uc218\ub97c \uce74\uc6b4\ud2b8\ud558\ubbc0\ub85c \ud558\ub098\uc758 \ud504\ub85c\uc138\uc2a4\uac00 \uba40\ud2f0\uc2a4\ub808\ub529\uc73c\ub85c \ub3cc\uc544\uac00\uba74 \ud504\ub85c\uc138\uc2a4 \uac1c\uc218\ubcf4\ub2e4 \ub354 \ub9ce\uc774 \uce74\uc6b4\ud2b8\ub418\ub294 \ub4ef \ud558\ub2e4. \ubcf4\ud1b5 \uc0ac\ub78c\ub4e4\uc774 \uac1c\ub150\uc801\uc73c\ub85c \uc774\ud574\ud558\ub294 \ud504\ub85c\uc138\uc2a4 \uc218\ub294 <code>ps ax | wc -l<\/code>\ub85c \uce74\uc6b4\ud305\ud558\ub294\uac8c \ub9de\uc744 \uac83\uc774\ub2e4.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\/proc\/loadavg \ud30c\uc77c\uc744 \uc77d\uc5b4\ubcf4\uba74 \ub2e4\uc74c\uacfc \uac19\uc740 \ub0b4\uc6a9\ubb3c\uc774 \ucd9c\ub825\ub41c\ub2e4. \uac01 \ub2e4\uc12f \uac1c\uc758 \ud544\ub4dc\uc758 \uc758\ubbf8\ub294 proc\uc758 \ub9e4\ub274\uc5bc \ud398\uc774\uc9c0\uc5d0\uc11c \uc124\uba85\uc744 \ucc3e\uc744 \uc218 \uc788\ub2e4. \uc55e\uc758 \uc138 \uac12\uc740 1\ubd84, 5\ubd84, 15\ubd84 \ub3d9\uc548\uc758 load average \uac12. \ub124 \ubc88\uc9f8\ub294 CPU\uac00 \ud604\uc7ac \uc218\ud589\ud558\uace0 \uc788\ub294 \uc2a4\ub808\ub4dc \uc218\uc640 \ucee4\ub110 \uc2a4\ucf00\uc904\ub7ec \ubaa9\ub85d\uc5d0 \uc788\ub294 \ucd1d \uc2a4\ub808\ub4dc \uc218\ub97c \uc2ac\ub798\uc2dc\ub85c \uad6c\ubd84\ud55c \uac12. \ub9c8\uc9c0\ub9c9\uc73c\ub85c \ub2e4\uc12f \ubc88\uc9f8\ub294 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2],"tags":[],"class_list":["post-62","post","type-post","status-publish","format-standard","hentry","category-linux"],"_links":{"self":[{"href":"https:\/\/hyandmj.asuscomm.com\/hblog\/index.php?rest_route=\/wp\/v2\/posts\/62","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/hyandmj.asuscomm.com\/hblog\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/hyandmj.asuscomm.com\/hblog\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/hyandmj.asuscomm.com\/hblog\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/hyandmj.asuscomm.com\/hblog\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=62"}],"version-history":[{"count":6,"href":"https:\/\/hyandmj.asuscomm.com\/hblog\/index.php?rest_route=\/wp\/v2\/posts\/62\/revisions"}],"predecessor-version":[{"id":789,"href":"https:\/\/hyandmj.asuscomm.com\/hblog\/index.php?rest_route=\/wp\/v2\/posts\/62\/revisions\/789"}],"wp:attachment":[{"href":"https:\/\/hyandmj.asuscomm.com\/hblog\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=62"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/hyandmj.asuscomm.com\/hblog\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=62"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/hyandmj.asuscomm.com\/hblog\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=62"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}