From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46303) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XqXbx-0007YW-0V for qemu-devel@nongnu.org; Mon, 17 Nov 2014 20:29:45 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1XqXbs-00019s-3A for qemu-devel@nongnu.org; Mon, 17 Nov 2014 20:29:40 -0500 Received: from [58.251.49.30] (port=60518 helo=mail.sangfor.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1XqXbr-00019C-O1 for qemu-devel@nongnu.org; Mon, 17 Nov 2014 20:29:36 -0500 Date: Tue, 18 Nov 2014 09:29:16 +0800 From: "=?utf-8?B?WmhhbmcgSGFveXU=?=" References: Message-ID: <201411180929134821865@sangfor.com> Mime-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] =?utf-8?q?Where_is_the_VM_live_migration_code=3F?= List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: =?utf-8?B?Smlkb25nIFhpYW8=?= , =?utf-8?B?S1ZN?= , =?utf-8?B?cWVtdS1kZXZlbA==?= > Hi, > > I saw this page: > > http://www.linux-kvm.org/page/Migration. > > It looks like Migration is a feature provided by KVM? But when I look > at the Linux kernel source code, i.e., virt/kvm, and arch/x86/kvm, I > don't see the code for this migration feature. > Most of live migration code is in qemu migration.c, savevm.c, arch_init.c, block-migration.c, and the other devices's save/load handler, .etc, only log/sync dirty page implemented in kernel. You can read the most important function migration_thread(), process_incoming_migration_co(). > So I wonder where is the source code for the live migration? Is it >purely implemented in user space? Because I see there are the > following files in the qemu source code: > > migration.c migration-exec.c migration-fd.c migration-rdma.c > migration-tcp.c migration-unix.c > > If I wish to understand the implementation of migration in Qemu/KVM, > are these above files the ones I should read? Thanks. > > -Jidong