Skip to contentSkip to conversation

Xend transaction reduction breaks migration

DISCUSSION Keir Fraser 2 participants 5 messages Nov 14, 2007 – Nov 16, 2007

lore
Share & tools
lore
#0 lore raw

Hey Daniel,

It turns out that your changeset 16260 in xen-unstable breaks our localhost non-live migration tests. What happens is that randomly (but fairly often) xend will throw an assertion at line 'assert console_port' in XendCheckpoint.py. This is in the domain_restore_fd context, so result is that the restorer dies and then of course the saver fails soon after since the migration socket goes away.

Any idea how your patch could cause this rather bizarre behaviour? I haven't worked it out myself, though I'm 99% sure it *is* that changeset that has caused this regression (based on tests with the changeset reverted).

It's currently the only blocker in our automated tests on the staging tree, and blocks pushing to the main xen-unstable tree. :-)

Thanks,
Keir

#1 lore raw
Quoted 9 lines · Keir Fraser

Hey Daniel,

It turns out that your changeset 16260 in xen-unstable breaks our localhost non-live migration tests. What happens is that randomly (but fairly often) xend will throw an assertion at line 'assert console_port' in XendCheckpoint.py. This is in the domain_restore_fd context, so result is that the restorer dies and then of course the saver fails soon after since the migration socket goes away.

Quoted 3 lines

Any idea how your patch could cause this rather bizarre behaviour? I haven't worked it out myself, though I'm 99% sure it *is* that changeset that has caused this regression (based on tests with the changeset reverted).

Basically, instead of doing many small transactions, my change made some stuff all happen in one large transaction. Oddly though, I tried to be careful so that I only changed the codepath for the 'xm list' operation (well the SEXPR call to the list operation). Other operations like create, save, restore ought to be left using fine grained transactions as before.

Dan.

Signature · 4 lines
|=- Red Hat, Engineering, Emerging Technologies, Boston.  +1 978 392 2496 -=|
|=-           Perl modules: http://search.cpan.org/~danberr/              -=|
|=-               Projects: http://freshmeat.net/~danielpb/               -=|
|=-  GnuPG: 7D3B9505   F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505  -=| 
#2 lore raw
Quoted 9 lines · Daniel P. Berrange
Quoted 3 lines

Any idea how your patch could cause this rather bizarre behaviour? I haven't worked it out myself, though I'm 99% sure it *is* that changeset that has caused this regression (based on tests with the changeset reverted).

Basically, instead of doing many small transactions, my change made some stuff all happen in one large transaction. Oddly though, I tried to be careful so that I only changed the codepath for the 'xm list' operation (well the SEXPR call to the list operation). Other operations like create, save, restore ought to be left using fine grained transactions as before.

I'll have another look at nearby changesets in xen-unstable then. Yours doesn't really look all that likely to cause this problem, except that the empirical evidence does point at it.

-- Keir

#3 lore raw
Quoted 10 lines · Keir Fraser
Quoted 4 lines · Daniel P. Berrange

all happen in one large transaction. Oddly though, I tried to be careful so that I only changed the codepath for the 'xm list' operation (well the SEXPR call to the list operation). Other operations like create, save, restore ought to be left using fine grained transactions as before.

I'll have another look at nearby changesets in xen-unstable then. Yours doesn't really look all that likely to cause this problem, except that the empirical evidence does point at it.

It is your patch. The readDomTxn() functions and friends should prepend the dompath, not the vmpath.

We wouldn't notice this normally since self.console_port is not actually really used after domain building. So we have to race the migration thread to get the assertion to fire, and that happens fairly rarely.

-- Keir

#4 lore raw
Quoted 9 lines · Keir Fraser
Quoted 7 lines · Keir Fraser
Quoted 4 lines · Daniel P. Berrange

all happen in one large transaction. Oddly though, I tried to be careful so that I only changed the codepath for the 'xm list' operation (well the SEXPR call to the list operation). Other operations like create, save, restore ought to be left using fine grained transactions as before.

Quoted 6 lines
Quoted 3 lines

I'll have another look at nearby changesets in xen-unstable then. Yours doesn't really look all that likely to cause this problem, except that the empirical evidence does point at it.

It is your patch. The readDomTxn() functions and friends should prepend the dompath, not the vmpath.

Aha. Thanks for finding & fixing that.

Dan.

Signature · 4 lines
|=- Red Hat, Engineering, Emerging Technologies, Boston.  +1 978 392 2496 -=|
|=-           Perl modules: http://search.cpan.org/~danberr/              -=|
|=-               Projects: http://freshmeat.net/~danielpb/               -=|
|=-  GnuPG: 7D3B9505   F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505  -=|