[rabbitmq-discuss] Increasing the file descriptors limit

Jean Paul Galea ninuhadida at gmail.com
Thu Jan 17 12:26:33 GMT 2013


Hi,

We have made a fresh install of RabbitMQ on a two machine cluster. Both 
machines are running the following software;

Ubuntu 12.04.1 LTS
RabbitMQ 3.0.1
Erlang R15B03

We're trying to increase the file descriptors limits for RabbitMQ to no 
avail. Here's what we did;

~# # check the current nofile value
~# su rabbitmq -s /bin/sh -c 'ulimit -n'
1024

~# # set soft,hard nofile limit for 'rabbitmq' user to 102400
~# cat >> /etc/security/limits.conf << "EOF"
rabbitmq	-	nofile	102400
EOF

~# # pam_limits.so is required for limits.conf to take affect
~# cat >> /etc/pam.d/common-session << "EOF"
session	required	pam_limits.so
EOF

~# # verifies new setting
~# su rabbitmq -s /bin/sh -c 'ulimit -n'
102400

However, RabbitMQ fails to start up with this limit. We have tried 
restarting the RabbitMQ service and also a system reboot.

~# rabbitmqctl status
  {file_descriptors,
 
[{total_limit,924},{total_used,3},{sockets_limit,829},{sockets_used,1}]},

~# rabbitmqctl eval 'proplists:get_value(max_fds, 
erlang:system_info(check_io)).'
1024
...done.

~# su rabbitmq -s /bin/sh -c "rabbitmqctl eval 
'proplists:get_value(max_fds, erlang:system_info(check_io)).'"
1024
...done.

In the log file there appears to be no warnings or errors either:

=INFO REPORT==== 17-Jan-2013::11:46:58 ===
Starting RabbitMQ 3.0.1 on Erlang R15B03

=INFO REPORT==== 17-Jan-2013::11:46:58 ===
Limiting to approx 924 file handles (829 sockets)

Anyone run into the same issue? Perhaps we're missing a small detail?

Thanks,
Jean Paul


More information about the rabbitmq-discuss mailing list