From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47529) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dmcRY-0000Yn-Od for qemu-devel@nongnu.org; Tue, 29 Aug 2017 05:04:22 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dmcRU-0004ae-Lw for qemu-devel@nongnu.org; Tue, 29 Aug 2017 05:04:20 -0400 Received: from mail-io0-x22f.google.com ([2607:f8b0:4001:c06::22f]:37733) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dmcRU-0004Zw-GS for qemu-devel@nongnu.org; Tue, 29 Aug 2017 05:04:16 -0400 Received: by mail-io0-x22f.google.com with SMTP id d81so15389431ioj.4 for ; Tue, 29 Aug 2017 02:04:15 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: References: From: Sameeh Jubran Date: Tue, 29 Aug 2017 12:04:13 +0300 Message-ID: Content-Type: text/plain; charset="UTF-8" Subject: Re: [Qemu-devel] [QGA] Bug of qga? List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Sam Cc: QEMU Developers , qemu-discuss@nongnu.org Hi Sam, Thanks for reporting this, in order to debug this efficiently I need you to provide me with more info, if you can provide it that would be great. Can you reproduce the issue with ncat? You can use ncat to connect to the socket by running the following command: nc -U /tmp/qga.sock Which OS are you running? Which qemu-ga version are you running? can you reproduce with upstream qemu-ga? On Tue, Aug 29, 2017 at 9:19 AM, Sam wrote: > So how to fix this bug? And where should I to report bug? > > 2017-08-29 13:52 GMT+08:00 Sam : > > > I could repeat this several times, I think it's mis-order of qmp in qga > > socket. > > > > 2017-08-25 11:09 GMT+08:00 Sam : > > > >> Also I found: > >> > >> when I use `socat` to take a qga socket, then I use `socat` to > >> communicate it will got error. > >> But also SOMETIMES, I will not got error and will communicate OK. > >> > >> If one user take qga socket, another user should got error, is it? But > >> why sometimes, the communicate is OK? > >> > >> 2017-08-25 10:11 GMT+08:00 Sam : > >> > >>> Hi all, > >>> > >>> I'm using qga to send `route -n` and `ping` command to guest. But I > >>> found SOMETIMES, the second `ping` command's result is the same as > `route > >>> -n` command. > >>> > >>> So I guess is there some cache mechanism of qga command result? So when > >>> I send the second command, and receive from qga socket, I receive the > >>> result of first command. > >>> > >>> Or is this bug happened because of I use async mechanism of python code > >>> to operate qga socket? > >>> > >>> This is the python code I use to operate on this qga socket: > >>> > >>> try: > >>>> sock=socket(AF_UNIX, SOCK_STREAM) > >>>> sock.settimeout(20) > >>>> sock.connect(vm_qga_sockpath) > >>>> sock.send(cmd) > >>>> while True: > >>>> res = sock.recv(1024) > >>>> if len(res): > >>>> break > >>>> except Exception as e: > >>>> res = -1 > >>>> finally: > >>>> sock.settimeout(None) > >>>> sock.close() > >>> > >>> > >> > > > -- Respectfully, *Sameeh Jubran* *Linkedin * *Software Engineer @ Daynix .*