[erlang-questions] stress test with tcp_server
Mon Jul 2 13:03:30 CEST 2007
Gaspar Chilingarov wrote:
> Jeremy Chow wrote:
>> I've tried use command ulimit to increase the file descriptors number to
>> but the connections number was no more than 1024, sometimes is 1017,
>> sometimes is 1018.
> it depends how much files descriptors already allocated by this user at
> the moment -- because file descriptor limit is set for users and not for
> 1 process.
> Anyway, after some experiments with FreeBSD I was able to push max
> connection count to 4999 open connections
> You should tune sysctl's to increase a hard limits
> kern.maxfiles: 25000
> kern.maxfilesperproc: 20000
> I've also tried to increase kern.ipc.nmbclusters=64000 but without success.
> Are there any limit in 5000 FD's hard coded in erlang???
No, but if I remember correctly FreeBSD also has a setting for max
sockets per process, not only FD's (this could be another BSD though).
Also, depending on the application the maximum number of processes (+P)
can affect the situation.
$ sysctl -a | grep max might give hints :)
I've had over 20000 connections without problems using FreeBSD.
> Setting ERL_MAX_PORTS also does not change the situation.
Erlang Training and Consulting
More information about the erlang-questions