[Bug 270259] Re: Leaks file descriptors and eventually runs out
Bug Watch Updater
270259 at bugs.launchpad.net
Mon Oct 8 09:47:41 UTC 2012
** Changed in: acpid (Suse)
Importance: Unknown => Critical
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to acpid in Ubuntu.
https://bugs.launchpad.net/bugs/270259
Title:
Leaks file descriptors and eventually runs out
Status in “acpid” package in Ubuntu:
Fix Released
Status in “acpid” source package in Hardy:
Fix Released
Status in “acpid” package in ALT Linux:
Unknown
Status in “acpid” package in Suse:
Fix Released
Bug description:
Binary package hint: acpid
I was performing a stress test which simulated part of system startup
(including starting and stopping (SIGTERM) the X server) in a tight
loop. After 1000 or so iterations, the X server blocked during
startup in connect(), trying to connect to /var/run/acpid.socket.
The acpid log file was 2147483647 bytes and looked like this:
[Sun Sep 14 19:43:54 2008] ERR: can't accept client: Too many open files
[Sun Sep 14 19:43:54 2008] ERR: can't accept client: Too many open files
[Sun Sep 14 19:43:54 2008] ERR: can't accept client: Too many open files
[Sun Sep 14 19:43:54 2008] ERR: can't accept client: Too many open files
[Sun Sep 14 19:43:54 2008] ERR: can't accept client: Too many open files
[Sun Sep 14 19:43:54 2008] ERR: can't accept client: Too many open files
[Sun Sep 14 19:43:54 2008] ERR: can't accept client: Too many open files
[Sun Sep 14 19:43:54 2008] ERR: can't accept client: Too many open files
[Sun Sep 14 19:43:54 2008] ERR: can't accept client: Too many open files
<repeated millions of times>
[Sun Sep 14 19:43:54 2008] E
netstat and /proc/pid/fd showed that it had reached the ulimit for
open file descriptors. At that point, it must have started spewing to
the log, and filled it up, at which point it didn't seem to even
attempt accept(2) anymore.
I could reproduce the fd leak using this simple python program:
Python 2.5.2 (r252:60911, Apr 21 2008, 11:08:23)
[GCC 4.2.3 (Ubuntu 4.2.3-2ubuntu7)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import socket
>>> help(socket)
>>> s = socket.socket(socket.AF_UNIX, socket.SOCK_STREAM)
>>> s.connect('/var/run/acpid.socket')
>>> s.close()
Each time I run this test, acpid gains another fd which never goes
away.
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/acpid/+bug/270259/+subscriptions
More information about the foundations-bugs
mailing list