kimchi-project / kimchi

An HTML5 management interface for KVM guests
https://github.com/kimchi-project/kimchi/releases/latest
Other
3.08k stars 365 forks source link

what is the file that generate /etc/libvirt/qemu/vm-name.xml ? #1292

Closed Alterjerof closed 4 years ago

Alterjerof commented 4 years ago

For writing in azerty with my french keyboard, i do The xml file is located in "/etc/libvirt/qemu/vm-name.xml" I changed the Line From: graphics type='vnc' port='-1' autoport='yes' listen='127.0.0.1' To: graphics type='vnc' port='-1' autoport='yes' listen='127.0.0.1' keymap='fr'

and restarted libvirt-bin.

But is possible to automate that? So what is the file that generate /etc/libvirt/qemu/vm-name.xml ? for automate.

thx for help

HTPC-Schrauber commented 4 years ago

The files in /etc/libvirt are created by libvirt. You should not edit them directly. Use "virsh edit vm-name" to edit the VM definition. This way you do not need to restart libvirt-bin.

Alterjerof commented 4 years ago

ok I try that. thx for issue

Alterjerof commented 4 years ago

So if i understand, is impossible to automate the add keymap='fr' Or i don't understand how use virsh edit vm-name in ubuntu.

If your can confirm, thx

HTPC-Schrauber commented 4 years ago

virsh edit takes you directly into the editor. So it is impossible to script this.

But you can use 'virsh dumpxml vm-name > vm-name.xml' to get the xml definition into a file. Then change this xml using sed or something. Then use 'virsh define vm-name.xml' to recreate the VM with the changed definition.

Alterjerof commented 4 years ago

i try automate with Inotify.

thx for help