You are here: Supporting Documents > Stratus Cloud Installation Guide > OpenStack Installation and Configuration > Managing RabbitMQ File Descriptor Limits

Managing RabbitMQ File Descriptor Limits

If you configure OpenStack services to use RabbitMQ for messaging, you must modify the settings on each RabbitMQ node to increase the maximum number of open files or file descriptors.

Many Linux distributions have a soft limit of 1024 files and a hard limit of 4096 files for each user; however, these numbers can be too low for using RabbitMQ in a production environment. Even reaching the soft limit of 1024 open files can raise an alarm in the operating system that prevents the RabbitMQ service from accepting new connections until the alarm clears, which prevents OpenStack services from functioning properly.

To prevent these problems in production environments, the RabbitMQ documentation recommends increasing the maximum number of files for the rabbitmq user to at least 65536 files.

To increase the maximum number of files for RabbitMQ:

  1. Log on to a RabbitMQ node.
  2. Open or create the /etc/default/rabbitmq-server file.
  3. Add or edit the following line in the file to increase the file descriptor limit to at least 65536 files:

    ulimit -n 65536
  4. Save the file and close the text editor.
  5. Restart the RabbitMQ service by entering the following command:

    # service rabbitmq-server restart
  6. Confirm that the new limits are in place by entering the following command:

    # grep -e Limit -e files /proc/$(cat /var/run/rabbitmq/pid)/limits
    Limit               Soft Limit    Hard Limit     Units
    Max open files      65536         65536          files
  7. Repeat the preceding steps to increase the limits on any additional RabbitMQ nodes.
of