sudo qemu-img resize /var/lib/libvirt/images/artix.qcow2 +10G
sudo apt install spice-vdagent
Graficamente: https://ostechnix.com/setup-a-shared-folder-between-kvm-host-and-guest/
https://libvirt.org/kbase/virtiofs.html
sudo apt-get install virt-manager libguestfs-tools
cd /etc/libvirt/qemu/
sudo vim debian12.xml
Agregá antes de </domain>
y dentro de <devices>
<filesystem type='mount' accessmode='passthrough'>
<source dir='/tu/carpeta/host'/>
<target dir='share'/>
</filesystem>
En el guest:
mount -t 9p -o trans=virtio share /mnt/shared
Si no te funcioná tenés que habilitar módulos.
Resolved for me (with an ubuntu 18.04 host and 14.04 guest) by adding theses modules:
into guest file /etc/initramfs-tools/modules
.
Don’t forget to upadate initramfs for your kernel(s) after add:
update-initramfs -uk <kernel|all>
modprobe virtio_pci
https://www.guyrutenberg.com/2018/10/25/sharing-a-folder-a-windows-guest-under-virt-manager/
https://libvirt.org/kbase/virtiofs.html
<domain>
...
<memoryBacking>
<source type='memfd'/>
<access mode='shared'/>
</memoryBacking>
...
<devices>
...
<filesystem type='mount' accessmode='passthrough'>
<driver type='virtiofs' queue='1024'/>
<source dir='/path'/>
<target dir='mount_tag'/>
</filesystem>
...
</devices>
</domain>
# mount -t virtiofs mount_tag /mnt/mount/path