April 2024
M T W T F S S
1234567
891011121314
15161718192021
22232425262728
2930  

Categories

April 2024
M T W T F S S
1234567
891011121314
15161718192021
22232425262728
2930  

maximum-number-of-file-descriptors-rhel-centos

cat /proc/sys/fs/file-max
589420
The output tells us it is set to 589420.
The vendor asked for this to be increased to 1639200. We can add change the value immediately by executing:
# sysctl -w fs.file-max=1639200
To make this a permanent setting applied everytime the system reboots an edit of /etc/sysctl.conf file is required. Add:
fs.file-max = 1639200
Save the changes to the file and execute sysctl -p, this will put the changes into effect.
# sysctl -p
net.ipv4.ip_forward = 0
net.ipv4.conf.default.rp_filter = 1
net.ipv4.conf.default.accept_source_route = 0
kernel.sysrq = 0
kernel.core_uses_pid = 1
net.ipv4.tcp_syncookies = 1
net.bridge.bridge-nf-call-ip6tables = 0
net.bridge.bridge-nf-call-iptables = 0
net.bridge.bridge-nf-call-arptables = 0
kernel.msgmnb = 65536
kernel.msgmax = 65536
kernel.shmmax = 68719476736
kernel.shmall = 4294967296
fs.file-max = 1639200
Thats all there is to it!

Leave a Reply

You can use these HTML tags

<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>