Skip to contentSkip to conversation

Should migration with slirp networking (-netdev user) be backward compatible?

Qemu-devel Guenther Hutzl 2 participants 2 messages Jun 13, 2016

lore
Share & tools
lore
#0 lore raw

Hello!

I have a problem with migration from qemu-v2.6.0 to qemu-v2.5.0. It looks like the slirp networking (-netdev user) is not backward compatible. This is the output I am seeing on the receiving side:

qemu-system-x86_64: savevm: unsupported version 4 for 'slirp' v3
qemu-system-x86_64: load of migration failed: Invalid argument

This is the little test machine I am trying to migrate (using tiny core linux iso):

qemu-system-x86_64-2.6.0 -machine pc-i440fx-2.5 \
-m 512 \
-cdrom core-current.iso \
-boot d \
-nographic \
-curses \
-netdev user,id=mynet0 \
-device virtio-net,netdev=mynet0,id=net0

The target machine looks like this:

qemu-system-x86_64-2.5.0 -machine pc-i440fx-2.5 \
-m 512 \
-cdrom core-current.iso \
-boot d \
-nographic \
-curses \
-netdev user,id=mynet0 \
-device virtio-net,netdev=mynet0,id=net0 \
-incoming tcp:0:4444

I am selecting a v2.5-compatible machine so migration to qemu-2.5 should be possible. The question is: Is the migration of slirp networking backward compatible or is this unsupported for some reason?

I tested migration from v2.6 to v2.6 with this configuration and it worked.

Thank you,

Guenther Hutzl.

IBM Deutschland Research & Development GmbH Vorsitzende des Aufsichtsrats: Martina Koederitz Geschäftsführung: Dirk Wittkopp
Sitz der Gesellschaft: Böblingen
Registergericht: Amtsgericht Stuttgart, HRB 243294

#1 lore raw
Quoted 32 lines · Guenther Hutzl

Hello!

I have a problem with migration from qemu-v2.6.0 to qemu-v2.5.0. It looks like the slirp networking (-netdev user) is not backward compatible. This is the output I am seeing on the receiving side:

qemu-system-x86_64: savevm: unsupported version 4 for 'slirp' v3
qemu-system-x86_64: load of migration failed: Invalid argument

This is the little test machine I am trying to migrate (using tiny core linux iso):

qemu-system-x86_64-2.6.0 -machine pc-i440fx-2.5 \

(quoted diff) +0 -7
-m 512 \
-cdrom core-current.iso \
-boot d \
-nographic \
-curses \
-netdev user,id=mynet0 \
-device virtio-net,netdev=mynet0,id=net0

The target machine looks like this:

qemu-system-x86_64-2.5.0 -machine pc-i440fx-2.5 \

(quoted diff) +0 -8
-m 512 \
-cdrom core-current.iso \
-boot d \
-nographic \
-curses \
-netdev user,id=mynet0 \
-device virtio-net,netdev=mynet0,id=net0 \
-incoming tcp:0:4444
Quoted 3 lines

I am selecting a v2.5-compatible machine so migration to qemu-2.5 should be possible. The question is: Is the migration of slirp networking backward compatible or is this unsupported for some reason?

Selecting an "old" machine type only ensures that the same hardware is visible to the guest as in old QEMU, i.e. that your guest will not break due to buggy drivers or anything like that. It is also necessary for new->old migration, but it's not sufficient. In general we _try_ to make migration backwards-compatible, but it's one of the most common sources of headaches and bugs so it is sometimes broken on purpose (and with a decent error message).

In this case, SLIRP's migration format was broken because support was added for IPv6. New QEMU knows how to load from old QEMU, but not the other way round.

Paolo