On (Thu) 22 Jan 2015 [15:01:36], Alexander Graf wrote: > Migration is a black hole to most people. One of the biggest reasons for > this is that its protocol is a secret, undocumented sauce of code rolling > around random parts of the QEMU code base. > > But what if we simply exposed the description of how the format looks like > alongside the actual migration stream? This is what this patch set does. > > It adds a new section that comes after the end of stream marker (so that it > doesn't slow down migration) that contains a JSON description of the device > state description. > > Along with this patch set also comes a python script that can read said JSON > from a migration dump and decipher the device state and ram contents of the > migration dump using it. > > With this, you can now fully examine all glorious details that go over the > wire when virtual machine state gets dumped, such as during live migration. > > We discussed the approach taken here during KVM Forum 2013. Originally, my > idea > was to include a special device that contains the JSON data which can be > enabled > on demand. Anthony suggested however to just always include the description > data > after the end marker which I think is a great idea.
'make check' fails with this series applied: migration/vmstate.o: In function `vmstate_save_state': qemu/migration/vmstate.c:289: undefined reference to `json_prop_str' qemu/migration/vmstate.c:290: undefined reference to `json_prop_int' qemu/migration/vmstate.c:291: undefined reference to `json_start_array' migration/vmstate.o: In function `vmsd_desc_field_start': qemu/migration/vmstate.c:245: undefined reference to `json_start_object' qemu/migration/vmstate.c:246: undefined reference to `json_prop_str' qemu/migration/vmstate.c:249: undefined reference to `json_prop_int' qemu/migration/vmstate.c:254: undefined reference to `json_prop_str' migration/vmstate.o: In function `vmsd_desc_field_end': qemu/migration/vmstate.c:275: undefined reference to `json_prop_int' qemu/migration/vmstate.c:276: undefined reference to `json_end_object' migration/vmstate.o: In function `vmstate_save_state': qemu/migration/vmstate.c:337: undefined reference to `json_end_array' migration/vmstate.o: In function `vmstate_subsection_save': qemu/migration/vmstate.c:423: undefined reference to `json_start_object' qemu/migration/vmstate.c:434: undefined reference to `json_end_object' qemu/migration/vmstate.c:419: undefined reference to `json_start_array' migration/vmstate.o: In function `vmsd_desc_field_start': qemu/migration/vmstate.c:251: undefined reference to `json_prop_int' migration/vmstate.o: In function `vmsd_desc_field_end': qemu/migration/vmstate.c:272: undefined reference to `json_end_object' migration/vmstate.o: In function `vmsd_desc_field_start': qemu/migration/vmstate.c:257: undefined reference to `json_start_object' migration/vmstate.o: In function `vmstate_subsection_save': qemu/migration/vmstate.c:441: undefined reference to `json_end_array' collect2: error: ld returned 1 exit status qemu/rules.mak:122: recipe for target 'tests/test-vmstate' failed make: *** [tests/test-vmstate] Error 1 Amit