From: Ian Murray Subject: Re: xl save but leave domain paused Date: Sun, 9 Jun 2013 22:41:24 +0100 (BST) Message-ID: <1370814084.74351.YahooMailNeo@web171301.mail.ir2.yahoo.com> References: <51A7C8BE.4050306@yahoo.co.uk> <1370356105.24512.110.camel@zakaz.uk.xensource.com> Reply-To: Ian Murray Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Return-path: In-Reply-To: <1370356105.24512.110.camel@zakaz.uk.xensource.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Ian Campbell Cc: "xen-devel@lists.xen.org" List-Id: xen-devel@lists.xenproject.org Thanks for reading and responding > = > Does it work if you simply do the pause before the resume? Looking at > the hypervisor side it appears that pauses are referenced counted and it > looks (based on a cursory glance) that it will do the right thing. > = I tried this before and it didn't seems to work. However, it seems to worki= ng now, having repeated the exercise. >From memory It seemed to leave the domain in either a "pss" or similar unhe= althy state (I don't remember exactly). I have since discovered this may be= a different issue around suspending/checkpointing using a CentOS 5.x Xen k= ernel and also I was working with a domain I broke because of experimentati= on. Anyway, I will spend more time testing this solution. >> =A0 I have looked at the corresponding xc calls but meddling with = >> those is way beyond my knowledge. Another way of looking at the problem = >> would be able to perform an xl save on a paused domain, as this would = >> achieve the same result. > = > OOI what happens if you try that? As far as I remember it complained that the domain didn't respond to the su= spend request. I was going to repeat the exercise but that seems like a moo= t point now. > = >> (Against RELEASE-4.2.2) > = > FYI any eventual patch will need to be against unstable and then > considered separately for backporting. Sure. I just needed a working place to start. If I was to prepare a patch against unstable, would it be accepted? The code I ended up with was (which is what I think you expected):- =A0=A0=A0 if (leavepaused || checkpoint || rc < 0) { =A0=A0=A0=A0=A0=A0=A0 if (leavepaused && ! (rc < 0)) { =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 libxl_domain_pause(ctx, domid); =A0=A0=A0=A0=A0=A0=A0=A0=A0=A0=A0 fprintf(stderr, "Pausing before resume\n"= ); =A0=A0=A0=A0=A0=A0=A0 } =A0=A0=A0=A0=A0=A0=A0 libxl_domain_resume(ctx, domid, 1, 0); =A0=A0=A0 } =A0=A0=A0 else =A0=A0=A0=A0=A0=A0=A0=A0 libxl_domain_destroy(ctx, domid, 0); > = > Ian. > =