194 points · by awalGarg · 10y ago · 282 comments
In particular, if Gnome is starting a ton of background processes that stick around and cause problems, then the fix should be to change Gnome, not to change the default behaviour and break everyone else.
To use the OS sandbox example, this is the reason why OS X added application sandboxing and forced Mac App Store apps to use it, and not anyone else. Systemd's approach is like Apple saying "We're going to start sandboxing everyone's apps, App Store or no, unless you make these changes to your apps.
In this case systemd seems to be reinventing process groups, in a totally different way, instead of fixing whatever the reason is why GUI sessions don't use session leaders.
So it's pretty obvious there really is a problem that needs to be fixed, and apparently so far nobody else has made a real or successful attempt to do so.
No, we shouldn't need to rely on processes behaving nicely. But when a program is broken, you fix that program, not change the entire system's semantics.
Interestingly enough, none of the bugs in other software that is being papered over are in closed source, so it's not like the original issues are unaddressable in the most direct way possible.
Processes using daemon(3) have been around for 21 years, and are used to certain behaviour. Some of those processes behave badly.
systemd is adding functionality to kill all of a user's process when the session ends, no matter what. The problem is that they don't have any way of telling which processes are behaving badly and which ones aren't, so they're telling everyone (e.g. tmux, screen, etc) that they have to implement changes or they'll be killed too.
Fundamentally, the problem isn't whether the systemd behaviour is right, the problem is that it's a huge breaking change and they're asking everyone else to work around the shortcomings of their approach.
> shell managers like screen and tmux had hacks to make them survive sessions ends in the past
tmux, screen, etc. didn't have hacks to survive sessions; they just did, automatically, because of how things worked. systemd is asking the to add hacks to make them survive session ends from now on, when running specifically on Linux under systemd 230+, because systemd is going to change default behaviour for other people's processes.
nohup is not a hack
What systemd is offering has nothing to do with nohup, it's not "a flavour" of nohup it's a completely different thing
Systemd is not correctly killing processes, this was NEVER DONE LIKE THIS, they decided this out of a whim because apparently Gnome can't do the right thing (how surprising)
Its with a recent dbus update implementing yet another session concept (leaving it with no less than two, as best i can tell).
So you graphically log into a distro with a Gnome desktop.
This result in 6 different "sessions" being started.
In the kernel, that is largely transparent.
In X, again largely transparent.
In Gnome.
In dbus, twice!
In systemd.
Seems to me like yet another systemd two minute hate. It's getting quite tiresome to see.
They then decided that, rather than encapsulate fixes for their breaking change in portable APIs like daemon(3) and PAM to allow user space to keep working as intended, it'd be easier to just outsource the labour onto the community by demanding every user space program that was working just fine do the work of adding a couple of hundred lines of systemd specific code directly, encapsulation be damned.
That's an insult to the tmux developers in particular, and disdainful of Open Source devs in general. Don't show up at my door telling me to do a bunch of work for you to fix your shit. You broke the contract; encapsulate the fix so I don't have to care.
Systemd is trying to build a new feature that is useful - reaping processes after logout should help improve security and performance. Think about Chrome having flags to "run background processes after app is closed".
Systemd is trying to maintain backwards compatible behavior by collaborating with developers. We should not do these things cost "that's the way they've always been" is killing innovation.
Correct
> This is no more an insult than removing cgroup write access from processes or any other new kernel feature.
False. Empoyees of a 2 billion dollar corporation deciding to demand free labour from the community to accommodate what they've decided by fiat is the new Right Way is incredibly insulting. The tmux developers do not exist to serve your whims. The community is not here to save you money.
> Systemd is trying to build a new feature that is useful - reaping processes after logout should help improve security and performance.
There's NOTHING new or innovative about this! Processes are already reaped at logout, unless they're nohup'd. Changing the state of affairs to "processes are reaped at logout, unless they use dbus to ask systemd to not reap them" is just a bunch of mechanism churn to get the same result
> Think about Chrome having flags to "run background processes after app is closed".
What would stop Chrome from doing that under this new regime? Literally the only difference is that they'd be accomplishing that via systemd-specific code rather than portable, SUS-compliant code.
Ultimately all this change is accomplishing is deprecating simple, portable interfaces for achieving nohup behaviour with baroque, dbus-laden, systemd-specific ones. Red Hat's goal here seems to be little more than increasing systemd's surface area; otherwise, why not simply hide the sausage-making systemd cruft behind the portable API?
> Systemd is trying to maintain backwards compatible behavior by collaborating with developers.
"Collaboration" is not a synonym for "I have altered the user space contract. Pray I do not alter it further".
> We should not do these things cost "that's the way they've always been" is killing innovation.
"Innovation" is not a synonym for "instead of a daemon(3) call, here's 150 lines of dbus crud to get right back to where you were before".
I think you should check what "backwards compatibility" means, because it's the total opposite of what you're describing
Not just tmux, every opensource project that used established nohup practices. For example, now all of my virtualbox instances are killed when I logout of Gnome on rawhide. This was a feature of virtualbox that’s worked perfectly for years now.
Obviously Red Hat's behaviour in general shows disdain for any devs in any project who had working daemonization code that just got broken.
"Hey, can you implement and maintain new platform-specific code to work around this problem we're going to introduce by breaking behaviour of programs using a 21-year-old API?"
It feels especially egregious because, as commenters pointed out, implementing the PAM API is a better (and undoubtedly more portable) way to do this that the developers of systemd didn't seem to consider. Instead, they jumped straight to "implement a custom fix just for us so our breaking change doesn't break your app too".
Seriously, every single person who feels compelled to offer their opinion based on what is an emotional response to Lennart's (or anyone's) "overreach/arrogance" is contributing little more than noise to the whole process. It's far too easy for someone who doesn't interact face-to-face with someone else to fall in a trap of assuming the worst about another person when there's a technical disagreement; this is a form of cognitive bias that pollutes development in the corporate world all the time. I'm as guilty of it as anyone, and I've learned to be wary of the temptation to project bad qualities on other people who I disagree with but don't interact with directly.
In the open source world it's so much worse though- not only do almost all developers interact indirectly (i.e. not face-to-face), but there are potentially thousands of people who are basically just casual observers who want to jump in to give their 2 cents. That's great! But it's only great as long as those 2 cents aren't just people bikeshedding, or actively trying to make things personal rather than technical. Unfortunately, more often than not it is bikeshedding, and literally the only thing they have to bikeshed about is to try to make it personal. :(
Instead they should take a step back and rethink their proposed solution every time they get strong feedback or face some resistance from the open source community.
They already released systemd 230 with this behavior and the bug reports from users of unstable/rawhide sparked the "public" discussion. (The bug report in the link says this right, but it still comes a week after the release instead of before)
I wouldn't consider that bit to be particularly egregious. The thought process of a systemd developer confronted with a regression caused by systemd changing some well-known behaviour would naturally lead to a solution where program X tells systemd that it needs to be handled differently. It's basically a version of the anecdote that experienced developers aren't better because they know the answer to every question, but rather that they know which question to ask. Apparently the discussion has lead to a better solution (not that I would be a good judge of that), so this seems like a bit of a storm in a teacup.
So now not only have we not achieved that goal, but now we've inserted an additional layer of complexity into the mix.
For years people have been locking their keys in their car and then having a locksmith open the door when they get back. Now, someone is trying to improve the locks so that a locksmith cant open the door and people are complaining that it ruins a perfectly good arrangement.
In this analogy, 'locking the keys in the car' is 'logging out' and the locksmith is 'nohup'.
systemd isn't really out to break nohup, they are trying to fix the logging out process. Sure, nohup has worked for decades, but 'logout' has never worked right.
The problem is that 'nohup' is designed to 'run a command immune to hangups' not 'run a command even after I logout' and there has never been a distinction between an individual connection 'hangup' and a full user 'logout'. With systemd, there is, and programs don't handle the distinction.
If you don't think there should be a distinction KillUserProcesses can be turned off.
This is an example of one of the concerns people had -- and were told to stop spreading FUD -- about systemd in that it seriously overstepped the bounds and desires of an init system.
Killing user processes after logout (when they have been set to not do so, through nohup usually) is not sensible.
Edit: clarification
In other words, if this functionality had been added 21 years ago as well, a lot of mess and confusion would have been avoided and we'd all be happier, but since it didn't the systemd guys are trying to implement it retroactively, which is going to break a lot more stuff than tmux/screen/etc.
Only if you can succesfully determine which ones the user wants to keep running. Otherwise it's just breaking stuff, as this story shows.
if this functionality had been added 21 years ago as well, a lot of mess and confusion would have been avoided
Not really. You will always have sub-standard software that doesn't adhere to the system's declared semantics, and just goes by "what works" (ask the WineHQ guys). Any API that has been around for 21 years will have corner cases where software just breaks. That does not mean you're then free to break the old API yourself.
edit: If you're already using a specific command to tell the application to stay alive (e.g. nohup), you can use the "new" systemd command as well. nohup never related to a "session" scope because that didn't really exist before systemd. A new command _does_ break historical behaviour, but thanks god we do that from time to time. That's how innovation works.
How is it so? I cannot see a single legitimate justification for such a stupid behaviour.
> "session" scope
Exactly. There is no such a thing, and it should not exist, it's a totally alien concept to anything Unix.
What you are describing is systemd becoming a kernel sitting on top of a kernel, second guessing the actual kernel.
... with nohup. Which now doesn't work.
> and no, unix signals are not a sane API
It might not be modern, but it's stable, widely used, and incredibly well documented. Hell, systemd is implementing this behavior using signals.
> Breaking with historical behavior is called progress.
It's not historical behavior when applications are today being developed that rely on said behavior.
Progress is building upon the best practices of the past, not breaking things because a bunch of very low quality, uneducated "developers" who all came from an alien culture simply could not think of a better, idiomatic solution.
I think the problem people have is that systemd developers seem to actually believe this axiom.
Seeing such an emotional reaction so long after the war makes me wonder if systemd can survive in the long run, though.
Seems to be an issue of "The north remembers."
Requesting the specific desired feature/fix is almost always preferable.
I actually let slip an f-bomb reading that. It shows a terrible understanding of longstanding unix philosophy, (and also straw-mans the argument).
Happily, it doesn't seem that was from a systemd developer as far as I can tell from their website. Still, it's a reminder that the userbase (and developer base) that engage with Unix/Linux/GNU is varied, and may not have grown up with the same sensibilities that people my age have about where the right line between user, system and sysadmin should lie.
This is a very relevant remark and highlights the root of the entire discussion, I believe. There seems to be an ideological fault line here. And I think, it is between those who wish for some ideal, all encompassing design and those who have been burned by the short sightedness of such ideals. Grand engineering ideals cemented into closely knit structures are really great on paper. But some years down the line, you realize you have made too many commitments, optimizing for something not relevant anymore. And now you have to circumvent all those greatly engineered structures. It's a bit like looking at satellite cities, the visions behind them, and what has become of them.
The Unix philosophy is mostly about avoiding those pitfalls. But I guess, understanding this might only come with experience.
In practice though, to me that would mean something that while looking pretty and being better automated would come with many fewer hidden parts and many fewer interactions between parts than sysvinit. That is, I'm looking for simplicity, composability, editability.
The implied technical debt of one system to rule them all is a lot over 20 years, and you will inevitably have to get into line with a dominant system as a developer downstream from it.
At any rate, happily this behaviour was publicised enough that I won't spend a day googling it when it happens to me. :)
Thanks. I'm kind of in the same boat, age wise. I have the impression (and this comes from a number of comments online and a podcast with Poettering I listened to lately) that any criticism from the experienced crowd is seen as a sort of elitism of people entrenched in their abilities they honed over many years. This might be the case for many critics, and Poettering may be right to dismiss them. But I'm afraid that the very valid criticism regarding overall design goals is lost in all of this. The systemd team steams on, believing that all naysayers are just stuck in their ways.
This means that if the DE or X develops a fault, you can always fall back to the CLI to get it back up.
But with systemd, the CLI has become subservient to the DE.
I really like my CLI though, and really really want to be able to change anything about my system from vi if need be, so I guess I fall on the other side of that perspective.
They can decide to die when they lose the terminal on SIGHUP (or on any other event), be nicely asked to stop with SIGTERM, and surely can be forced to die with SIGKILL. Everything is there for decades, sane and simple - so I don't really get the idea.
I mean, if some process hadn't considered dying on HUP (i.e. on session close) while it should - it's a bug in that program, go ask its author to fix it.
In fact, the question is should the shell and init environment overrun the (at least 30 year) unix convention that a user's background processes are not killed when they log out?
The reasons given for a 'yes' answer to this question had better be well and truly good, from my perspective. It's not nearly sufficient to say 'some users complain that things are running when they log out'.
If you read the original bug report, this all started because some userspace programs aren't very well behaved, and the typical windows or os x behaviour would be to log out, ensuring the OS kills them, then try them again.
Generally the advice from unix land would be:
1) Don't use those programs 2) Learn to use ps / top and how to kill a naughty process 3) logging in and out is meaningless when it comes to things running as daemons or in the background.
It's pretty shocking to me that someone thinks the best solution is to obviate all that advice. Not that users won't get an experience they expect from other OSes -- they will. But many users will lose a simple experience they rely on, even if they never touch the GUI. That has a bad architecture smell to me, and I think some other solution could be found.
justin@t420:/tmp$ git clone https://github.com/tmux/tmux.git
justin@t420:/tmp$ cd tmux
justin@t420:/tmp/tmux$ wc -l osdep*
95 osdep-aix.c
88 osdep-cygwin.c
80 osdep-darwin.c
133 osdep-dragonfly.c
202 osdep-freebsd.c
41 osdep-hpux.c
98 osdep-linux.c
137 osdep-netbsd.c
157 osdep-openbsd.c
101 osdep-sunos.c
41 osdep-unknown.c
1173 total
Apparently people have been trying to get tmux fixed for FIVE YEARS NOWSystemd is not a platform. And not every Linux runs systemd.
For now...
osdep-linux-sysvinit.c
osdep-linux-openrc.c
osdep-linux-upstart.c
osdep-linux-systemd.c
osdep-linux-epoch.c
osdep-linux-finit.cOkay.
That would be before 1979. nohup was in 7th Edition. I haven't checked 6th.
Ironically, by pointing to the fact that one has to go back through 37 years of documentation, education, user experience, and scripts you are making other people's point for them. Especially by drawing attention to one of the major flaws in the "nohup was new once" argument, which is that in 1979 (or before) there wasn't a prior 37 years built up to contradict. (-:
https://github.com/dspinellis/unix-history-repo.git
has different branches for various unix versions
Seems the earliest reference I could find in there was dated november 1973, but it is from a full import in 77:
commit c849507974bd2c0e2fd8c17e06f6f65b68075ca9 Author: Bill Joy <wnj@ucbvax.Berkeley.EDU> Date: Wed Nov 23 12:43:50 1977 -0800
Start development on BSD 1
Create reference copy of all prior development files
Synthesized-from: 1bsd
Some of the earlier copies i can see were even just shell scripts: trap "" 1 15
if test -t 2>&1 ; then
echo "Sending output to 'nohup.out'"
exec nice -5 $* >>nohup.out 2>&1
else
exec nice -5 $* 2>&1
fi
Research-V3-Snapshot-Development did not have nohup
Research-V4-Snapshot-Development had the nohup man page but not nohup
Research-V5-Snapshot-Development has nohup.ccommit 0281f55d1cf7aa94555d8522d8b37161b97791be Author: Ken Thompson <ken@research.uucp> Date: Tue Nov 26 18:13:21 1974 -0500
Research V5 development
Work on file usr/source/s2/nohup.c
Co-Authored-By: Dennis Ritchie <dmr@research.uucp>
Synthesized-from: v5
Then later v7 reverted back to the shell versioncommit 6144d5b3a973b515977eef01a828cdd82c480fe3 Author: Ken Thompson <ken@research.uucp> Date: Wed Jan 10 15:25:04 1979 -0500
Research V7 development
Work on file bin/nohup
Co-Authored-By: Dennis Ritchie <dmr@research.uucp>
Synthesized-from: v7This is due to a larger discussion that most users don't expect lingering process after logout. https://github.com/systemd/systemd/issues/3382 In these situations, screen/tmux must include changes that enforce this behavior. Today the operating system itself does not reap processes ... but systemd is not doing anything wrong. By adding this change, tmux/screen users will still get the behavior they expect and the rest of the world get a better behaving operating system.
It's breaking historical behaviour
However making tmux try to use systemd-run is a much better solution than making it depend on libsystemd
You might want to see all of the people at https://news.ycombinator.com/item?id=11782364 who are expecting nohup to effect exactly that, with reference to the Single Unix Specification no less.
Who should ever care about the opinion of the non-contributing, useless users coming from the irrelevant platforms?
(Btw, I'm ambivalent on systemd itself)
This can be done at the distro package level. Packagers would edit /etc/systemd/logind.conf and set KillUserProcesses=no to disable it. It's a single line change if people don't like the new default. The behavior itself (killing user processes when the session ends) is quite sensible, and should have been the default over a decade ago, but people got used to terrible defaults and are now complaining.
This is handled at the packager/admin level, but they merged a patch two days ago (https://github.com/systemd/systemd/pull/3373) to fix the policy to let users manage it themselves with loginctl enable-linger. I think it missed the v230 merge window, but could easily be backported individually or at the distro level until the next release.
So, not only can the behavioral decision be managed entirely at the distro level, that decision can be punted down to the individual user if they don't want to explicitly mark the processes they want to continue running.
In any case, wasn't killing user processes already the norm except for the ones which called daemon() or equivalent? And won't the new system kill user processes except for the ones who call StartTransientUnit? I'm having some trouble understanding the improvement, except for the short-term gain until the broken processes start calling the new API.
Whatever you think of it, systemd is doing the "ground-up rewrite" correctly. Normally, you get 90% of the features for 10% of the code in a rewrite, but then the last 10% of the features are the "plugging this thing into the ecosystem of other crufty things" features which bloat the codebase into something exactly as bad as the original.
The only successful way to do a rewrite is to scope your rewrite not to the size of one component, but rather to the size of the whole component ecosystem, such that you get to redefine all the crufty boundaries requiring convoluted code into clean and simple ones. This means you do have to rewrite more things, but each one can stay at that 10%-for-90% size, because none of the bad-API bloat has to come along.
systemd is consuming components of the Linux userland and leaving cleaner boundaries in its wake. The sheer scope of that effort can make the project look bloated—but people forget to compare the codebase with the combined codebases of all the projects it took to have equivalent functionality before.
People also forget to compare the functionality of the entire ecosystem of software—not just the big stuff everyone uses, but the niche stuff—before and after. Linux's original bazaar approach to system software meant that everything worked with whatever components it explicitly planned to work with, and nothing else. Do you know how many codebases contained some random subset of support for logging via STDOUT, logfiles (with or without rotation), syslog, rsyslog? That's what you get with a bazaar approach. systemd's "hub-and-spoke" cathedral approach means that everything just has to work with systemd, and then systemd can ensure that everything works with everything else.
> I really dislike the idea of having one project handling everything on a box
Which is crazy talk because that is one of the selling points to something like openbsd.
Many of these tools have to run in other *nix. Tmux came out of the OpenBSD community. Why would they necessarily want to put in effort to make sure your house is built correctly?
Instead of moving everything to a new platform-specific init system like freebsd's rc system, I instead moved everything to runit. Runit can run ontop of an existing init system, so now I can have this code running ontop of bsd, upstart and systemd based systems without having to change a thing. It's really be a savior for me. I don't touch anything, I write scripts that are about the simplest thing I've ever seen and it just runs anywhere I toss it. I used to avoid writing init scripts like this like the plague but runit has made it quite enjoyable. I've even moved a lot of dev stuff where I had everything running in tmux to runit based control.
I've spent 20 years with this platform and seriously worry about it being as useful the next 20.
With systemd it's not so simple.
More importantly, I think that some of the systemd maintainers have a track record of not really knowing what they're doing, as exemplified by this tmux issue. I have serious worry about running their process as PID 1.
Other than that, totally positive effect: It deepened my interest in OS security and hastened my switch to OpenBSD which was probably happening anyway.
The one that really annoyed me (and is still present) is when it replaced cryptsetup init scripts but did not implement support for root file-system key-files.
For release-upgrades this will result in broken, unbootable, systems - it isn't difficult to imagine how this causes swearing and bad feeling!
For new installs it means loss of required functionality, and lost time and productivity exploring and implementing work-arounds to counter the regression and return to the status quo.
The reason for the lack of key-file support in systemd-cryptsetup? The purist idealism that key-file support patches will only be accepted if they use the Linux kernel's key-ring API (rather than replicate the existing cryptsetup init script behaviour).
Canonical does not spend so much on employing core developers and feeds mostly on upstream.
That in itself is not a problem...but your presumption is wrong. If you track the systemd inclusion process in Debian, you will find that it was not subverted but was a free and open fight. Systemd won on its perceived superiority by people much smarter than me.
The only thing the TC decided is that daemons must be able to run under systemd -- which can be achieved by providing a (cross-init) sysv script, or a systemd service file.
While RH and Oracle has a long history of cooperation, Oracle now have their own distro thats a fork of RHEL.
This fork prompted RH to end some policies that made life easy for CentOS (who now happens to be sponsored by RH), regarding the packaging of various patches.
They are not tying together originally independent projects so that others has to conform or else. They build their own thing to their own needs, and if you find you have the same needs then your free to help out.
This behavior can be disabled by the distro or admin with a single line change, and there's a policy for users to be able to set the behavior for themselves with a single line. They fixed a problem with that policy two days ago, but the fixed policy could be backported for those who need it immediately before the next release. This is in addition to being able to control it on a per-process level. Obviously they gave us so many ways to control this because they wanted to break things.
"Breaking everything" is nothing but hyperbole. This change won't make it to the users unless the package maintainers just let it through. And I can guarantee after this stink that every systemd packager will be informed of the decision.
Yes, asking tmux to request this behavior by dbus was amazingly short-sighted, bordering on stupid. I don't think anyone really wants to argue that. Plenty of developers get caught up in the importance of their project and fail to recognize that not everyone else wants to use it. So he's easily earned some criticism.
I suspect it was well intentioned; he probably heard people complaining about how this change affected tmux, and wanted to help people "resolve it". He obviously didn't understand that this is not the way tmux would want to handle it.
> Redhat is leveraging its strong position ... to bend all Linux distributions to its way > guided by a desire to keep Canonical penned-in
This reactionary stuff is completely out of hand. We have people:
* claiming that the default should always be to let everything run forever because that's the way it's always been isn't much better. Since the moment Linux supported multiple users, letting processes continue after logout was a bad default. * insisting that any compiled code beyond the absolute minimum in the boot process is a bad idea. * Insisting on bad faith when developers don't consider their singular workflow. * Stating that standards don't matter if only one system implements them. Despite the fact that most standards start with 0-1 implementations. * engaging in constant tinfoil hat conspiracy claims against Gnome, Redhat, and any other group of contributors larger than 2 people. Obviously they're trying to control us and not, you know, trying to make things work the way they want to work. The fact that these corporations fund major portions of the ecosystem and contribute heavily to all levels of the stack doesn't matter anything - they're obviously trying to get a "monopoly" on linux through open source code. Or working with the NSA. Yes, someone's actually said that.
It beyond ridiculous to think that there's anything guiding these decisions other than the perception of what makes a good product to those involved. They might be wrong, but they're not malicious.
It's disgusting that these systemd threads always spiral out of control like this, stirring up a disturbing level of vitriol. We have constant mudslinging over things that can be fixed with default configurations at the distro level. The fact that we still have these periodic flamewars and monthly hatefests about any groups or projects (even systemd) makes working in the FOSS community an undesirable minefield. We should be embarrassed as adults that we lack the self-control to deal with this in an adult fashion.
The old state of affairs is dependent processes are killed by default on log-out, but there's an opt out method.
The new state of affairs: dependent processes are killed by default on log-out, but there's a new opt out method.
The only difference is the old opt-out method is now ignored, in order to reap the misbehaving Gnome processes that use it - until of course those processes adapt to the new API or some other processes do something similar, and we can start the game anew, instead of ever fixing the misbehaving code...
This behavior is neither old nor bad and painting it as such is just rhetoric.
When the 'session' that spawns a user daemon ends, usually via logout, the child processes receive SIGHUP which notifies them that their controlling process has exited. Most processes respond to this signal be terminating. However, if a process is intended to persist, then it will simply ignore the signal and continue running.
Now, if we're going to have a rational discussion about this then you need to explain what is wrong with this model, and why transitioning to a systemd specific dbus interface is an improvement.
> new better way
Which has a hard dependency on a specific init system reducing portability. UNIX signals are stable, documented, and so portable you can even use most of them on Windows.
As someone in the linked issue remarked, this will end with everyone calling bar() if they want to persist (the same way they already called foo()), and we'll still have the same level of persistent process issues, but with a systemd dependency.
Worse, this isn't "the systemd developers have proposed a new common API for simplified persistent processes across platforms", but a hard dependency on this particular revision of the systemd dbus interface, or using the systemd-run application to generate a user service file.
I personally don't think that systemd and subverting unix philosophy is worth the trade of faster reboot times on my servers. It solves a "problem" that I don't have with a middleware solution that I don't want.
I have a eight-core CPU. Do I want to wait 80 seconds waiting for my laptop to boot because it is using only one core of CPU? Or do I want to wait 20 seconds waiting for my laptop to boot using all the cores available? I do not know what your use-case is, but to me, the choice seems pretty obvious. Can you provide any reason why it is a "perceived" issue, not a real issue?
EDIT: 80 seconds or 20 seconds are not the hard numbers, these are just used to show 4x speed-up on 8-core CPU. Also, why the downvote? Is HN becoming another echo chamber where people can not accept different opinion without downvoting?
And for reference I have compared sequential vs. parallel on rotating disks and SSD for myself. And there was almost no difference in boot time between both (only significant speedup was from replacing the rotating disk by the SSD).
systemd myth #2: systemd is about speed
I'm aware of their propaganda.
It seems that the problem is that some apps need a feature/toggle that would kill them on logout, but the daemon call doesn't allow that - so a reasonable fix is to make such behavior possible (i.e., new api call), and change those apps who need new behavior instead of changing those apps who rely on this behavior staying as implemented, documented and intended originally.
"Desktop" users with their silly "issues" should go somewhere else and leave Unix alone.
Were you unintentionally playing a parody of a traditionalist here?
I can't really say I have much of an opinion on systemd, aside from using it on newer systems and discovering that it hasn't really affected much. But it does seem that there's an unnecessary amount of antipathy between views on this issue, to the point where any discussion about it is difficult to extract any value from due to the noise. This comment kind of sums that up - issues of desktop users are important for desktop users of UNIX, and dismissing that seems a little irrational.
Systemd is ill-designed throughout, and all of its design decisions do not have any place in Unix world. They're solving the silly desktop "issues" (note the quotes again - I do not believe any of this is a genuine issue at all) always in the most retarded and convoluted way possible.
Another issue with tmux, is that maybe you want to have your ssh-agent available in it. To do that in a user friendly way, you have to start the ssh-agent first, then start tmux from a shell where you've exported its variables. Good luck with this now...
Very dissapointed with RedHat.
In this case, the management of user processes is a real problem. It's very easy to accumulate lots of forgotten processes on shared machines with long uptimes. Think ad-hoc scripting servers and jumpboxes here. Think nohup'ed perl scripts that hung waiting for something that'll never happen.
When you run "screen" or "tmux" you expect them to survive a broken session (i.e. you expect them to behave like an independent session). However, when you run something under "nohup" you mostly expect it to survive the controlling terminal going away (a particular screen window or SSH connection being killed). You may be okay with it being killed if you no longer have a session to the server. A user process running in the background without a controlling terminal isn't a service, and from my experience most users don't expect it to be. There is a subtle difference between a "session" and a "connection" that's not properly implemented without systemd (and can be argued not to be properly implemented _with_ systemd).
The thing is how to implement this without "screen" or "tmux" explicitly informing systemd that they want a new session. Touching any API that's used beyond terminal multiplexers defeats the whole purpose.
Nice. (/s)
But as pointed out already on this page, that would be to miss the wood for the trees. There are many programs that are hit by the fact that they call daemon() with the idea of escaping being killed at the end of the login session and yet are still (now, as of systemd version 230) killed by systemd at (final) logout. The systemd developers themselves mentioned screen and tmux. But others have already mentioned mosh-server and deluged (ironically in the bug report that supposedly drove this systemd change). It will almost certainly affect things like emacs --daemon as well. The list grows on and on.
* http://askubuntu.com/questions/338135/
* http://blog.refu.co/?p=1296#comment-61675
Should the systemd developers fork emacs so that they have a logind-aware version of emacs --daemon?
A user_daemon() interface is the Right Way. Processes should not survive past the user session without some fancy footwork, not as a default matter of course. Applications will have to be reworked in some cases, but that's because linux has been subject to bad userspace practices all over the place for decades and after the big issues of drivers have been hashed out, time for a little objectivity in handling processes.
Either way, dissent is futile. Jump to a niche distro or ditch GNU/Linux entirely if systemd bothers you.
I think there is some good intent in systemd's change. But they should have approached tmux/screen/community before making the change and a release which broke things. They should have asked for feedback and such and see if tmux is willing to do what they propose. Simply hammering over things as if you hold powers over other's codebases doesn't come off as very positive.
But oh well...
It's nice, no drama, things are where you expect them to be.
Am I alone in thinking such comments are ostensibly helpful but in fact passive aggressive, because they stifle the user community's only relevant channel of complaint?
And that is why I use tmux.
As a BSD user I started using tmux as soon as I saw it imported into pkgsrc in 2009. What a pleasant surprise it was, I remember well. I live in textmode and everything about this program's design was appealing to me immediately. I am very fussy about software and that is rare. I was so excited I even emailed the developer with a dumb question, which is not something I do very often. He's an OpenBSD committer. Surprise.
At that time there was virtually no online discussion of tmux that I had seen.
In the graphics dominated world we live in, I am amazed at how popular tmux has become.
Why make such a change instead of just making it optional? What would be the impact in such a case?
Did they announce it well in advance and document this?
If not, then the question that springs to mind is "I don't want these guys in charge of helping me administer my systems."
Imagine updating via apt or yum, and having a bunch of important processes killed with no warning when you log out for the day.
All that happened in v230 is that a default of off was flipped to on, nothing more.
What people criticize is that a default was change breaking behaviour and biting people who don't expect it. The feature is useful for system administrators who want it of course
Usually log outs are already instant so I'm not sure what problem this fixes.
So your problem is that you haven't spent enough time learning to configure your ssh according to your needs. The cool thing is that ssh configs can be done for a specific session (if it happens just once in a while or you experiment about the right configuration), it can be done per target (in case you want to react differently on your personal blog and your company development host), and globally (to apply always). Have fun reading. You may find that ssh can solve a lot of problems and in some people's mind even solves problems like other tools but more elegant (I personally prefer it over http-proxys and VPNs as well).
Making it explicit means you have more control about what will continue to run.
I wonder if this breaks mosh as well, if it's anything with per-user persistence.
* https://github.com/mobile-shell/mosh/blob/master/src/fronten...
Systemd’s change is just "processes have to explicitly declare they are long-running, or they’ll be killed".
How else would you do it?
Most systems have a single human user anyway and there is no need for them to log out. For systems that have multiple users it seems more convenient to be able to pick up where you left off.
Maybe we need a way for people to lock their screens without traditionally logging out... wondered the person who implemented the functionality 40 years ago.