On Tue, 21.10.14 14:43, Dan Williams (dcbw(a)redhat.com) wrote:
> I am really not keen though to do this via dbus, nor via some
dir in
> /run (like networkd does) due to the awkward ownership and lifecycle
> semantics.
That was my major issue with resolvconf too, the lifecycle issues. But
that could be solved via D-Bus connections, where if the client
disconnects, resolved removes the information that client pushed
down.
Well, we thought about that too. But what we didn't like about this
was that it actually binds the life-cycle of things to the wrong
object: it should be attached to the interface, not the daemon
installing it. I think it would be a really good idea to support a
scheme where some program figures out something, attaches it to the
iface and dies, but the data isn't lost.
For ownership, I don't think that's solved by XATTRs. Unless
you
namespace them or otherwise tie them to the DNS source, all resolved can
do is read the "dns1" attribute on eth0. But that attribute could be
written to by anything with privilege, be that NetworkManager or
networkd or whatever. If this isn't what you mean by ownership, could
you elaborate?
well, by ownership I just mean that the lifecycle is bound to some
other suitable object. xattrs allow us to do this naturally to network
interfaces.
Lennart
--
Lennart Poettering, Red Hat