
The XML component for the shared memory backing is:

So, select the Overview option, then the XML tab, and in the section and just under the element, add the XML component for the shared Memory Backing. Memory Backing enables how virtual memory pages are backed by host pages.

In the new window that appears, click on View, followed by Details.įirst, add the XML component for shared Memory Backing. Then, select the guest to which you want to mount the host’s shared directory and press the Open button. So, open the Virtual Machine Manager and enable XML editing.

However, as XML editing is disabled by default in Virtual Machine Manager, you have to enable it first. You need to add two XML components to share a directory in Virtual Machine Manager. Share Directory Using Virtual Machine Manager Choose the one that best suits your needs. The shared directory can be set graphically or via the command line. You can choose any other location on the host or even a different Linux distribution for the guest VM. To illustrate this, on the host system, I will share my home directory ( /home/madhu) with the Debian guest virtual machine. As a result, a new file system called virtiofs was developed to take advantage of this proximity in order to achieve semantics and performance comparable to local file systems. Since virtualization allows several guests to operate on the same physical host, their proximity to the physical host allows them to quickly access shared memory. In this post, I’ll show how to share files between KVM host and Linux guest using virtiofs.Įxisting remote file systems, such as NFS and 9P, that are used to share files with Linux guests will have some communication overhead between the host and the guest since they were designed for network architecture. For Linux guests, you can use the NFS or the Virtiofs file system to share files, while for Windows guests, you can use Samba file shares. In KVM, file sharing between the host and its Linux and Windows guests is completely different.
