[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] Guest-sync-delimited and sentinel issue
From: |
Eric Blake |
Subject: |
Re: [Qemu-devel] Guest-sync-delimited and sentinel issue |
Date: |
Fri, 16 Mar 2012 09:07:26 -0600 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:10.0.1) Gecko/20120216 Thunderbird/10.0.1 |
On 03/16/2012 06:47 AM, Michal Privoznik wrote:
> Hi guys,
>
> I was just implementing support for guest-sync-delimited into libvirt. My
> intent is to issue this command prior any other command to determine if GA is
> available or not. The big advantage is - it doesn't change the state of the
> guest so from libvirt POV it's harmless. The other big advantage is this
> sentinel byte 0xFF which is supposed to flush all unprocessed (and possibly
> stale) data from previous unsuccessful tries.
>
> As written in documentation, this command will output sentinel byte to the
> guest agent socket. This works perfectly. However, it is advised in the very
> same documentation to prepend this command with the sentinel as well allowing
> GA parser flush. But this doesn't work for me completely. All I can get is:
>
> $ echo -e "\xFF{\"execute\":\"guest-sync-delimited\",
> \"arguments\":{\"id\":1234}}" | nc -U /tmp/ga.sock | hexdump -C
side note - echo -e is non-portable; I would have written this as:
printf '\xff{"execute":"guest-sync-delimited", "arguments":{"id":1234}}'
--
Eric Blake address@hidden +1-919-301-3266
Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature