From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47133) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aGkqb-00036T-OR for qemu-devel@nongnu.org; Wed, 06 Jan 2016 04:57:42 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aGkqX-0001d6-H3 for qemu-devel@nongnu.org; Wed, 06 Jan 2016 04:57:41 -0500 Received: from mx1.redhat.com ([209.132.183.28]:52479) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aGkqX-0001cr-Bw for qemu-devel@nongnu.org; Wed, 06 Jan 2016 04:57:37 -0500 Date: Wed, 6 Jan 2016 09:57:32 +0000 From: "Dr. David Alan Gilbert" Message-ID: <20160106095731.GB2528@work-vm> References: <0259E1C966E8C54AA93AA2B1240828E650F34EC8@szxema507-mbs.china.huawei.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <0259E1C966E8C54AA93AA2B1240828E650F34EC8@szxema507-mbs.china.huawei.com> Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] What's the advantages of POSTCOPY over CPU-THROTTLE? List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: "Zhangbo (Oscar)" Cc: "zhouyimin Zhou(Yimin)" , Zhanghailiang , Yanqiangjun , "Huangpeng (Peter)" , "qemu-devel@nongnu.org" , "Herongguang (Stephen)" , Linqiangmin , Huangzhichao , "Wangyufei (James)" * Zhangbo (Oscar) (oscar.zhangbo@huawei.com) wrote: > Hi all: > =E3=80=80=E3=80=80Postcopy is suitable for migrating guests which have = large page change rates. It=20 > 1 makes the guest run at the destination ASAP. > 2 makes the downtime of the guest small enough. > If we don't take the 1st advantage into account, then, its benefit = seems similar with CPU-THROTTLE: both of them make the guest's downtime s= mall during migration. > =20 > CPU-THROTTLE would make the guest's dirtypage rate *smaller than th= e network bandwidth*, in order to make the to_send_page_number in each it= eration convergent and achieve the small-enough downtime during the last = iteration. > If we adopt POST-COPY here, the guest's dirtypage rate would *becom= e equal to the bandwidth*, because we have to fetch its memory from the s= ource side, via the network. > Both of them would introduce performance degradations of the guest,= which may in turn cause downtime larger. >=20 > So, here comes the question: If we just compare POSTCOPY with CPU-T= HROTTLE for their advantages in decreasing downtime, POSTCOPY seems has n= o pos over CPU-THROTTLE, is that right? >=20 > Meanwhile, Are there any other benifits of POSTCOPY besides the 2 m= entioned above? It's a good question and they do both try and help solve the same problem= . One problem with cpu-throttle is whether you can throttle the CPU enough = to get the dirty-rate below the rate of the network, and the answer to that = is very workload dependent. On a large, many-core VM, even a little bit of = CPU can dirty a lot of memory. Postcopy is guaranteed to finish migration, irrespective of the workload. Postcopy is pretty fine-grained, in that only threads that are accessing pages that are still on the source are blocked, since it allows the use of async page faults, that means it's even finer grained than the vCPU le= vel, so many threads come back up to full performance pretty quickly even if there are a few pages left. Dave >=20 > Oscar >=20 > =20 >=20 -- Dr. David Alan Gilbert / dgilbert@redhat.com / Manchester, UK