From: Sam Liao <phyomh@gmail.com>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] [slirp] guest program's tcp connection hang on close_wait.
Date: Mon, 21 Dec 2009 10:41:12 +0800 [thread overview]
Message-ID: <da5b0fda0912201841o67b1595ayea34bf55ef8ed712@mail.gmail.com> (raw)
Hi All,
I am using qemu-arm running linux (guest), I start a server
program on the linux(guest); then I start a program on host machine to
connect to the server(on qemu linux guest) to a specified tcp port.
(the qemu is started with tcp redir configuration).
Then I got a problem when the client program on host closed the
tcp connection when the server is busy sending data to client. The
server program will hang on close_wait state. I captured the tcp
packets between the host <-> qemu and qemu<->guest linux. It seems
like the connection is closed like:
1. host <-> qemu
FIN -->
<-- ACK
<-- More data with PUSH
RST -->
2. qemu <-> guest
FIN -->
<-- ACK
<-- More data
ACK -->
<-- More data
ACK -->
...
ACK, zero window->
<- Keep-Alive
ACK, zero window->
<- keep alive
So, here the connection between the qemu and guest did not closed
correctly. After the qemu's FIN is acked by guest os, the qemu still
receives data until it's
window came to be zero(which I think maybe the receive buf is filled),
then it came to a zerowindow-keepalive loop, and the connection is
hanging there. I checked the slirp's source code, from the packet
between host and qemu, the host connection is reset, and the problem
is the connection between qemu and guest is not correctly closed by
slirp.
I'm not sure this is a slirp bug or something else, any suggestion
would be appreciated.
Thanks.
-Sam
reply other threads:[~2009-12-21 2:41 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=da5b0fda0912201841o67b1595ayea34bf55ef8ed712@mail.gmail.com \
--to=phyomh@gmail.com \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).