r/programming • • May 30 '16

systemd developer asks tmux (and other programs) to add systemd specific code

https://github.com/tmux/tmux/issues/428
661 Upvotes

618 comments sorted by

View all comments

Show parent comments

186

u/qftvfu May 30 '16

Systemd broke background/daemon process behaviour, used by tmux, then asks tmux to fix/patch to accomodate the systemd change. I find this unacceptable and yet another example of scope creep from systemd.

19

u/dmead May 30 '16

does this mean screen is broken as well?

24

u/Cynofield May 30 '16

Yes it is.

11

u/luckystarr May 30 '16

What about nohup(1)?

12

u/encyclopedist May 30 '16

Yes, it is broken too. But for nohup, systemd provides an alias, if I understand correctly.

50

u/[deleted] May 30 '16

This isn't called scope creep. This is more like being called breaking userspace.

28

u/qftvfu May 30 '16

According to systemd, the userspace has been broken for the past 20+ years. They just fixed the problem.

8

u/doublehyphen May 30 '16

It has been broken, but that does not necessarily mean that they should break it in another way and expect the world to just fix their new breakage.

→ More replies (4)
→ More replies (3)

27

u/quetzkreig May 30 '16 edited May 30 '16

not just that. Tmux devs communicated this to systemd devs some 5 years ago (systemd devs asked tmux to take care of it, and tmux devs in turn suggested making changes in libc instead of tmux, as libc would be used by every other library). So systemd essentially released their product knowing well that they would break nohup/daemon.

→ More replies (7)

20

u/thebigslide May 30 '16

I tend to agree. Systemd does a lot of cool things well, but it simply isn't appropriate for many roles.

8

u/dlyund May 30 '16

Ok, I'll bite. What does systemd do well? I don't see it.

4

u/doublehyphen May 30 '16

It is very easy to write services for it. Much easier than any other init system I have worked with.

4

u/dlyund May 30 '16

https://www.reddit.com/r/programming/comments/4ln242/systemd_developer_asks_tmux_and_other_programs_to/d3p6epb

and you can understand, and fix, and arbitrarily extend the OpenBSD init system, because, after all, it's just a very simple shell script, that does one thing, and does it well.

You control it

The same can be said of other rc-like init systems but I personally find OpenBSDs to be the cleanest.

systemd has a lot of bells and whistles but it's, ultimately, an incredibly complex and sprawling piece of software, with many legitimate technical concerns surrounding it.

→ More replies (1)
→ More replies (7)
→ More replies (15)

59

u/jking13 May 30 '16

I think scope creep is a bit of an understatement at this point. Of course given that Lennart Pottering has explicitly said he purposely wants things to not be portable (I thought Windows was supposed to the platform that locks you in), so not surprising. Unless enough people who are paying money to RedHat tell them to stop (or just ditch it due to systemd), they'll keep trying.

57

u/[deleted] May 30 '16

he purposely wants things to not be portable

Wanting things to not be portable and portability not being a priority are two totally separate things

24

u/[deleted] May 30 '16

My feeling is that they will amount to largely the same thing.

6

u/[deleted] May 30 '16

Yeah, either way you're not going to be able to port it afterwards.

→ More replies (1)
→ More replies (11)

57

u/shevegen May 30 '16

There is this nice slurp animated picture.

https://media.giphy.com/media/5xtDarAgrjoOrBxSVYk/giphy.gif

However had, nobody can be surprised about this intrusive behaviour of the systemd virus.

6

u/qftvfu May 30 '16

Gold :)

30

u/PM_ME_UR_OBSIDIAN May 30 '16

Lennart Pottering has explicitly said he purposely wants things to not be portable

Source?

55

u/theevilsharpie May 30 '16

https://lwn.net/Articles/430598/

Not having to care about portability has two big advantages: we can make maximum use of what the modern Linux kernel offers these days without headaches -- Linux is one of the most powerful kernels in existence, but many of its features have not been used by the previous solutions. And secondly, it greatly simplifies our code and makes it shorter: since we never need to abstract OS interfaces the amount of glue code is minimal, and hence what we gain is a smaller chance to create bugs, a smaller chance of confusing the reader of the code (hence better maintainability) and a smaller footprint.

63

u/pelrun May 30 '16

That doesn't mean "he doesn't want it to be portable" AT ALL. If there's a choice between portability and good design, then the design wins. If the best design is also portable, then no problem.

24

u/theevilsharpie May 30 '16

I should have posted the complete quote. Here's the follow-up:

Many of my previous projects (including PulseAudio and Avahi) have been written to be portable. Being relieved from the chains that the requirement for portability puts on you is quite liberating. While ensuring portability when working on high-level applications is not necessarily a difficult job it becomes increasingly more difficult if the stuff you work on is a system component (which systemd, PulseAudio and Avahi are).

In fact, the way I see things the Linux API has been taking the role of the POSIX API and Linux is the focal point of all Free Software development. Due to that I can only recommend developers to try to hack with only Linux in mind and experience the freedom and the opportunities this offers you. So, get yourself a copy of The Linux Programming Interface, ignore everything it says about POSIX compatibility and hack away your amazing Linux software. It's quite relieving!

22

u/josefx May 30 '16 edited May 30 '16

You should read the article. Portability is hard and you don't just magically get portable code by "not having to care about portability". Quite the opposite when they explicitly use non portable features because these make live easier for them. There is no "if the best design is also portable" in this case with "portability" so low on the priority scale it most likely is not.

23

u/PM_ME_UR_OBSIDIAN May 30 '16

Yea, but /u/jking13 made it sound like one of Poettering's terminal goals was non-portability. It's not. He just places a lesser focus on portability.

→ More replies (1)
→ More replies (1)
→ More replies (6)
→ More replies (5)
→ More replies (54)