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

Re: xenstored file descriptor leak



On 03.02.21 09:16, Manuel Bouyer wrote:
On Wed, Feb 03, 2021 at 09:05:27AM +0100, Jürgen Groß wrote:
[...]
Yes, I think this is a good idea.

Well, after some sleep I don't think it is. We should always keep at last
POLLIN or we will never notice a socket close otherwise.

Adding the fd of an ignored socket connection to the list is the real
problem here. Why should that be done?

If we don't do it, we never notice when the socket is closed and the file
descriptor will stay forever. When I tried it, I had about 50 zombie
file descriptors open in xenstored, after starting only 2 domains.

This shouldn't happen in case we are closing the socket actively.

In the end we should just do a talloc_free(conn) in
ignore_connection() if it is a socket based one. This should revert
the critical modification of the XSA-115 fixes for sockets while
keeping the desired effect for domain connections.


Juergen

Attachment: OpenPGP_0xB0DE9DD628BF132F.asc
Description: application/pgp-keys

Attachment: OpenPGP_signature
Description: OpenPGP digital signature


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.