How to customize libvirt.xml for an instance ?
Hello
I'm following the procedure at https://ask.openstack.org/en/question/5415/customize-libvirtxml-for-an-instance/ (https://ask.openstack.org/en/question...) but it doesn't seem to work. I'm on Havana.
This is what I see:
(1) No instance on the compute node
root@node-12:~# virsh
Welcome to virsh, the virtualization interactive terminal.
Type: 'help' for help with commands
'quit' to quit
virsh # list
Id Name State
----------------------------------------------------
(2) Create and boot an instance via Horizon, find the libvirt file and check it
virsh # list
Id Name State
----------------------------------------------------
20 instance-0000000d running
virsh #
root@node-12:~# ls -la /var/lib/nova/instances/
total 8
drwxr-xr-x 6 nova nova 136 Apr 12 11:50 .
drwxr-xr-x 10 nova nova 123 Mar 31 11:18 ..
drwxr-xr-x 2 nova nova 53 Apr 12 11:51 760a2891-da1a-40e1-b6de-ef6b9f029b09
more /var/lib/nova/instances/760a2891-da1a-40e1-b6de-ef6b9f029b09/libvirt.xml
<system>
<entry name="manufacturer">OpenStack Foundation</entry>
<entry name="product">OpenStack Nova</entry>
<entry name="version">2013.2.2</entry>
<entry name="serial">d289170a-baff-42d0-b858-2268192cc682</entry>
<entry name="uuid">760a2891-da1a-40e1-b6de-ef6b9f029b09</entry>
</system>
(3) Modify the libvirt file of the instance ( changed the value of entry name "product" ) and save the file
more /var/lib/nova/instances/760a2891-da1a-40e1-b6de-ef6b9f029b09/libvirt.xml
<system>
<entry name="manufacturer">OpenStack Foundation</entry>
<entry name="product">Router in OpenStack Nova</entry>
<entry name="version">2013.2.2</entry>
<entry name="serial">d289170a-baff-42d0-b858-2268192cc682</entry>
<entry name="uuid">760a2891-da1a-40e1-b6de-ef6b9f029b09</entry>
</system>
(4) Follow the procedure explained at https://ask.openstack.org/en/question/5415/customize-libvirtxml-for-an-instance/ (https://ask.openstack.org/en/question...)
virsh # destroy instance-0000000d
Domain instance-0000000d destroyed
virsh # undefine instance-0000000d
Domain instance-0000000d has been undefined
virsh # define /var/lib/nova/instances/760a2891-da1a-40e1-b6de-ef6b9f029b09/libvirt.xml
Domain instance-0000000d defined from /var/lib/nova/instances/760a2891-da1a-40e1-b6de-ef6b9f029b09/libvirt.xml
virsh # start instance-0000000d
Domain instance-0000000d started
virsh # exit
(5) Check that the libvirt file is still modified, and then soft reboot (via Horizon) the instance
more /var/lib/nova/instances/760a2891-da1a-40e1-b6de-ef6b9f029b09/libvirt.xml
<system>
<entry name="manufacturer">OpenStack Foundation</entry>
<entry name="product">Router in OpenStack Nova</entry>
<entry name="version">2013.2.2</entry>
<entry name="serial">d289170a-baff-42d0-b858-2268192cc682</entry>
<entry name="uuid">760a2891-da1a-40e1-b6de-ef6b9f029b09</entry>
</system>
( soft reboot via Horizon )
(6) After soft reboot check the libvirt file; entry name "product" is back to the original value
more /var/lib/nova/instances/760a2891-da1a-40e1-b6de-ef6b9f029b09/libvirt.xml
<system>
<entry name="manufacturer">OpenStack Foundation</entry>
<entry name="product">OpenStack Nova</entry>
<entry name="version">2013.2.2</entry>
<entry name="serial">d289170a-baff-42d0-b858-2268192cc682</entry>
<entry name="uuid">760a2891-da1a-40e1-b6de-ef6b9f029b09</entry>
</system>
Of course I don't really care about changing the entry name "product", but this is just to show that even what I believe was a cosmetic change is not possible (at least in my scenario)
Any suggestion ? Anybody able to reproduce the same behavior ?
E.
Hi, have you resolved the issue? I've the same problem.