tacho / conman

Automatically exported from code.google.com/p/conman
GNU General Public License v3.0
1 stars 0 forks source link

conmand unable to open logfiles & resolve hostnames: too many open files #17

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

Start conmand with a configuration having a large number of consoles such that 
the requisite number of open files exceeds the NOFILE (number of open files) 
resource hard limit.

What is the expected output? What do you see instead?

conmand logs the following information: 

NOTICE:    Starting ConMan daemon 0.2.7 (pid 1234)
INFO:      Open file limit set to 1024
WARNING:   Unable to open logfile "/var/log/conman/foo509": Too many open files
WARNING:   Unable to resolve hostname "cy15" for [foo509]
WARNING:   Unable to open logfile "/var/log/conman/foo510": Too many open files
WARNING:   Unable to resolve hostname "cy15" for [foo510]
WARNING:   Unable to open logfile "/var/log/conman/foo511": Too many open files
WARNING:   Unable to resolve hostname "cy15" for [foo511]
...

/etc/security/limits.conf defines an increased nofile hard limit, but it is not 
affecting the environment for conmand at boot.

What version of the software are you using? On what operating system?

conman-0.2.7
Red Hat Enterprise Linux Server release 6.2 (Santiago)

Please provide any additional information below.

As of 0.2.0, conmand sets the RLIMIT_NOFILE current "soft" limit to the maximum 
"hard" limit.

/etc/security/limits.conf is the configuration file for the pam_limits module 
which sets limits on the system resources that can be obtained in a 
user-session.  This does not affect daemons started at boot.

One option is to increase the nofile limit in the init script via "ulimit -n 
<num>".

Original issue reported on code.google.com by chris.m.dunlap on 8 Mar 2013 at 12:24

GoogleCodeExporter commented 9 years ago
Adding a new server directive to conman.conf:

  server nofile=<int>

This specifies the maximum number of open files for the daemon.  If set to 0, 
use the current (soft) limit.  If set to -1, use the maximum (hard) limit.  The 
default is 0.

Note that root is able to increase this beyond the resource hard limit.

Original comment by chris.m.dunlap on 8 Mar 2013 at 2:45

GoogleCodeExporter commented 9 years ago
This issue was closed by revision 1cb0709f707d.

Original comment by chris.m.dunlap on 8 Mar 2013 at 2:47