Libvirt vs QEMU benefits

2022-04-06 Thread M, Shivakumar
Hello,

For one of our case validation, we were using direct QEMU commands before for 
VM creation as it was easier to configure the VMs. Inside VM we do run the 
real-time latency test.
Recently we switched to libvirt for the VM creation and deletion. Surprisingly, 
we do see a significant increase in the real-time latency performance for the 
VMs launched through the libvirt.

W.r.t configuration wise both VMs are the same, we just converted the existing 
QEMU commands into libvirt XMLs.

I am wondering what and all the features which libvirt has, improving this 
performance.


Thanks,
Shivakumar M


QEMU args generation order with libvirt

2022-02-27 Thread M, Shivakumar
Hello,

We are trying to bring up the Android VM with Libvirt, as part of this exercise 
it is advised to keep Replay Protected Memory Block (RPMB) device as the first 
virtio device in the QEMU arg list, as the secure storage daemon in Andriod 
side communicates with dev/vport0p1 for RPMB usage.

Is there any way we can make a qemu commands generation in particular order 
with Libvirt XML ?

Thanks,
Shivakumar M


RE: udmabuf error with libvirt + QEMU

2022-02-01 Thread M, Shivakumar
Hi Daniel,

You're right , /dev/udmabuf is required for GTK display for GL support. I agree 
passing the device using qemu:arg breaks the security confinement of Libvirt. 
For our use-case we need to have the GL support, is there any way to specify 
the GTK display option in the Libvirt XML ? or any other alternatives?

Thanks,
Shiv

-Original Message-
From: Daniel P. Berrangé  
Sent: Tuesday, February 1, 2022 8:11 PM
To: M, Shivakumar 
Cc: libvirt-users@redhat.com
Subject: Re: udmabuf error with libvirt + QEMU

On Tue, Feb 01, 2022 at 02:27:55PM +, M, Shivakumar wrote:
> Hi,
> 
> We are seeing an issue with udambuf, where it says "open /dev/udmabuf: No 
> such file or directory " even if the device exits. This issue particularly we 
> are seeing with libvirt. When we run the QEMU args on the command line, 
> everything works as expected.
> It seems to be some permission issue when we use the Libvirt, please help us 
> on resolving this.

When libvirt launches QEMU it puts in place a number of strict security 
protections. Libvirt will grant access on a per-file basis to resources on the 
host that QEMU should be allowed to access based on the device configuration in 
the XML.

In your case though you're using command line passthrough:

>   
> 
> 
> 
> 
> 
>   

This is totally opaque to libvirt and so libvirt won't be granting access to 
any resources needed by these args. I'm assuming /dev/udmabuf is needed by the 
GTK display for GL support, or something along those lines.

For further information about your options please consult this page:

  https://libvirt.org/kbase/qemu-passthrough-security.html

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 :|




Backend memory object creation - query

2022-01-27 Thread M, Shivakumar
Hello,


For our use-case with Libvirt we want to create the Memory backend object ,

Expected QEMU args would be
-object memory-backend-memfd,id=mem1,size=4096M

Request you to please help us to specify this arg in the libvirt XML.

Thanks,
Shiv