[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt-users] QEMU hook on restore

On 2012. February 10. 11:45:49 Eric Blake wrote:
> On 02/10/2012 05:43 AM, Székelyi Szabolcs wrote:
> > I'm using libvirt 0.8.3. It looks like to me that when a QEMU domain is
> > restored from save, the hook is called with the "stopped end -"
> > arguments.
> That sounds like a bug, although I haven't yet looked in the code to see
> for sure.  Are you sure you are not getting confused with the hook
> invocation issued at the time the save completes?

Yes. A few days have passed between the save and restore. I'm logging to 
syslog from the hook scripts, and the timestamps clearly confirm this.

> At any rate, I agree
> that both saving and restoring a domain should trigger hooks, and that
> we ought to make sure the hook arguments are recognizable as distinct
> from normal stop and start events.
> > I've also noticed that the domain description passed to the hook script
> > doesn't contain the network device the host will be attached to (XPath:
> > /domain/devices/interface/target/@dev).
> This is a different question; right now it is a feature that we don't
> ever expose the actual network device through dumpxml to the user.

That's strange, since the same hook is definitely provided this info when the 
domain is started from scratch (in contrary to when it's restored).

> But
> given your use case of a hook, we might have a reason to do it after
> all.

This particular hook sets up L2 firewalls to provide virtual network isolation; 
thus is has to know the host interface to assemble the correct ebtables rules.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]