[augeas-devel] Variables must be set in order?

David Lutterkort lutter at redhat.com
Thu May 14 16:14:07 UTC 2009


On Mon, 2009-05-11 at 14:45 +1000, Matt Palmer wrote:
> I think this kinda says it all, really:
> 
> ---8<---
> 
> grog:~# augtool
> augtool> set /files/etc/network/interfaces/iface[4] br0
> augtool> set /files/etc/network/interfaces/iface[4]/method manual
> augtool> set /files/etc/network/interfaces/iface[4]/family inet
> augtool> set /files/etc/network/interfaces/iface[4]/address 192.168.12.14
> augtool> set /files/etc/network/interfaces/iface[4]/netmask 255.255.255.0
> augtool> save
> Saving failed

Just to expand on what Raphael said: the Augeas tree is ordered (because
files are inherently ordered), i.e. the order in which siblings appear
matters, and the interfaces lens specifies that 'family' has to come
before 'method' - if it were legal in the config file, it would be
possible to allow 'method' before 'family' in the lens, too.

David





More information about the augeas-devel mailing list