[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [PATCH] libxlu: Handle += in config files



On Tue, Aug 13, 2019 at 04:47:23PM +0100, Andrew Cooper wrote:
> Error between user and terminal. :)
> 
> I'd sync'd xl and libxl.so, but not libxlu.so

I actually made the same mistake first time I tried.

> Ok, so that is working now.  I think 'cmdline+=" dom0=pvh
> dom0-iommu=none"' is slightly less tortured syntax, but I guess there is
> no way that this isn't going to be horrible.
> 
> As for the general mechanism, how usable is += for anything other than
> cmdline?  Most strings in config files can't usefully be extended in
> this matter - if they need changing, they need changing wholesale.

That's true, but one could imaging some maybe bad example like adding a
suffix to the name of the guest: "name+='-ovmf';".
Going through `man xl.cfg', maybe a good example other than cmdline
could be "cpus+=',^1'" but maybe a space is fine here, or one could use
a list instead.
Other potential uses could be for "PATH", but in this case it would be
better reset the setting rather that attempting to add a suffix to an
existing one.

I wonder if instead of doing += on all strings, we should instead have
`xl' whitelist the few options where += would make sense. (and at that
point, it would be easy to add a ' ' where is make sense, like
"cmdline"s. But then, how to tell users that it can't do "name+='-new'"?
because xlu would just print a warning, and xl would keep going with
name="".  Try "xl create memory+=42" ;-).

-- 
Anthony PERARD

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.