virsh capabilities does not include qemu

shafnamol N shafnamol29 at gmail.com
Tue Mar 23 05:00:36 UTC 2021


Hi,
I didnt pass prefix while building.
So I tried

*meson build -Dsystem=true*

It worked for me.Now virsh shows kvm and qemu in its capabilities and
could create a new VM using virsh create.
Thanks for your valuable time.

Thanks,

Shafnamol.N



On Mon, Mar 22, 2021 at 6:40 PM Daniel P. Berrangé <berrange at redhat.com>
wrote:

> On Mon, Mar 22, 2021 at 01:57:24PM +0100, Michal Privoznik wrote:
> > On 3/22/21 5:17 AM, shafnamol N wrote:
> > > Hi,
> > > I am new  to Libvirt and Qemu.I have installed Libvirt 7.1.0 and
> > > qemu-kvm 4.2.0.
> > > I configured and built libvirt based on instructions from
> > > https://libvirt.org/compiling.html <https://libvirt.org/compiling.html
> >.
> > > But when i tried to create a VM using virsh it shows the following
> error:
> > > # virsh create /home/abc.xml
> > > error: Failed to create domain from /home/abc.xml
> > > error: invalid argument: could not find capabilities for arch=x86_64
> > > domaintype=kvm
> > >
> > > When i check the hypervisor capabilities ,it doest show qemu in guest
> > > domain type.
> > > # virsh capabilities
> > > ....................................
> > > .....................................
> > >   </host>
> > >
> > >    <guest>
> > >      <os_type>exe</os_type>
> > >      <arch name='x86_64'>
> > >        <wordsize>64</wordsize>
> > >        <emulator>/usr/local/libexec/libvirt_lxc</emulator>
> > >        <domain type='lxc'/>
> > >      </arch>
> > >    </guest>
> > >
> > >    <guest>
> > >      <os_type>exe</os_type>
> > >      <arch name='i686'>
> > >        <wordsize>32</wordsize>
> > >        <emulator>/usr/local/libexec/libvirt_lxc</emulator>
> >
> > This smells suspicious. Perhaps you did not pass proper prefix (meson
> > -Dsystem=true)?
> >
> > Anyway, libvirt tries to find qemu-system-$arch in $PATH and falls back
> to
> > /usr/libexec/qemu-kvm if no binary was found. So I suspect that maybe the
> > directory you installed QEMU into is not in $PATH?
>
> This capabiliities output is showing an lxc:///system driver connection
> too, not QEMU. So I suspect libvirt was perhaps built without QEMU
> support ?
>
>
> Regards,
> Daniel
> --
> |: https://berrange.com      -o-
> https://www.flickr.com/photos/dberrange :|
> |: https://libvirt.org         -o-
> https://fstop138.berrange.com :|
> |: https://entangle-photo.org    -o-
> https://www.instagram.com/dberrange :|
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listman.redhat.com/archives/libvirt-users/attachments/20210323/354026ce/attachment.htm>


More information about the libvirt-users mailing list