Re: gvfsd-http runs out of file descriptors: many sockets in CLOSE_WAIT state



On Wed, Jun 18, 2014 at 07:32:18PM +0200, Matteo Settenvini wrote:

Dear gvfs developers,

it's some times I have noticed an unwanted behaviour of gvfsd-http.
That is, sockets used to retrieve files over the network stay in the
CLOSE_WAIT state for ages... and thus the number of FDs is growing and
growing. I have a long-running program I wrote (and I know also for
Rhythmbox this was an issue), which soon runs out of file descriptors,
leading to a failure.

To help better seeing the problem, I have written a small program using
Gtkmm, which exhibits the issue. It is attached here. To see it run out
of file descriptors, increase the amount of fetches to 1001.

I tried digging into GDaemonFile's source, which I think is the client
counterpart to gvfsd-http, and I *think* the problem is at least that,
upon destruction of the GFile it subtypes, gvfsd-http does not get
notified to close the socket. In alternative, closing the socket upon a
call to g_file_read_finish(), inside GIO, might be the correct think to
do.

I would like to know if this is a bug in gvfs, gio, or my program, and
in the former cases if I should submit it to Bugzilla.


This bug has been logged before as gvfs bug 639777 and was tracked down
as libsoup bug 695652.  If you're having this issue even though you're
using a recent version of libsoup, please open a new bug on GNOME
Bugzilla against gvfs.

Thanks,
-- 
Ross Lagerwall


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]