Suddenly we faced the error 'Open file limit ' while login on Linux server and try to run df -h or any other command.
The likely cause of this issue is hitting max "Open file limit". This error indicates that all available file handles for the process have been used.
To resolve this issue we need to increase the size of ulimit -Sn. The ulimit command allow you to control user resource limit is the system such as process data size , virtual memory and process file size , no of processes etc.
Current value of ulimit -Sn is 1024. Here we need to increase the value of ulimit -Sn.
#ulimit -Sn1024
#ulimit -a
core file size (blocks, -c) 0data seg size (kbytes, -d) unlimitedscheduling priority (-e) 0file size (blocks, -f) unlimitedpending signals (-i) 1031260max locked memory (kbytes, -l) 64max memory size (kbytes, -m) unlimitedopen files (-n) 1024pipe size (512 bytes, -p) 8POSIX message queues (bytes, -q) 819200real-time priority (-r) 0stack size (kbytes, -s) 10240cpu time (seconds, -t) unlimitedmax user processes (-u) 1031260virtual memory (kbytes, -v) unlimitedfile locks (-x) unlimited
Increase the limit temporary.
It can be increased temporarily for the current session by setting
#ulimit -Sn 4024
#ulimit -Hn 653223
Increase the limit permanently.
For permanently we need to edit /etc/security/limits.conf for root user or non-root user as well.
#cat /etc/security/limits.conf
####setting for nofile soft limit is 1024
oracle soft nofile 4024* soft nofile 4024
### oracle-rdbms-server-11gR2-preinstall setting for nofile hard limit is 65536
oracle hard nofile 65536* hard nofile 65536
Once you save file, you may need to logout and login again.
Finally verify the value.
[root@***** ~]# ulimit -Sn4096
[root@***** ~]# ulimit -Hn65536
2 comments:
oracle training in noida
oracle training institute in noida
oracle course in noida
oracle institute in noida
oracle training in delhi
oracle training institute in delhi
100% Job Guarantee Classes In Bangalore
https://www.sevenmentor.com/100-job-guarantee-courses-in-bangalore
Post a Comment
Thanks for reading till end. I hope this will help you more to improve your knowledge.
Now it's your turn!
What do you think? Share your experience in the comments box and subscribe for more interesting post.