|
|
Log in / Subscribe / Register

Systemd and containers

Systemd and containers

Posted Jun 11, 2015 8:26 UTC (Thu) by gfa (guest, #53331)
Parent article: Systemd and containers

this time i think systemd does too much. *i don't want to flame* but dnsmasq is already here and working fine, why does systemd implement it's own dhcp server?

i think this time systemd is suffering from NIH syndrome


to post comments

Systemd and containers

Posted Jun 11, 2015 9:59 UTC (Thu) by cortana (subscriber, #24596) [Link] (11 responses)

Among other things, dnsmasq has no idea about how to map different upstream nameserver configurations to currently active network connections. A really nice feature of systemd-resolved is that names are resolved separately on each of the currently active connections, and the results are merged. So connecting to a VPN no longer needs to hijack your entire internet connection--it can now just be used to give you access to a particular network, without interrupting traffic that shouldn't flow through it.

Systemd and containers

Posted Jun 11, 2015 10:14 UTC (Thu) by gfa (guest, #53331) [Link] (9 responses)

of course it does

dnsmasq --no-hosts --no-resolv --strict-order --bind-interfaces --interface=tap50303112-34 --except-interface=lo --pid-file=/$RANDOM.pid --server=8.8.8.8 --dhcp-hostsfile=/tmp/1c83334d-7896-4b1d-9381-26108295f89d/host --addn-hosts=/tmp/addn_hosts --dhcp-optsfile=/tmp/opts

this way dnsmasq will bind exclusively to an interface (tap50303112-34 ) and will use 8.8.8.8 as dns server for that interface. more complex things can be done

anyway is good to have a choice

Systemd and containers

Posted Jun 11, 2015 17:33 UTC (Thu) by kleptog (subscriber, #1183) [Link] (6 responses)

I think you misunderstood. The active connections in this case are for example a VPN to your work and a VPN to your Uni. So when asked to resolve a domain resolved asks each of the upstream nameservers (at your work and at Uni) and merges the results. I don't think dnsmasq can do that and your example certainly doesn't (it sends everything to 8.8.8.8).

Systemd and containers

Posted Jun 11, 2015 18:00 UTC (Thu) by cuviper (guest, #56273) [Link] (5 responses)

You can do split networks with dnsmasq though, as NetworkManager will do with the dnsmasq plugin. For example I get a something like "dnsmasq --server=/redhat.com/$VPN_DNS --server=$ISP_DNS", so all redhat.com queries go over the VPN, and the rest go to my ISP. That seems better than "ask everyone and merge" that you describe.

Systemd and containers

Posted Jun 11, 2015 22:42 UTC (Thu) by rahvin (guest, #16953) [Link] (4 responses)

The method you describe would require that you configure every time you change connection what connections go over what links. This can become exceedingly micromanaging and drive someone nuts. The systemd method ensures that you always get the results regardless of what links are up or active. As long as names don't overlap that is, if you have overlaps in names the systemd method would be a resolv nightmare.

Systemd and containers

Posted Jun 11, 2015 22:45 UTC (Thu) by cuviper (guest, #56273) [Link] (3 responses)

Yeah, it's not something I'd want to configure manually, but NetworkManager does it for me.

Systemd and containers

Posted Jun 12, 2015 8:16 UTC (Fri) by anselm (subscriber, #2796) [Link] (2 responses)

NetworkManager is a useful but quite complicated piece of software, and adding potentially several instances of dnsmasq into the mix isn't going to make things more straightforward. It would be useful to be able to deal with as many of the standard use cases as is reasonable with systemd-networkd (and if it plays well with containers, so much the better) and reserve the extra complexity of NetworkManager for those situations where it is actually needed (like dealing with lots of different wireless networks).

Systemd and containers

Posted Jun 18, 2015 8:07 UTC (Thu) by dakas (guest, #88146) [Link] (1 responses)

NetworkManager is a useful but quite complicated piece of software,
So does systemd differ by being not useful or by being not complicated? I don't quite see the point you try to make against this being NIH syndrome.

Systemd and containers

Posted Jun 18, 2015 9:08 UTC (Thu) by anselm (subscriber, #2796) [Link]

There are lots of systems that profit from being based on systemd but have no conceivable need for NetworkManager (mostly because NetworkManager's strength is dealing with a changing network environment, while these systems may be sitting firmly on a desk or in a rack somewhere). It makes sense to investigate whether such systems could use something simpler than NetworkManager+dnsmasq.

Systemd and containers

Posted Jun 20, 2015 14:18 UTC (Sat) by dakas (guest, #88146) [Link] (1 responses)

anyway is good to have a choice
The systemd universe is about not having choices. It's all or nothing.

Systemd and containers

Posted Jun 20, 2015 14:19 UTC (Sat) by anselm (subscriber, #2796) [Link]

Go back under your bridge, troll. This has been debunked so many times it is no longer funny.

Systemd and containers

Posted Jun 15, 2015 9:58 UTC (Mon) by alan (guest, #4018) [Link]

Instead of implementing a dhcp server, was any effort made to reach out to dnsmasq developers to add the additional support needed? If not then this is definitely NIH syndrome, reimplementing a service that gives you 95% of what you need without investigating what is necessary to get support for that additional 5%.

Systemd and containers

Posted Jun 11, 2015 11:17 UTC (Thu) by ibukanov (subscriber, #3942) [Link] (2 responses)

dnsmasq does not support LLMNR which is useful for truly stateless configs using local link addressing.

Systemd and containers

Posted Jun 11, 2015 21:44 UTC (Thu) by luto (subscriber, #39314) [Link] (1 responses)

But dnsmasq would allow *.local (or whatever) to be forwarded to an LLMNR resolver.

There's one problem: for link-local applications, client software (especially on IPv6) needs an ifindex or other scope indicator. We don't have that using just resolv.conf-based mechanisms. I think that should be added independently of systemd-resolved, though.

Systemd and containers

Posted Jun 13, 2015 13:34 UTC (Sat) by grawity (subscriber, #80596) [Link]

I remember spending some time with that. Both systemd's libnss_resolve, and (I think) Avahi's libnss_mdns, do return the scope index. Unfortunately, glibc throws it away.

(libnss_dns of course doesn't return the scope because it doesn't know the scope.)

Systemd and containers

Posted Jun 11, 2015 13:21 UTC (Thu) by charlieb (guest, #23340) [Link]

This time? Where have you been?


Copyright © 2026, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds