Custom Configuration files for AppVMs

429 views
Skip to first unread message

AndrewX192

unread,
Jun 29, 2013, 12:58:59 AM6/29/13
to qubes...@googlegroups.com
Is it possible to permanently set or override options in the autogenerated configuration files, and if so - what is the best way to implement these changes?

Ideally I want to be able to permanently add more disks to my virtual machines, without having to run qvm-start with a custom configuration file. I checked qvm-prefs <VM> -s config <NEW_FILE>, but it doesn't understand the property "config".

Olivier Médoc

unread,
Jun 29, 2013, 2:23:10 AM6/29/13
to qubes...@googlegroups.com
On 06/29/13 06:58, AndrewX192 wrote:
> Is it possible to permanently set or override options in the
> autogenerated configuration files, and if so - what is the best way to
> implement these changes?
>
If you change your vm config filename and you edit qubes manager xml
file to match the new filename, this file will be considered as custom
and won't be generated anymore during the vm startup. Check in
/var/lib/qubes/appvms/yourvm and /var/lib/qubes/qubes.xml.

You will probably have to restart the qubes manager once you changed the
file. I'm not sure about that.


> Ideally I want to be able to permanently add more disks to my virtual
> machines, without having to run qvm-start with a custom configuration
> file. I checked qvm-prefs <VM> -s config <NEW_FILE>, but it doesn't
> understand the property "config".
> --
> You received this message because you are subscribed to the Google
> Groups "qubes-users" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to qubes-users...@googlegroups.com.
> To post to this group, send email to qubes...@googlegroups.com.
> Visit this group at http://groups.google.com/group/qubes-users.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>

Andrew Sorensen

unread,
Jun 29, 2013, 2:36:24 PM6/29/13
to Olivier Médoc, qubes...@googlegroups.com
On 06/28/13 23:23, Olivier M�doc wrote:
> On 06/29/13 06:58, AndrewX192 wrote:
>> Is it possible to permanently set or override options in the
>> autogenerated configuration files, and if so - what is the best way
>> to implement these changes?
>>
> If you change your vm config filename and you edit qubes manager xml
> file to match the new filename, this file will be considered as custom
> and won't be generated anymore during the vm startup. Check in
> /var/lib/qubes/appvms/yourvm and /var/lib/qubes/qubes.xml.
>
> You will probably have to restart the qubes manager once you changed
> the file. I'm not sure about that.
>

For the record, this solution works perfectly.

Marek Marczykowski-Górecki

unread,
Jul 8, 2013, 10:29:18 PM7/8/13
to Olivier Médoc, qubes...@googlegroups.com
On 29.06.2013 08:23, Olivier Médoc wrote:
> On 06/29/13 06:58, AndrewX192 wrote:
>> Is it possible to permanently set or override options in the autogenerated
>> configuration files, and if so - what is the best way to implement these
>> changes?
>>
> If you change your vm config filename and you edit qubes manager xml file to
> match the new filename, this file will be considered as custom and won't be
> generated anymore during the vm startup. Check in /var/lib/qubes/appvms/yourvm
> and /var/lib/qubes/qubes.xml.
>
> You will probably have to restart the qubes manager once you changed the file.
> I'm not sure about that.

Qubes manager should automatically detect qubes.xml modification (inotify
based watch).

--
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab

signature.asc

3mp...@gmail.com

unread,
Aug 31, 2018, 11:51:15 AM8/31/18
to qubes-users
I have the same problem in Qubes 4.0 but I can't find the VM configuration file... I tried modifying the qubes.xml file, tried virsh edit the VM with no luck, the config file of the VM I can't find is always regenerated when the VM starts.

There is a workaround when the VM is started with xl block-attach which is working and probably can be automated with qubes-rpc but I'm looking for a more elegant way like Olivier's solution for Qubes 4.0

Any directions ?

airele...@tutanota.com

unread,
Aug 31, 2018, 1:22:08 PM8/31/18
to Qubes Users

In Qubes 4.0,  I think the default config for all VMs is:
   /usr/share/qubes/templates/libvirt/xen.xml
and you can override it for <vm> by placing a config file in
  /etc/qubes/templates/libvirt/xen/by-name/<vm>.xml
Simply copying the former to the latter is probably a good place to start.

31. Aug 2018 15:51 by 3mp...@gmail.com:

--
You received this message because you are subscribed to the Google Groups "qubes-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to qubes-users...@googlegroups.com.
To post to this group, send email to qubes...@googlegroups.com.

3mp...@gmail.com

unread,
Sep 5, 2018, 10:18:00 AM9/5/18
to qubes-users
Le vendredi 31 août 2018 19:22:08 UTC+2, airele...@tutanota.com a écrit :
> In Qubes 4.0, I think the default config for all VMs is:
> /usr/share/qubes/templates/libvirt/xen.xml
> and you can override it for <vm> by placing a config file in
> /etc/qubes/templates/libvirt/xen/by-name/<vm>.xml
> Simply copying the former to the latter is probably a good place to start.

Thank you for your answer ! Searching this XML template location redirected me to this thread which contains a link to qubes dev documentation and a good example of what I'm trying to accomplish : https://groups.google.com/forum/#!msg/qubes-users/jZnKHg1a4Gs/uKWBK701AgAJ

It's working like a charm now :)
Reply all
Reply to author
Forward
0 new messages