3 ms·
It seems to be that a lot of what systemd is doing (over and above being 'just' an init system) seems to be focused on standalone systems. And that's fine and
by throw0101d 1y ago
It seems to be that a lot of what systemd is doing (over and above being 'just' an init system) seems to be focused on standalone systems.
And that's fine and all for some folks, but for those of us sysadmin-ing servers/VMs, it's all sorts of annoying that these sub-systems exist for dynamic environments (laptops using networkd/resolvd/etc to handle moving around), but I just want my system to be static and not have (e.g.) resolv.conf futzed around with (I've taken to doing a chattr +i on the file quite often).
- nixosbestos 1y agoHm. So then don't use (systemd-)resolved? Alternatively, I've accepted that it's built to work with a decades-old ecosystem and that resolv.conf is effectively a generated, read-only-except-resolved file. And in turn, resolved's configuration is perfectly static and equally immutable. /shrug My* only problem is that it's pretty good at what it does, and can be... more helpful than you might like at providing consistent global DNS resolution. For example, it's use over dbus makes processes in `netns`s susceptible to leaking DNS requests. Though arguably I should've been going more full-containery than just a netns maybe, given my expectations.
- throw0101a 1y ago> Hm. So then don't use (systemd-)resolved? The number of ways and things that twiddle with /etc/resolv.conf nowadays is quite unreasonable. Changing the IP address was also fairly simple in editing a file, but now there's networkd sometimes, and NetManager other times, and netplan too, and perhaps make sure your YAML file is indented with the right number of spaces in the right place…
- yjftsjthsd-h 1y ago> The number of ways and things that twiddle with /etc/resolv.conf nowadays is quite unreasonable. In many years of daily-driving unix-likes and being an amateur and professional sysadmin, I think resolv.conf is the only time I've ever actually used `chattr +i`.
- wpollock 1y ago> (I've taken to doing a chattr +i on the file quite often) That requires ext4 AFAIK, whereas many systems use XFS, BTRFS, or ZFS. I've done this as well on several files I don't want mucked with, when I can't simply disable the systemd daemons. For me, ext4 works best.
- throw0101d 1y ago> That requires ext4 AFAIK, whereas many systems use XFS, BTRFS, or ZFS. All three of these support immutable files: * https://man.archlinux.org/man/xfs.5.en#FILE_ATTRIBUTES https://man.archlinux.org/man/xfs.5.en#FILE_ATTRIBUTES * https://man.archlinux.org/man/btrfs.5.en#Attributes https://man.archlinux.org/man/btrfs.5.en#Attributes * 2016 OpenZFS bug where it was broken and fixed: https://github.com/openzfs/zfs/pull/5486 https://github.com/openzfs/zfs/pull/5486
- wpollock 1y agoTIL. Thanks!