[squid-users] socket failure: (24) Too many open files
Antony Stone
Antony.Stone at squid.open.source.it
Fri Oct 5 21:06:04 UTC 2018
On Friday 05 October 2018 at 22:08:16, Cherukuri, Naresh wrote:
> For just squid process open files count.
>
> [root at squidprod ~]# lsof -c squid | wc -l
> 4385
Squid is not the only thing running on this machine...
> [root at squidprod ~]# lsof | wc -l
> 10875
But you seem to have sufficient file descriptors configured *in Squid* (but maybe
not in the O/S):
> [root at squidprod ~]# cat /etc/squid/squid.conf | grep "max_filedescriptors"
> max_filedescriptors 8192
So, Squid can have 8192 FDs.
> ulimit -a value
> [root at squidprod ~]# ulimit -a
> open files (-n) 8192
...and the system will provide 8192 FDs for every process combined...
> [root at squidprod ~]# lsof | wc -l
> 10875
I reckon that may well be your problem - you have a system-wide limit of 8192
file descriptors, and yet you are trying to use 10875 open files (this will
include local pipes, sockets, etc, so it's understandable that it's higher,
but it indicates you're going over the limit).
> Thanks,
> Naresh
And, as I asked previously:
What do "cat /proc/sys/fs/file-max" and "cat /proc/sys/fs/file-nr" tell you?
How many users do you have, what sort of number of connections per
second/minute/hour (whatever is convenient for you to express) do you have
going through this machine?
Antony.
--
A good conversation is like a miniskirt;
short enought to retain interest,
but long enough to cover the subject.
- Celeste Headlee
Please reply to the list;
please *don't* CC me.
More information about the squid-users
mailing list