[libvirt] [RFC] new preferences requirement

Justin Clift jclift at redhat.com
Wed Dec 1 10:19:30 UTC 2010


On 01/12/2010, at 8:35 PM, Osier Yang wrote:
>   Should we add these new preferences(if they are really neccessary)
> in qemu.conf? or create new config file, e.g. The approch Justin
> raised up an approch before:
> http://www.redhat.com/archives/libvir-list/2010-November/msg00651.html
> 
>   Though for Justin's approch, IMHO we'd better also to provide a
> default config file, e.g. "/etc/libvirt/client.conf".
> 
>   Any feedback is welcomed, thanks

When thinking about this more, three levels of preference can be found in
other applications, and _might_ be the right approach for us to take as well.

  1) System wide

    Client preferences stored in a location that's applicable to all users.

      ie:  /etc/libvirt.conf or similar

    We can't put it in the /etc/libvirt/ directory with the present permission
    structure, because /etc/libvirt/ is not world readable.  Would need to be
    in a world readable location (/etc/ ?) or we could relax the perms of
    /etc/libvirt/ (prob not likely).

 2) Per user preference

      ie:  ~/.libvirt.conf or ~/.libvirt/client.conf or similar

    For a user to permanently override the above system wide defaults,
    in case their setup is different from everyone else on the system.

  3) On the command line

      ie: $ virsh --some-new-option=foo

      For adhoc preference changes not to be stored in a pref file.

The other category of user preferences that I think are important, is
for the defaults of virsh.  I strongly suspect people who use virsh a lot
would like to change some of it's command defaults.  Specifically having
"--all" be the default for the *-list commands, having "--details" automatically
be used for the storage list commands, and that kind of thing.

That's my thinking so far anyway. :)

Regards and best wishes,

Justin Clift
        




More information about the libvir-list mailing list