Public bug reported:

== Comment: #0 - Satheesh Rajendran <sathe...@in.ibm.com> - 2016-09-26 07:12:52 
==
---Problem Description---
VM creation fails for wrong machine type from virt-install.

>From the initial debugging it looks like pseries-2.7 is not listed as a
supported machine type from qemu-system-ppc64 but the virsh capabilities
lists as default, hence virt-install ended in choosing pseries-2.7 and
qemu complains as unsupported type.

may be pseries-2.7 is renamed to pseries-yakkety? which needs a change
in capabilities?

Contact Information = sathe...@in.ibm.com 
 
---uname output---
Linux ltc-test-ci1 4.8.0-17-generic #19-Ubuntu SMP Sun Sep 25 06:35:40 UTC 2016 
ppc64le ppc64le ppc64le GNU/Linux
 
Machine Type = power 8 ppc64le 
 
---Debugger---
A debugger is not configured
 
---Steps to Reproduce---
  /usr/bin/virt-install --connect=qemu:///system --hvm --accelerate --name 
'vm1' --machine pseries --ram=1024 --vcpu=2 --import --os-variant linux 
--serial pty --disk 
path=/var/lib/libvirt/images/ubuntu-16.10-ppc64le.qcow2,bus=scsi,size=10,format=qcow2
 --network=bridge=virbr0,model=spapr-vlan,mac=52:54:00:49:4a:4b --noautoconsole

Starting install...
ERROR    internal error: process exited while connecting to monitor: 
2016-09-26T10:58:22.312099Z qemu-system-ppc64: -enable-kvm: unsupported machine 
type
Use -machine help to list supported machines
Domain installation does not appear to have been successful.
If it was, you can restart your domain by running:
  virsh --connect qemu:///system start vm1
otherwise, please restart your installation.


#qemu-system-ppc64 -machine ?
Supported machines are:
bamboo               bamboo
g3beige              Heathrow based PowerMAC
mac99                Mac99 based PowerMAC
mpc8544ds            mpc8544ds
none                 empty machine
ppce500              generic paravirt e500 platform
prep                 PowerPC PREP platform
pseries-2.1          pSeries Logical Partition (PAPR compliant)
pseries-2.2          pSeries Logical Partition (PAPR compliant)
pseries-2.3          pSeries Logical Partition (PAPR compliant)
pseries-2.4          pSeries Logical Partition (PAPR compliant)
pseries-2.5          pSeries Logical Partition (PAPR compliant)
pseries-2.6          pSeries Logical Partition (PAPR compliant)
pseries-xenial       pSeries Logical Partition (PAPR compliant)
pseries              pSeries Logical Partition (PAPR compliant) (alias of 
pseries-yakkety)
pseries-yakkety      pSeries Logical Partition (PAPR compliant) (default)
ref405ep             ref405ep
taihu                taihu
virtex-ml507         Xilinx Virtex ML507 reference design


#virsh capabilities
....
....
 <guest>
    <os_type>hvm</os_type>
    <arch name='ppc64le'>
      <wordsize>64</wordsize>
      <emulator>/usr/bin/qemu-system-ppc64le</emulator>
      <machine maxCpus='255'>pseries-yakkety</machine>
      <machine canonical='pseries-yakkety' maxCpus='255'>pseries</machine>
      <machine maxCpus='1'>ref405ep</machine>
      <machine maxCpus='1'>virtex-ml507</machine>
      <machine maxCpus='32'>ppce500</machine>
      <machine maxCpus='15'>mpc8544ds</machine>
      <machine maxCpus='1'>bamboo</machine>
      <machine maxCpus='1'>g3beige</machine>
      <machine maxCpus='1'>prep</machine>
      <machine maxCpus='1'>mac99</machine>
      <machine maxCpus='255'>pseries-2.6</machine>
      <machine maxCpus='255'>pseries-2.4</machine>
      <machine maxCpus='255'>pseries-2.5</machine>
      <machine maxCpus='255'>pseries-2.2</machine>
      <machine maxCpus='1'>taihu</machine>
      <machine maxCpus='255'>pseries-2.3</machine>
      <machine maxCpus='255'>pseries-xenial</machine>
      <machine maxCpus='255'>pseries-2.1</machine>
      <domain type='qemu'/>
      <domain type='kvm'>
        <emulator>/usr/bin/kvm</emulator>
        <machine 
maxCpus='255'>pseries-2.7</machine>-----------------------------------------------NOK
        <machine canonical='pseries-2.7' maxCpus='255'>pseries</machine>
        <machine maxCpus='1'>ref405ep</machine>
        <machine maxCpus='1'>virtex-ml507</machine>
        <machine maxCpus='32'>ppce500</machine>
        <machine maxCpus='15'>mpc8544ds</machine>
        <machine maxCpus='1'>bamboo</machine>
        <machine maxCpus='1'>g3beige</machine>
        <machine maxCpus='1'>prep</machine>
        <machine maxCpus='1'>mac99</machine>
        <machine maxCpus='255'>pseries-2.6</machine>
        <machine maxCpus='255'>pseries-2.4</machine>
        <machine maxCpus='255'>pseries-2.5</machine>
        <machine maxCpus='255'>pseries-2.2</machine>
        <machine maxCpus='1'>taihu</machine>
        <machine maxCpus='255'>pseries-2.3</machine>
        <machine maxCpus='255'>pseries-2.1</machine>
      </domain>
    </arch>
    <features>
      <cpuselection/>
      <deviceboot/>
      <disksnapshot default='on' toggle='no'/>
    </features>
  </guest>


Userspace tool common name: ii  qemu-system-ppc                            
1:2.6.1+dfsg-0ubuntu3                   ppc64el      QEMU full system emulation 
binaries (ppc) , ii  libvirt0:ppc64el                           2.1.0-1ubuntu6  
                        ppc64el      library for interfacing with different 
virtualization systems 
 
The userspace tool has the following bit modes: both 

Userspace rpm: ii  qemu-system-ppc                            1:2.6.1
+dfsg-0ubuntu3                   ppc64el      QEMU full system emulation
binaries (ppc) , ii  libvirt0:ppc64el
2.1.0-1ubuntu6                          ppc64el      library for
interfacing with different virtualization systems

Userspace tool obtained from project website:  na 
 
*Additional Instructions for sathe...@in.ibm.com: 
-Post a private note with access information to the machine that the bug is 
occuring on.
-Attach ltrace and strace of userspace application.

== Comment: #1 - Satheesh Rajendran <sathe...@in.ibm.com> - 2016-09-26 09:17:32 
==
There was a local qemu-system-ppc64 instance and due to /usr/bin/kvm defaults 
to local qemu-system-ppc64 instance there was inconsistent in virsh 
capabilities output, even after removing the local qemu-system-ppc64 instance.

Had a discussion with Shiva, after removing libvirt cache, libvirt
restart the virsh capabilities output became consistent

== Comment: #2 - Shivaprasad G. Bhat <shiva...@in.ibm.com> - 2016-09-26 
09:19:41 ==
Just to add, the binary in wrapper better be an absolute path that way, there 
is never an inconsistency over PATH variable changes

== Comment: #3 - Satheesh Rajendran <sathe...@in.ibm.com> - 2016-09-26 09:26:21 
==
To avoid this behavior permanently, it is good to the absolute path for 
qemu-system-ppc64 in /usr/bin/kvm wrapper, 


 #!/bin/sh
set -f

getcpu() {
   CPU="unknown"
   [ -r /proc/cpuinfo ] || return
   local line
   while read line; do
      set -- $line
      [ "$1" = "cpu" ] && CPU="$3" && return 0;
   done < /proc/cpuinfo
   return
}

getcpu
case "$CPU" in
  e500*|e6500*|e5500*)
    qemu=qemu-system-ppcemb
    ;;
  *)
    case "" in
      ppc64*)
        
qemu=qemu-system-ppc64--------------------------------->qemu=/usr/bin/qemu-system-ppc64
        ;;
      *)
        
qemu=qemu-system-ppc------------------------------------->qemu=/usr/bin/qemu-system-ppc
        ;;
    esac
  ;;
esac
exec "$qemu" -enable-kvm "$@"

** Affects: qemu (Ubuntu)
     Importance: Undecided
     Assignee: Taco Screen team (taco-screen-team)
         Status: New


** Tags: architecture-ppc64le bugnameltc-146735 severity-high 
targetmilestone-inin1610

** Tags added: architecture-ppc64le bugnameltc-146735 severity-high
targetmilestone-inin1610

** Changed in: ubuntu
     Assignee: (unassigned) => Taco Screen team (taco-screen-team)

** Package changed: ubuntu => qemu (Ubuntu)

-- 
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
https://bugs.launchpad.net/bugs/1628101

Title:
  qemu-kvm: virt-install VM fails due to inconsistent virsh capabilities
  output due to multiple qemu instance

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/qemu/+bug/1628101/+subscriptions

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to