Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

XrdSysIOEvents can go into an EAGAIN loop #303

Closed
abh3 opened this issue Nov 23, 2015 · 0 comments
Closed

XrdSysIOEvents can go into an EAGAIN loop #303

abh3 opened this issue Nov 23, 2015 · 0 comments

Comments

@abh3
Copy link
Member

abh3 commented Nov 23, 2015

It is possible for Linux (and only Linux) to return EPOLLHUP + EPOLLIN when calling epoll_wait(). Unformtuantely,, XrdSysIOEvents first checks EPOLLIN and decides that everything is OK when, in fact, it is not because EPOLLHUP is also set. The subsequent read will then return EAGAIN going back to epoll_wait(); creating a loop. Eventually, the loop resolves itself when the socket is actually closed on the other end. However, that may take a while. The solution is to make sure no other "bad" bits are set when epoll_wait() indicates a socket is ready to read from. This appears to be a known issue and has hit other epoll event handlers out in the field.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant