From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:44088) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aO6kE-000821-NY for qemu-devel@nongnu.org; Tue, 26 Jan 2016 11:45:31 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aO6kA-0005GK-FW for qemu-devel@nongnu.org; Tue, 26 Jan 2016 11:45:30 -0500 Received: from mx1.redhat.com ([209.132.183.28]:13840) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aO6kA-0005Ft-9Z for qemu-devel@nongnu.org; Tue, 26 Jan 2016 11:45:26 -0500 Date: Tue, 26 Jan 2016 16:45:21 +0000 From: "Daniel P. Berrange" Message-ID: <20160126164521.GK15172@redhat.com> References: <56A7A1A8.4060704@windriver.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <56A7A1A8.4060704@windriver.com> Subject: Re: [Qemu-devel] high outage times for qemu virtio network links during live migration, trying to debug Reply-To: "Daniel P. Berrange" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Chris Friesen Cc: libvir-list@redhat.com, qemu-devel@nongnu.org On Tue, Jan 26, 2016 at 10:41:12AM -0600, Chris Friesen wrote: > Hi, > > I'm using libvirt (1.2.12) with qemu (2.2.0) in the context of OpenStack. > > If I live-migrate a guest with virtio network interfaces, I see a ~1200msec > delay in processing the network packets, and several hundred of them get > dropped. I get the dropped packets, but I'm not sure why the delay is > there. > > I instrumented qemu and libvirt, and the strange thing is that this delay > seems to happen before qemu actually starts doing any migration-related > work. (i.e. before qmp_migrate() is called) > > Looking at my timestamps, the start of the glitch seems to coincide with > libvirtd calling qemuDomainMigratePrepareTunnel3Params(), and the end of the > glitch occurs when the migration is complete and we're up and running on the > destination. > > My question is, why doesn't qemu continue processing virtio packets while > the dirty page scanning and memory transfer over the network is proceeding? The qemuDomainMigratePrepareTunnel3Params() method is responsible for starting the QEMU process on the target host. This should not normally have any impact on host networking connectivity, since the CPUs on that target QEMU wouldn't be running at that point. Perhaps the mere act of starting QEMU and plugging the TAP dev into the network on the target host causes some issue though ? eg are you using a bridge that is doing STP or something like that. Regards, Daniel -- |: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :| |: http://libvirt.org -o- http://virt-manager.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|