How do common users increase the maximum number of files?
Source: Internet
Author: User
How to increase the maximum number of files a common user ran a program on the server yesterday, and the error java.net. socketException: Toomanyopenfiles. you can use ulimit-a to check that the value of openfiles is 1024. you just want to increase the value and run the program...
How can a common user increase the maximum number of files to run a program on the server yesterday? the error "java.net. socketException: Too program open files ". you can use ulimit-a to check that the value of open files is 1024. you just want to increase the value and run ulimit-n 4096, the result shows that "ulimit: open files: cannot modify limit: The operation is not allowed." It is not a change, but a common user can only change the size, but cannot change the size ..... you can change the root user as needed, but the root user can only change the root user. Then I searched the internet and found that www.2cto.com could be modified by modifying/etc/security/limits. to solve this problem, add two configurations in the conf file. the Java code * soft nofile 65535 * hard nofile 65535 requires the root user to have the permission to modify the file. After the change, the user logs on again, and then ulimit-a checks that the number of open files is 65535.
Author swordinhand
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.