{"id":1557,"date":"2006-11-21T10:39:00","date_gmt":"2006-11-21T10:39:00","guid":{"rendered":"http:\/\/gleamynode.net\/articles\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux"},"modified":"2022-12-28T01:46:48","modified_gmt":"2022-12-27T16:46:48","slug":"modifying-default-ulimit-values-for-a-normal-user-in-linux","status":"publish","type":"post","link":"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/","title":{"rendered":"Modifying Default ulimit Values for a Normal User in Linux"},"content":{"rendered":"\n

Linux\uc5d0\uc11c \uc77c\ubc18 \uc0ac\uc6a9\uc790\uc758 default ulimit \uac12 \uc218\uc815<\/p>\n\n\n\n

The default value of ulimit -n<\/tt> (the maximum number of open file descriptors per process per user) is 1024 in Ubuntu Linux<\/a>. There\u2019s no problem with this default value in my daily life, but I start to get \u2018Too many open files\u2019 errors when I test the performance of server applications which accept from 1000 to tens of thousands client connections. A super user (root) can type a command like ulimit -n 10240<\/tt> to increase the default limit value, but a normal user can\u2019t. If you are at least a sudoer, you can resolve this problem by adding the following lines to \/etc\/security\/limits.conf<\/tt> file.<\/p>\n\n\n\n

\uc81c\uac00 \uc0ac\uc6a9\ud558\uace0 \uc788\ub294 Ubuntu Linux<\/a>\uc758 ulimit -n<\/tt> (\ub3d9\uc2dc\uc5d0 \uc5f4 \uc218 \uc788\ub294 \ud30c\uc77c\uc758 \ucd1d \uc218)\uc758 \uae30\ubcf8\uac12\uc740 1024\uc785\ub2c8\ub2e4. \uc77c\uc0c1 \uc5c5\ubb34\ub97c \ubcf4\ub294\ub370\ub294 \uc804\ud600 \uc9c0\uc7a5\uc774 \uc5c6\uc9c0\ub9cc \uc11c\ubc84 \uc5b4\ud50c\ub9ac\ucf00\uc774\uc158\uc744 \ud14c\uc2a4\ud2b8\ud558\ub2e4 \ubcf4\uba74 \uc801\uac8c\ub294 1000\uac1c, \ub9ce\uac8c\ub294 \uc218\ub9cc \uac1c\uc758 \uc811\uc18d\uc744 \ud14c\uc2a4\ud2b8\ud574\uc57c \ud560 \uc77c\uc774 \uc0dd\uaca8 \u2018Too many open files\u2019 \uc5d0\ub7ec\ub97c \ubcfc \uc218\ubc16\uc5d0 \uc5c6\uc2b5\ub2c8\ub2e4. \uc218\ud37c \uc720\uc800 (root)\ub77c\uba74 ulimit -n 10240<\/tt>\uacfc \uac19\uc774 \uc785\ub825\ud558\uc5ec \uadf8 \uc81c\ud55c\uc744 \uc62c\ub9b4 \uc218 \uc788\uc9c0\ub9cc, \uc77c\ubc18 \uc0ac\uc6a9\uc790\ub294 \ubd88\uac00\ub2a5\ud569\ub2c8\ub2e4. \uc774\ub54c \ub9cc\uc57d \uc218\ud37c \uc720\uc800 \uad8c\ud55c\uc744 \uac16\uace0 \uc788\ub2e4\uba74 \/etc\/security\/limits.conf<\/tt> \ud30c\uc77c\uc5d0 \ub2e4\uc74c\uacfc \uac19\uc740 \ub0b4\uc6a9\uc744 \ucd94\uac00\ud558\uc5ec \uc774 \ubb38\uc81c\ub97c \ud574\uacb0\ud560 \uc218 \uc788\uc2b5\ub2c8\ub2e4.<\/p>\n\n\n\n

trustin         soft    nofile          10240\ntrustin         hard    nofile          10240\nwww-data        soft    nofile          10240\nwww-data        hard    nofile          10240<\/code><\/pre>\n\n\n\n

The example above increases the maximum number of open files per process per user to 10240 for two users; trustin and www-data.<\/p>\n\n\n\n

\uc704\uc758 \uc608\uc2dc\ub294 trustin\uacfc www-data\ub77c\ub294 \uc0ac\uc6a9\uc790\uc758 \ucd5c\ub300 \uc5f0 \ud30c\uc77c \uc218\ub97c 10240\uc73c\ub85c \uc62c\ub824 \uc90d\ub2c8\ub2e4.<\/p>\n","protected":false},"excerpt":{"rendered":"

Linux\uc5d0\uc11c \uc77c\ubc18 \uc0ac\uc6a9\uc790\uc758 default ulimit \uac12 \uc218\uc815 The default value of ulimit -n (the maximum number of open file descriptors per process per user) is 1024 in Ubuntu Linux. There\u2019s no problem with this default value in my daily life, but I start to get \u2018Too many open files\u2019 errors when I test the performance… Continue reading →<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"yoast_head":"Modifying Default ulimit Values for a Normal User in Linux — T's message of the day<\/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:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Modifying Default ulimit Values for a Normal User in Linux — T's message of the day\" \/>\n<meta property=\"og:description\" content=\"Linux\uc5d0\uc11c \uc77c\ubc18 \uc0ac\uc6a9\uc790\uc758 default ulimit \uac12 \uc218\uc815 The default value of ulimit -n (the maximum number of open file descriptors per process per user) is 1024 in Ubuntu Linux. There\u2019s no problem with this default value in my daily life, but I start to get \u2018Too many open files\u2019 errors when I test the performance... Continue reading →\" \/>\n<meta property=\"og:url\" content=\"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/\" \/>\n<meta property=\"og:site_name\" content=\"T's message of the day\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/trustin\" \/>\n<meta property=\"article:author\" content=\"https:\/\/www.facebook.com\/trustin\" \/>\n<meta property=\"article:published_time\" content=\"2006-11-21T10:39:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2022-12-27T16:46:48+00:00\" \/>\n<meta name=\"author\" content=\"Trustin Lee\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@https:\/\/www.twitter.com\/trustin\" \/>\n<meta name=\"twitter:site\" content=\"@trustin\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Trustin Lee\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/\"},\"author\":{\"name\":\"Trustin Lee\",\"@id\":\"https:\/\/vault.motd.kr\/wordpress\/#\/schema\/person\/4430ad90fc2ddeef051565701d85db9d\"},\"headline\":\"Modifying Default ulimit Values for a Normal User in Linux\",\"datePublished\":\"2006-11-21T10:39:00+00:00\",\"dateModified\":\"2022-12-27T16:46:48+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/\"},\"wordCount\":157,\"publisher\":{\"@id\":\"https:\/\/vault.motd.kr\/wordpress\/#\/schema\/person\/4430ad90fc2ddeef051565701d85db9d\"},\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/\",\"url\":\"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/\",\"name\":\"Modifying Default ulimit Values for a Normal User in Linux — T's message of the day\",\"isPartOf\":{\"@id\":\"https:\/\/vault.motd.kr\/wordpress\/#website\"},\"datePublished\":\"2006-11-21T10:39:00+00:00\",\"dateModified\":\"2022-12-27T16:46:48+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/vault.motd.kr\/wordpress\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Modifying Default ulimit Values for a Normal User in Linux\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/vault.motd.kr\/wordpress\/#website\",\"url\":\"https:\/\/vault.motd.kr\/wordpress\/\",\"name\":\"T's message of the day\",\"description\":\"the best is yet to come\",\"publisher\":{\"@id\":\"https:\/\/vault.motd.kr\/wordpress\/#\/schema\/person\/4430ad90fc2ddeef051565701d85db9d\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/vault.motd.kr\/wordpress\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\/\/vault.motd.kr\/wordpress\/#\/schema\/person\/4430ad90fc2ddeef051565701d85db9d\",\"name\":\"Trustin Lee\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/vault.motd.kr\/wordpress\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/vault.motd.kr\/wordpress\/wp-content\/uploads\/2020\/09\/avatar-2019-966px.png\",\"contentUrl\":\"https:\/\/vault.motd.kr\/wordpress\/wp-content\/uploads\/2020\/09\/avatar-2019-966px.png\",\"width\":966,\"height\":966,\"caption\":\"Trustin Lee\"},\"logo\":{\"@id\":\"https:\/\/vault.motd.kr\/wordpress\/#\/schema\/person\/image\/\"},\"sameAs\":[\"https:\/\/t.motd.kr\/\",\"https:\/\/www.facebook.com\/trustin\",\"https:\/\/www.instagram.com\/trustinlee\/\",\"https:\/\/www.linkedin.com\/in\/trustin\",\"https:\/\/twitter.com\/https:\/\/www.twitter.com\/trustin\",\"https:\/\/www.youtube.com\/@trustinlee\"]}]}<\/script>","yoast_head_json":{"title":"Modifying Default ulimit Values for a Normal User in Linux — T's message of the day","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:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/","og_locale":"en_US","og_type":"article","og_title":"Modifying Default ulimit Values for a Normal User in Linux — T's message of the day","og_description":"Linux\uc5d0\uc11c \uc77c\ubc18 \uc0ac\uc6a9\uc790\uc758 default ulimit \uac12 \uc218\uc815 The default value of ulimit -n (the maximum number of open file descriptors per process per user) is 1024 in Ubuntu Linux. There\u2019s no problem with this default value in my daily life, but I start to get \u2018Too many open files\u2019 errors when I test the performance... Continue reading →","og_url":"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/","og_site_name":"T's message of the day","article_publisher":"https:\/\/www.facebook.com\/trustin","article_author":"https:\/\/www.facebook.com\/trustin","article_published_time":"2006-11-21T10:39:00+00:00","article_modified_time":"2022-12-27T16:46:48+00:00","author":"Trustin Lee","twitter_card":"summary_large_image","twitter_creator":"@https:\/\/www.twitter.com\/trustin","twitter_site":"@trustin","twitter_misc":{"Written by":"Trustin Lee","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/#article","isPartOf":{"@id":"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/"},"author":{"name":"Trustin Lee","@id":"https:\/\/vault.motd.kr\/wordpress\/#\/schema\/person\/4430ad90fc2ddeef051565701d85db9d"},"headline":"Modifying Default ulimit Values for a Normal User in Linux","datePublished":"2006-11-21T10:39:00+00:00","dateModified":"2022-12-27T16:46:48+00:00","mainEntityOfPage":{"@id":"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/"},"wordCount":157,"publisher":{"@id":"https:\/\/vault.motd.kr\/wordpress\/#\/schema\/person\/4430ad90fc2ddeef051565701d85db9d"},"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/","url":"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/","name":"Modifying Default ulimit Values for a Normal User in Linux — T's message of the day","isPartOf":{"@id":"https:\/\/vault.motd.kr\/wordpress\/#website"},"datePublished":"2006-11-21T10:39:00+00:00","dateModified":"2022-12-27T16:46:48+00:00","breadcrumb":{"@id":"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/vault.motd.kr\/wordpress\/posts\/1557\/modifying-default-ulimit-values-for-a-normal-user-in-linux\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/vault.motd.kr\/wordpress\/"},{"@type":"ListItem","position":2,"name":"Modifying Default ulimit Values for a Normal User in Linux"}]},{"@type":"WebSite","@id":"https:\/\/vault.motd.kr\/wordpress\/#website","url":"https:\/\/vault.motd.kr\/wordpress\/","name":"T's message of the day","description":"the best is yet to come","publisher":{"@id":"https:\/\/vault.motd.kr\/wordpress\/#\/schema\/person\/4430ad90fc2ddeef051565701d85db9d"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/vault.motd.kr\/wordpress\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/vault.motd.kr\/wordpress\/#\/schema\/person\/4430ad90fc2ddeef051565701d85db9d","name":"Trustin Lee","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/vault.motd.kr\/wordpress\/#\/schema\/person\/image\/","url":"https:\/\/vault.motd.kr\/wordpress\/wp-content\/uploads\/2020\/09\/avatar-2019-966px.png","contentUrl":"https:\/\/vault.motd.kr\/wordpress\/wp-content\/uploads\/2020\/09\/avatar-2019-966px.png","width":966,"height":966,"caption":"Trustin Lee"},"logo":{"@id":"https:\/\/vault.motd.kr\/wordpress\/#\/schema\/person\/image\/"},"sameAs":["https:\/\/t.motd.kr\/","https:\/\/www.facebook.com\/trustin","https:\/\/www.instagram.com\/trustinlee\/","https:\/\/www.linkedin.com\/in\/trustin","https:\/\/twitter.com\/https:\/\/www.twitter.com\/trustin","https:\/\/www.youtube.com\/@trustinlee"]}]}},"_links":{"self":[{"href":"https:\/\/vault.motd.kr\/wordpress\/wp-json\/wp\/v2\/posts\/1557"}],"collection":[{"href":"https:\/\/vault.motd.kr\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/vault.motd.kr\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/vault.motd.kr\/wordpress\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/vault.motd.kr\/wordpress\/wp-json\/wp\/v2\/comments?post=1557"}],"version-history":[{"count":2,"href":"https:\/\/vault.motd.kr\/wordpress\/wp-json\/wp\/v2\/posts\/1557\/revisions"}],"predecessor-version":[{"id":5978,"href":"https:\/\/vault.motd.kr\/wordpress\/wp-json\/wp\/v2\/posts\/1557\/revisions\/5978"}],"wp:attachment":[{"href":"https:\/\/vault.motd.kr\/wordpress\/wp-json\/wp\/v2\/media?parent=1557"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/vault.motd.kr\/wordpress\/wp-json\/wp\/v2\/categories?post=1557"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/vault.motd.kr\/wordpress\/wp-json\/wp\/v2\/tags?post=1557"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}