-
Notifications
You must be signed in to change notification settings - Fork 744
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
Failure to epoll() on armhf #1089
Comments
Some preliminary findings: The problem code seems to be (around) here: https://github.com/seanmonstar/reqwest/blob/45f67c1dccf30ed82d172e31e5dc6ef2b7acf2ea/src/client.rs#L634-L669. The Mio doesn't use any Futexes, so it's likely coming from: https://github.com/seanmonstar/reqwest/blob/45f67c1dccf30ed82d172e31e5dc6ef2b7acf2ea/src/wait.rs#L96-L98?
Is that the entire log? Because that would mean that Mio would be stuck in Version info for the future: As a side note: why is rewqest using async API's to provide a sync API? Why bother with all that complexity if you're not going to take advantage of the benefits? (genuine question) |
Thank you @Thomasdezeeuw for that analysis. I agree that reqwest probably is what is introducing the 30s timeout -- Given reqwest's implementation of waiting, could it simply be that on armhf there are insufficient threads in the worker pool so none of the futures/connections can make progress? If so, I suppose I ought to reassign this to reqwest. |
Maybe, but I don't know for sure. It could really help if you can determine how long the call to |
I've asked the person who made the straces if they can do another with extra timing data, but if the epoll_ctl() was stuck, I'd expect to see it |
@Thomasdezeeuw From another run, that
So it's got to be something other than that getting stuck |
I don't think this a problem with Mio then. It think it somewhere between reqwest and Tokio, maybe how one uses the API of the other (is reqwest driving Tokio's reactor in some way?). I would normally expect an |
Thanks for your time then, I'll try attacking this from the reqwest side of things. |
Hi,
I, and a friend (@cjwatson), have been trying to diagnose a problem whereby
rustup
onarmhf
is failing to connect to a web proxy when usingreqwest
which is built onhyper
and thencetokio
and thusmio
ultimately.On amd64 (x86_64) it runs perfectly well, but on armhf it sits for 30s and times out the connect.
By stracing the entire build, eventually we were able to find the following syscall sequence on armhf:
Importantly you can see the futex for the 30s timeout, the connect starting, being added to the epoll, but then nothing occurring for 30s and the futex timing out. The thread which called epoll_ctl() never seems to call anything else and eventually exits at the end of the process.
By comparison, running on amd64 (x86_64):
Where the connect is in progress, gets added to the epoll, and then the same thread enters epoll_wait() succeeds, and the connection proceeds as expected.
I'm unsure if this is mio or tokio at fault, but I figured this was the right place to start.
This is the armhf log: buildlog_snap_ubuntu_bionic_armhf_rust-snap-test_BUILDING.txt.gz
The amd64 log I have, but is 50M so I can't paste it here and I'm not sure it'd help that much.
If this is not the right place, please let me know and I'll re-file appropriately.
Thanks,
D.
The text was updated successfully, but these errors were encountered: