Bug 491473 - guest migration between Intel and AMD fail to start listening VM when they both use Snap5.2
guest migration between Intel and AMD fail to start listening VM when they b...
Status: CLOSED NOTABUG
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: qemu-kvm (Show other bugs)
6.0
All Linux
low Severity medium
: rc
: ---
Assigned To: Amit Shah
: Reopened
Depends On: KvmXVendorMigration
Blocks:
  Show dependency treegraph
 
Reported: 2009-03-21 10:01 EDT by Vivian Bian
Modified: 2016-04-26 11:11 EDT (History)
10 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-05-05 08:44:52 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
rhel5u3 log (894 bytes, text/plain)
2009-03-23 06:37 EDT, Vivian Bian
no flags Details
rhel5u3 guest definition file (1014 bytes, text/plain)
2009-03-23 06:37 EDT, Vivian Bian
no flags Details
after migration ,the log in the Intel box (638 bytes, text/plain)
2009-03-23 06:38 EDT, Vivian Bian
no flags Details
the win2k8 guest definition file (1016 bytes, text/plain)
2009-03-23 06:41 EDT, Vivian Bian
no flags Details
AMD win2k8 guest log (5.51 KB, text/plain)
2009-03-23 06:42 EDT, Vivian Bian
no flags Details
win2k8 guest log in Intel box (874 bytes, text/plain)
2009-03-23 06:43 EDT, Vivian Bian
no flags Details
cpuinfo in 10.66.65.167 ,the source box (1.34 KB, text/plain)
2009-03-23 07:02 EDT, Vivian Bian
no flags Details
cpuinfo in 10.66.70.52.the destination box (1.25 KB, text/plain)
2009-03-23 07:03 EDT, Vivian Bian
no flags Details

  None (edit)
Description Vivian Bian 2009-03-21 10:01:57 EDT
Description of problem:
Install snap5.2 both in Intel and AMD boxes,and then did a migration between the two boxes.Got a libvir:QEMU error: fail to start listening VM,but between a snap4 AMD and snap5.2 Intel migration will be ok. snap4 Intel and snap5 AMD will still be ok.

Version-Release number of selected component (if applicable):
ovirt-node-image-1.0-1.snap5.2.el5ovirt

How reproducible:
Always

Steps to Reproduce:
1.install two snap5.2 in Intel and AMD boxes
2.create a guest on any of the above two boxes
3.# virsh migrate --live $domain_id qemu+tcp://IP/system
  
Actual results:
libvir:QEMU error: fail to start listening VM

Expected results:
the migration will be ok

Additional info:
Comment 1 Vivian Bian 2009-03-22 08:25:20 EDT
(In reply to comment #0)
> Description of problem:
> Install snap5.2 both in Intel and AMD boxes,and then did a migration between
> the two boxes.Got a libvir:QEMU error: fail to start listening VM,but between a
> snap4 AMD and snap5.2 Intel migration will be ok. snap4 Intel and snap5 AMD
> will still be ok.
> 

  the ok guest is an empty one without any system installed.And now I installed win2k3_x86_64(R2).But this guest could not be migrated between the two boxes (both Intel and AMD installed Snap5.2)

  and for the win2k8 system I could migrate it between two AMD boxes,but failed in Intel and AMD
Comment 2 Vivian Bian 2009-03-22 08:27:13 EDT
fail to start listening VM at the first time 
libvir: Remote error :socket closed unexpectedly at the second time
Comment 3 Dor Laor 2009-03-22 08:41:37 EDT
Cross vendor migration is not supported.
Actually it should be forbidden by libvirt.
Comment 4 Lawrence Lim 2009-03-22 10:39:41 EDT
Could you please confirm if its supported on the kvm level?
Comment 5 Daniel Berrange 2009-03-23 05:32:41 EDT
While cross-vendor migration is not supported, I don't believe vbian should be seeing the error messages mentioned in comments 1 or 2.

vbian, can you attach the two files /var/log/libvirt/qemu/$DOMNAME.log  from both the source and destination hosts.
Comment 6 Daniel Berrange 2009-03-23 05:34:16 EDT
Dor, libvirt explicitly restricts its scope to providing 'mechanism', and not 'policy'. As such any restrictions on migration between different CPU types should be enforced by the management application using libvirt, not libvirt itself.
Comment 7 Vivian Bian 2009-03-23 06:36:38 EDT
(In reply to comment #5)
> While cross-vendor migration is not supported, I don't believe vbian should be
> seeing the error messages mentioned in comments 1 or 2.
> 
> vbian, can you attach the two files /var/log/libvirt/qemu/$DOMNAME.log  from
> both the source and destination hosts.  

  migrated win2k8 from AMD to Intel,a running guest hang in the Intel boxes.And I could see no error output.
 
  But please try the attached rhel5u3.xml to define a guest,and then try to migrate it from AMD to Intel.The error referred in comment 2 will be seen.

  Steps:
  # iscsiadm --mode discovery --type sendtargets --portal 10.66.70.7
  # iscsiadm --mode node --targetname dhcp-65-108.nay.redhat.com:storage-pool --portal 10.66.70.7 --login
  # virsh pool-define storage-pool.xml
  # virsh define rhel5u3.xml
  # virsh start rhel5u3
  # virsh migrate --live rhel5u3 qemu+tcp://10.66.70.52/system
    libvir: QEMU error: operation failed: failed to start listening VM
  # virsh migrate --live rhel5u3 qemu+tcp://10.66.70.52/system
    libvir: Remote error: socket closed unexpectedly
    libvir: Remote error: socket closed unexpectedly
Comment 8 Vivian Bian 2009-03-23 06:37:20 EDT
Created attachment 336263 [details]
rhel5u3 log
Comment 9 Vivian Bian 2009-03-23 06:37:52 EDT
Created attachment 336264 [details]
rhel5u3 guest definition file
Comment 10 Vivian Bian 2009-03-23 06:38:40 EDT
Created attachment 336265 [details]
after migration ,the log in the Intel box
Comment 11 Vivian Bian 2009-03-23 06:41:20 EDT
Created attachment 336266 [details]
the win2k8 guest definition file
Comment 12 Vivian Bian 2009-03-23 06:42:37 EDT
Created attachment 336267 [details]
AMD win2k8 guest log
Comment 13 Vivian Bian 2009-03-23 06:43:09 EDT
Created attachment 336268 [details]
win2k8 guest log in Intel box
Comment 14 Daniel Berrange 2009-03-23 06:56:52 EDT
> migrated win2k8 from AMD to Intel,a running guest hang in the Intel boxes.
> And I could see no error output.

Ok, the log shows the libvirt migration option completed successfully. So the resulting hang must just be due to the incompatibility in instruction set between the AMD & Intel CPUs.  

>  But please try the attached rhel5u3.xml to define a guest,and then try to
> migrate it from AMD to Intel.The error referred in comment 2 will be seen.

The log file for this VM contains 

/usr/bin/qemu-kvm -S -M pc -m 3906 -smp 1 [snip more args] -incoming tcp:0.0.0.0:49154 
madvise: Cannot allocate memory
Could not allocate physical memory


So KVM on the destination was unable to allocate memory to start the VM for incoming migration. This is why libvirt gave back the error message for rhel5u3 VM. This is also not a libvirt bug - either the host is OOM, or there is some problem in KVM allocating memory.
Comment 15 Daniel Berrange 2009-03-23 06:57:50 EDT
Re-assigning to KVM to verify whether the 'cannot allocate memory' problem is a real bug or not. If not, can just close this WONTFIX, since cross-vendor migration is expected to not work reliably
Comment 16 Vivian Bian 2009-03-23 07:02:51 EDT
Created attachment 336270 [details]
cpuinfo in 10.66.65.167 ,the source box
Comment 17 Vivian Bian 2009-03-23 07:03:28 EDT
Created attachment 336271 [details]
cpuinfo in 10.66.70.52.the destination box
Comment 18 Vivian Bian 2009-03-23 07:05:06 EDT
worth mentioned I have migrated the win2k8 guest successfully between AMD and Intel ,and it is living now .
Comment 19 Vivian Bian 2009-03-23 09:32:54 EDT
In addition, the win2k8 mentioned in this bug is just a core ,not a full installation,and after I reinstalled a full one,it could not be migrated,and the error is the same with the comment 2
Comment 20 Dor Laor 2009-04-12 10:53:31 EDT

*** This bug has been marked as a duplicate of bug 488489 ***
Comment 21 Eduardo Habkost 2009-04-15 15:15:43 EDT
Moving back to NEW, that was the status before the bug was closed as duplicate.
Comment 22 Dor Laor 2009-04-16 03:53:34 EDT
Since amd-intel is not supported at all I'm closing the bug.
Even if it works it is not supported so please don't try it.
Comment 23 Eduardo Habkost 2009-04-16 08:02:46 EDT
There is a cross-vendor migration bug (bug #488489), proposed for rhev-1.1. Proposing this one for rhev-1.1 too.
Comment 24 RHEL Product and Program Management 2009-06-22 14:47:44 EDT
This request was evaluated by Red Hat Product Management for inclusion in a Red
Hat Enterprise Linux major release.  Product Management has requested further
review of this request by Red Hat Engineering, for potential inclusion in a Red
Hat Enterprise Linux Major release.  This request is not yet committed for
inclusion.
Comment 25 Eduardo Habkost 2010-01-20 06:52:24 EST
On RHEL-6, the KVM userspace package is named "qemu-kvm". Moving bug to the right component.

Note You need to log in before you can comment on or make changes to this bug.