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 ebl...@redhat.com +1-919-301-3266 Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature