Migration over RDMA failed since commit: 294e5a4034 ("multifd: Only flush once each full round of memory") with erors: qemu-system-x86_64: rdma: Too many requests in this message (3638950032).Bailing.
migration with RDMA is different from tcp. RDMA has its own control message, and all traffic between RDMA_CONTROL_REGISTER_REQUEST and RDMA_CONTROL_REGISTER_FINISHED should not be disturbed. find_dirty_block() will be called during RDMA_CONTROL_REGISTER_REQUEST and RDMA_CONTROL_REGISTER_FINISHED, it will send a extra traffic( RAM_SAVE_FLAG_MULTIFD_FLUSH) to destination and cause migration to fail even though multifd is disabled. This change make migrate_multifd_flush_after_each_section() return true when multifd is disabled, that also means RAM_SAVE_FLAG_MULTIFD_FLUSH will not be sent to destination any more when multifd is disabled. Fixes: 294e5a4034 ("multifd: Only flush once each full round of memory") CC: Fabiano Rosas <faro...@suse.de> Signed-off-by: Li Zhijian <lizhij...@fujitsu.com> --- V2: put that check at the entry of migrate_multifd_flush_after_each_section() # Peter --- migration/options.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/migration/options.c b/migration/options.c index 1d1e1321b0..327bcf2fbe 100644 --- a/migration/options.c +++ b/migration/options.c @@ -368,7 +368,7 @@ bool migrate_multifd_flush_after_each_section(void) { MigrationState *s = migrate_get_current(); - return s->multifd_flush_after_each_section; + return !migrate_multifd() || s->multifd_flush_after_each_section; } bool migrate_postcopy(void) -- 2.31.1