14 ms·
Systemd programming, 30 months later
- deleted 10y ago[deleted]
- bkor 10y agoAnother nice video discussing the current limitations of using systemd user sessions for starting up desktop environments (=user session) is: https://www.youtube.com/watch?v=hq18daxTkLA https://www.youtube.com/watch?v=hq18daxTkLA On July Martin Pitt already started to discuss some of the difficulties on systemd-devel mailing list: https://lists.freedesktop.org/archives/systemd-devel/2016-July/037017.html https://lists.freedesktop.org/archives/systemd-devel/2016-Ju... During the systemd conference they've been working to create a good solution for this.
- digi_owl 10y agoSo effectively a doubling down on the cockup that is systemd login sessions... https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=825394 https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=825394 Gotta go faster faster faster...
- bkor 10y agoThey're making it work in practice. That's quite different from "doubling down on a cockup". There's various bits which do not work in the current design, so they have to change things until it does. This effort is being driven not by a systemd developer, but someone working for Canonical. These user sessions have existed for various years. Now they're ensuring it'll work for graphical sessions. How is this fast?
- digi_owl 10y agoHe may be working for Canonical, but he is basically Systemd's insider at the company (and Debian, btw). As for the last line: https://www.youtube.com/watch?v=VTHsOSGJHN0 https://www.youtube.com/watch?v=VTHsOSGJHN0
- tremon 10y agoNot really. "Making it work in practice" is a perfect recipe for creating a cockup. It is a perfect illustration of how software engineering isn't. Do you really want a real, professional engineer to use the strategy "I don't need verified designs, I'll just make it work in practice" when building a bridge or railway?
- reacweb 10y agoVery interesting for developpers, but I am still searching for a documentation about systemd and nfs for non expert users.
- proaralyst 10y agoThe Arch Linux wiki has good documentation on Systemd: https://wiki.archlinux.org/index.php/Systemd https://wiki.archlinux.org/index.php/Systemd
- macawfish 10y agoI just switched to Arch recently, and only then became aware of systemd. I have to say (as an init scripting noob) that I appreciate how systemd scripts seem more naturally organised than init.d scripts. Having dependencies specified explicitly helps me to understand how the system works much more easily than cryptic directories full of numbered init scripts ever have.
- a3n 10y agoSame as you, recent Arch switcher. I've never been a professional sysadmin, just my home network. I've been enjoying systemd from a noob/amateur perspective.
- xaduha 10y agoI'd recommend NixOS, for non expert users. If you are interested in 'what' and not in 'how' or 'why', then declarative nature of Nix configuration will do nicely. It can be as simple as services.nfs.server.enable = true; services.nfs.server.exports = '' /export 192.168.0.0/16(rw,no_root_squash,insecure,no_subtree_check) '';
- psibi 10y agoAs someone who uses NixOS now and then, I disagree with you. Right now, NixOS itself is for expert users. The installation itself will be problematic for non expert users.
- xarope 10y agoI've not looked closely at systemd yet, but my initial attempts with using sysctl on a test ubuntu 16.04 server, seems to reflect my experience with usage of svcadm in solaris/illumos, where the latter requires XML manifest instead of a "simple" script. Is this an apt comparison for systemd, or is it way better/worse (I'm not an expert, so I'll leave the qualitative opinions to others!) than that?
- izacus 10y agoHmm, I found the systemd scripts (plain text files) very readable and decently simple.
- ChoHag 10y agoAs a script, "start the service" is extremely readable and simple on the surface. Exactly what I'd need to do to be able to put a #! on the line before is slightly more complex and you won't be able to reason about it yourself except by guesswork but that's alright because I've got it right. You can trust me.
- viraptor 10y agounits are simple ini-like files. Unless you want some very specific behaviour (and if you're the app's author, you know if you do), your service file will be normally as simple as: [Unit] Description=Some description [Service] Type=simple ExecStart=/the/service/binary [Install] WantedBy=multi-user.target The rest is stuff on top (user/group, namespaces, cgroups, stdout redirection, socket activation, ordering, etc.) Actually running the services instead of forking them also allows you to get rid of lots of silly pidfile handling options.
- chme 10y ago> simple This might look simple, because "Hello world" is simple in most languages. But if you really work with them, you will encounter many hidden complexities.
- __david__ 10y agoOh wow, I didn't know about `systemctl mask`. I've been fighting with a computer that takes forever to boot because of nfs, even though I do not want nfs enabled. I was trying to use `systemctl disable` to no avail, but `mask` looks like it'll actually do the trick.
- gosub 10y agoCould you elaborate on why `systemctl disable` was not working? I do not uderstand the difference between mask and disable.
- vetinari 10y ago'disable' can still start the service, if another service claims it as a dependency. It will not start the service, if it is the last one in the dependency chain. 'mask' will not start the service, not even as a dependency to another service; instead it will rather let the dependent service fail to start.
- brazzledazzle 10y agoThat would surprise me at some point. Kind of counter intuitive. Good to know, thanks for the info.
- lallysingh 10y agoDifficulty of naming in software. If they'd named it "block" instead of "mask", perhaps it'd be clearer?
- tremon 10y agoIn everyday usage, "disabled" is stronger than "masked". It is indeed surprising that masking is a stronger operation than disabling. It would be clearer if the systemd operation names were reversed.
- 10y ago
- new299 10y agoI've basically decided systemd isn't for me and have uninstalled it from my systems. The last straw for me was a recent security issue: https://www.agwa.name/blog/post/how_to_crash_systemd_in_one_tweet https://www.agwa.name/blog/post/how_to_crash_systemd_in_one_... Which made me re-evaluate systemd. Fundamentally creating a monolithic tool to take over from many small single purpose tools seems counter to the UNIX philosophy, and makes it harder to hack on my (mostly desktop/laptop) systems.
- ergo14 10y agoSo, what do you use instead?
- antocv 10y agoI use OpenRC on my servers, systemd on my desktop/productive-mode laptop. On some servers I use s6 toolset. Those are nice. OpenRC is nice. It gets the work done, its so small, its easy to do things with it, and it has less problems than systemd - which I experience on the desktop. Example, started using networkd for managing networks, because hey why not, and NetworkManager is shit, I had gotten tired of typing wpa-supplicant and dhcpcd commands manually. But then, systemd apparantly takes control over the networking subsystem not only the network interfaces - it changes sysctl flags and doesnt delete after itself when asked to stop - it leaves any addresses and other configuration changes it had done. What!? edit: As all things, systemd-networkd has its place, its just not on a developers laptop, maybe it would be great to have in some kind of cloud environment where you have to configure hordes of machines and virtual machines in them, with networking and networking subsystem configured correctly. Then its nice to have a "do-it-all" tool, but then you should also probably swallow the rest of RedHats output, such as Ansible and look at Project Atomic.
- ausjke 10y agoAlpine Linux uses OpenRC too, the linux preference for Docker these days.
- new299 10y ago
- mhd 10y agoI increasingly get the feeling that systemd is the maven of Linux administration.
- ddalex 10y agoOn reddit, I would've gilded you. I could not quite put the finger on what irked me about it, but this is a perfect description of the feeling I get when thinking about systemd.
- pawadu 10y agoIts funny, this is exactly how I felt when I saw that comment.
- nurettin 10y agoCould you give examples of some of the difficulties people experience using maven to someone who is not a Java veteran?
- ddalex 10y agoBasically, when something goes wrong, it offers no help in what went wrong. It's a nice idea with a terrible implementation.
- pawadu 10y agoAlso, a lot of things that were trivial before will now have a long series of dependencies.
- reitanqild 10y agoHeh. To each their own. I prefer having my dependencies listed in version control, automatically downloaded, having a tool that can tell me why dependency x is pulled in etc etc.
- 10y ago
- throw2016 10y agoI think systemd the init should be separated from the rest of it. This will allow it be more easily managed, secured, developed and be replaceable by other inits thus retaining one of the most important aspects of Linux and prevent any single entity beyond the kernel from gaining too much influence. The functionality that creates these deeper tie ins to Gnome, udev and others today prevent other inits from working for instance with Gnome. Now they want to add a kernel bus. This will make it extremely difficult to replace systemd. Can any supporter of open source and Linux really support this? A init is a critical subsystem and should have limited scope that is clearly defined, be thorougly tested for that scope and released. Continuously developing and adding features to it does not make for a stable experience. Debian Jessie is now on a outdated version of systemd 2.15 while Systemd is at 2.31. Things like predictable network names are ironically named as now they are not predictable to end users and scripts that work across systems. Things like eth0, eth1, wlan0 abstract the underlying hardware. If your solution cannot even abstract it and retains the arcane bus names and makes it difficult to even read let alone work with the interface name how is it a solution. Things like binary logging may be important to a small subset of users and they should have an option to enable it. But why should it be imposed on everyone by default? The technical debt of niche cases should go to those who want it.
- digi_owl 10y agoIf you want just the init and accompanying ini-files, perhaps give Nosh a look? https://lists.freedesktop.org/archives/systemd-devel/2016-July/037017.html https://lists.freedesktop.org/archives/systemd-devel/2016-Ju...
- mattbillenstein 10y agoI just write one systemd script to start supervisord and ignore the rest of it basically...
- baldfat 10y agoA article about programming to systemd and how it helped the various distributions turned into HN emotional responses to bash systemd. I like systemd and it has helped Linux advance. init was a mess and no one still has come with a golden response that shows the world how anything would be better then systemd. systemd answered a difficult question and hopefully we willsee more similar advancements shortly for Linux.
- mixedCase 10y ago>I like systemd and it has helped Linux advance. init was a mess and no one still has come with a golden response that shows the world how anything would be better then systemd. Just boot the system and hand it off to a service manager that handles unit files. That was a nice idea. Everything else that came after with tight coupling to systemd was not.
- mikekchar 10y agoPersonally, I would have been ecstatic to see systemd if it hadn't have been tied directly to GNOME and thereby installed by every distribution that wanted to include GNOME. My main gripe with systemd is that every other system the main author of systemd has written has made my computer inoperable time and time again. I would have liked to have a choice of using systemd or waiting until I saw it become mature enough that I trusted it. I just didn't want to be forced to use it in case history repeated itself. Opting out of systemd is ridiculously difficult due to that GNOME tie-in. It's one of the most important parts of my system. I still would prefer not to have systemd, but I will admit that it works reasonably well for my purposes. I'm pretty upset about how it all went down, but that's life in the fast lane I guess. Where are the days when everybody ignored Linux? I should move to BSD ;-)
- vetinari 10y agoThe Gnome developers were asking for years for someone to step in and maintain ConsoleKit. Nobody did and there wasn't any hope somebody would. So they took plan B and used logind, which is part of systemd. People are still free to develop shims that would work with other init systems - but so far nobody is willing to do that.
- ausjke 10y agoOn Desktop and servers I had to reluctantly use systemd as-is, no time to replace it basically. never enjoyed it really. On embedded linux I make, I use everything else but systemd. I still worry that over time systemd will be integrated so deeply into linux that it will be impossible to remove and also leave no chances for alternatives and if its monolithic approach will be wrong then it will be too late. Or maybe systemd wants to be everything, to make even linux obsolete
- geggam 10y agoI moved all my servers to BSD. Servers do not need udev gnome or many of the other things systemd has hooked into. I have an ubuntu laptop which requires a reboot every so often for a reason I have yet to figure out. I am not sure about the linux communities direction after the recent drive to systemd containers and other complex methods of doing things which should be simple.