Systemd Starts Killing Your Background Processes By Default (blog.fefe.de)
New submitter nautsch writes: systemd changed a default value in logind.conf to "yes", which will kill all your processes, when you log out... There is already a bug-report over at debian: Debian bug tracker.
The new change means "user sessions will be properly cleaned up after," according to the changelog, "but additional steps are necessary to allow intentionally long-running processes to survive logout. To effectively allow users to run long-term tasks even if they are logged out, lingering must be enabled for them."
The new change means "user sessions will be properly cleaned up after," according to the changelog, "but additional steps are necessary to allow intentionally long-running processes to survive logout. To effectively allow users to run long-term tasks even if they are logged out, lingering must be enabled for them."
They are racist, xenophobic, Islamophobia, rapists, misogynists, warmongering, fecal demons.
Trending 3.. 2.. 1..
No, really.
In my mind if you want background processes to stay alive, you should explicitly state so, and not have the system make the assumption, even if it has been the convention that background processes do stay alive. To me it just seems a potential vector for a backdoor or something, I dunno >
Better feed it. :)
"user sessions will be properly and improperly cleaned up after..."
FTFY.
"National Security is the chief cause of national insecurity." - Celine's First Law
A multi-user system shouldn't allow unpriviledged users from consuming resources indefinitely. It's too easy to starve a system or resources. I think that's one of the reasons behind the isolation dockers provides in the first place. Shut down the container and everything gets cleaned up.
This might just be the final straw that gets me to move over to one of the BSD Unixes. I ran OpenBSD a few years back and it was a solid OS, may have to load it back up on my beater machine and give it another whirl.
Personally I think this is a very good idea, and I know it's something I've considered on a few occasions.
The reason this is a problem is that when using home directory encryption you need a quick an easy way of making your data inaccessible, but as long as processes are running as your user the volume can't be unmounted, leaving your data open for everybody to read.
Killing all your processes and unmounting your encrypted home directory is a Good Thing(TM), and is semantically in-line with the meaning of 'Logging Out', aka - 'Im no longer using this computer'.
If you really want long-running processes it's pretty easy to create a separate services account, or use systemd containers, or docker etc.
Why so much fuss?
Looks more like a Debian thing. It's the Debian maintainers who decides what the default value of configurations should be.
For desktops however this sounds like expected behaviour which is nice to finally have.
Michael Biebl seems incredibly arrogant at https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=825394#40
and clueless at https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=825394#45
Yay! Awesome!
systemd is by far the stupidest thing to happen to Linux, ever... It's not that different from Java. "Oh, new clean shiny thing that is lean and mean!" Then they halfheartedly learn what the real world requires and half-ass it ever since.
So, "screen" has always been a good way to ensure that processes don't get killed randomly by disconnections, logout or X crashes.
Then comes systemd and kills all your processes at logout, even when launched with screen.
Finally, then comes Poettering, explaining you that you're a moron if you expect to keep those processes running.
Seriously, the systemd devs make it really hard no to hate them.
So they do what everyone else has always done which is extremely sensible in multi-user environments, and because of that they get a deceiving headline on ever-decreasing-quality slashdot. If I want to read untrue clickbait I'll read yahoo.
Oh no! We've always done it this way!
My first program:
Hell Segmentation fault
Fear not, people of Slashdot, because there is an option to maintain background processes, even after user disconnection.
But this option is not "on" by default. So, yeah, screen and tmux all of a sudden become useless, unless you fiddle with the knobs.
Seriously, now, fsck systemd: Slackware and OpenBSD for me from now on.
Even Mac OS X has the decency not to mess up your tmux sessions when suspending and restoring your session. Fsck systemd.
The right to offend is far more important than the right not to be offended. (Rowan Atkinson)
Pick your poison
#fucksystemd is all I need to say ever. I never ran so far away from a Linux distribution as when systemd started taking over everything. I had to abandon Fedora which I'd been using for almost 10 years at the point I realized it was killing my servers with its bullshit. Thanks to its horrible "integration" with syslog, I lost a lot of valuable log info when my site was under attack. Go ahead and mod this "Troll" if you don't understand how Unix/Linux has worked for all this time...
Let's say that I run a program that is "old", BUT I can't upgrade it to the "latest version"...because something else running on the server REQUIRES an older library (no...I can NOT use LD_LIBRARY_PATH)...what happens if I just - ON MY DISCRETION - want to go out and check for a new version of the software I use and download it - IF I WANT TO...
A "code/script" snippet...
#the lftp script will download if it sees a newer version of the software I want
nohup lftp -f get_my_stuff.script &
My script could only run a long time if newer stuff is available to me...
Does systemd have the "right" to kill my proc? HELL NO!!!
Again and again I've heard people like you suggest that Slackware is a replacement for a modern mainstream distro like Debian. Others suggest Gentoo.
Well, the reality is that neither is sufficient.
Slackware is, to put it politely, very primitive. While simplicity is a good thing, Slackware takes it to the point where it becomes a liability.
When using Debian, it's possible to get a full-featured desktop or server set up with very little effort, and this can be done quickly. Thanks to sensible defaults and a practical installer, manual configuration is kept to a minimum.
Slackware, on the other hand, requires far too much manual intervention just to get a minimally usable system set up. Maybe this isn't a problem for a hobbyist who tinkers with Linux on a weekend, but it is a problem for people who are seriously using Linux, especially in a business setting. They can't afford to waste time and effort on Slackware, especially if a distro like Debian manages to avoid such waste.
Gentoo really isn't much better. It's not as bad as Slackware, but Gentoo is still a niche distro, and its whole compilation strategy is wasteful for anyone but hobbyists.
At this point, sensible and experienced Debian users have realized that Debian systemd/GNU/Linux is a lost cause. They've moved to FreeBSD ages ago, or are in the process of doing so. If Slackware and Gentoo are the only viable non-systemd options left for those who want to use Linux, then Linux is just not suitable for use.
FreeBSD gives much of what Debian used to give: stability, reliability, trustworthiness, an excellent packaging system, a superb installer, sensible defaults, no systemd, and an environment that's perfect for both desktops and servers. In some ways FreeBSD is even better than Debian traditionally was: much of the FreeBSD code is released under truly free BSD family licenses, rather than the far more restrictive and less-free GPL family.
This story: Systemd Starts Killing Your Background Processes By Default
Previous story: Massive Backlash Building Over Windows 10 Upgrades
That's the best conjunction of two headlines that I've noticed in my many years here.
FWIW, I'm a happy PC-BSD user, not that this is a panacea by any means, but there does seem to be less of the "stupidity on a rampage" form of collateral damage.
I pay the price with a lot more "W?TF doesn't Firefox play this media type either?" and I find I have to page bounce to Chrome once or twice almost every day (my FF is plug-in central, my Chrome is naked install).
Unfortunately, I can't even brag that PC-BSD is a successful Poettering removal tool, as I still had to fight some nasty battles with PulseAudio due to rampant ecosystem taint in the package tree that PC-BSD doesn't have the resources to strip out (nor, sadly, does the entire *BSD Avenger collective). Get this, the GUI control I needed to mess with only appears if certain PulseAudio processes are active, but because of my debugging mode, those processes were timing out before I could visit all the places where I thought the GUI control might possibly show up (discoverability anti-pattern in anti-flagrante delicto).
Every large software ecosystem must eventually manage breakage. There are good ways to go about this, and there are bad ways to go about this, and then there are Poettering ways to go about this. It's the added ego problem that seems excessive.
> A multi-user system shouldn't allow
> unpriviledged users from consuming resources
> indefinitely.
Don't worry, Systemd-OS will implement process accounting, soon.
If I nohup a process then I want it to persist. Why invent something different when that still works fine?
Martin Pitt http://www.piware.de/
Can somebody please fire this guy, he clearly has no clue AND IS DESTROYING LINUX
Sure, FreeBSD is great until those lazy fuckwits forget to test their shit and you are left without /lib when freebsd-update does it's thing like what happened at the 10.1 upgrade. At least Debian tests their upgrades.
Why does Google Maps on FreeBSD default to lite mode?
I was just using Google Maps, and it reminded me that on PC-BSD (both Chromium and FF) Google Maps only runs in Lite mode, despite having all the requirements.
You can fix this by spoofing your user agent string to an older browser version. As stated, PC-BSD rocks, but it's by no means a panacea (though no great fault of their own).
-1 Google web coders
Any Poettering haters out there who know someone who works at Google, please put the word out that this is not acceptable.
"it should rather be disabled .. by setting KillUserProcesses=no in /etc/systemd/logind.conf ." ref
Apparently, according to some reports, this came about because Gnome can't properly kill off all your sub processes when you log out.
So, systemd to the rescue. Why is anyone using gnome again?!
They are far too dirty to touch, let alone clean up.
but it is a problem for people who are seriously using Linux, especially in a business setting
Serious users know already the use cases for the installation. Configuring just what is needed and disabling anything else is just a benefit, not a hassle. A business user who cares for the quick installation is likely a smaller business user wanting to replace a Windows desktop. In that case the problem is solved with a suitable Linux or BSD distribution.
Give Devuan a spin. It is very much like Debian but without systemd.
ransom for their re7el Pin our gay
Ordinarily, a user's processes SHOULD all be killed on logout. They're no longer logged on; they're no longer using or entitled to use the machine.
However, there will be cases where something long-term needs to go on. How hard is it to add daemons or background services in an administrator or batch context? That's where the long-term stuff should go. Olde days with VM/CMS: CMSBATCH was available to ordinary users if some job would run too long to be practical in foreground in the user account. Submit; it runs when scheduled (by the user or the system, depending on load) and returns results to the user account.
... systemd is less than perfect?
Changes like this make me wonder if the systemd developers even use Linux beyond their local development workstations. This isn't just an inconvenient change, it breaks the expected and decades old behavior of how Unix machines work. This breaks ^Z/bg/disown, it breaks screen, it breaks nohup, etc. Yes, these things can be made to work still but, why do I need to jump through hoops to re-gain the functionality I've relied on for decades? If I'm not aware of this change, how would I even figure out why all my screen sessions died when I logged out? What benefits am I gaining by having this be the default behavior?
One of many systemd bugs is that it sometimes leaves user "systemd" processes running even after a user logs out. Over time this can add up to many lingering user "systemd" processes. I've seen dozens of simultaneous, buggy user "systemd" processes lingering fter users have logged in and out a few times. The processes have to be manually killed. Rather than fixing the problem they've apparently "worked around it" by kill all login processes instead. This did not occur pre-systemd.
So will it also kill tmux and screen sessions??
Sorry, but "Devuan" sounds like a half-black, half-Puerto Rican ladyboy. I can't seriously consider using it.
Log out = no more of your processes. Normal. Having "nohang" processes, for a regular user != root, is the exception.
Slashdot, fix the reply notifications... You won't get away with it...
https://en.m.wikipedia.org/wiki/List_of_ethnic_slurs
That's pretty much what I did a couple weeks ago. Then I realized "wow, this is so nice and clean running! It does exactly what I want, the way I want it!" And that is the whole reason I started with Slack way back in 1996.... The thing about systemd and pulseaudio is that they provide exactly *zero* new features that I needed, whilst severely screwing with the system. I went thru RH, SuSE, Debian, and now back to Slack... RH in particular lately has been pulling some bonehead moves WRT the traditional Linux base.
C|N>K
I wish I had mod points, because I just squired milk out of my nose.
"Somebody has to do something. It's just incredibly pathetic it has to be us."
--- Jerry Garcia
These people (Lennart et al) just do not get the concept of a multiuser operating system so it makes perfect sense to them.
Basically systemd is built on a totally fucked up concept - a concept in which whatever the users do is not important, only system resources count, and if the users do not like it, they can go fuck themselves
That is basically what systemd is - and it perfectly reflects the way systemd's proponents think as well
Muchas Gracias, Señor Edward Snowden !
You don't want your long-running processes to have root privileges. It's a massive security hole. Many of the Linux daemons for server use run on less than root privileges (Apache, MySQL, etc).
A better approach would have been to have a group that had the ability to make processes run after logout. That would be a security improvement, since you could then determine which users had the rights to have persistent processes.
This is change overturns about 40 years of Linux/Unix computer history. The concept of nohup is used everywhere in Linux server land, and breaking that programming idiom will have significant ramifications.
Usually mysql and the like are started by root, but immediately do a setuid (mysql user). These processes will not be killed at log-off.
Slashdot, fix the reply notifications... You won't get away with it...
why does he have such a following at Debian? Is he the devil or what? What an idiot.
fuck em
"systemd is an init system used by some Linux distributions to bootstrap the user space and manage all processes subsequently, instead of the UNIX System V or Berkeley Software Distribution (BSD) init systems."
I run Slackware since ... ever. At about 20 years. And using it as my primary desktop since ... ever. Browsing web, handling e-mail, watching movies, running LibreOffice, managing family photos, developing in C and Java, playing (admittedly older) games. Yes, occasionally I do some steps that I would not do on another distro - often because I want to, not because I need to. But the benefit is a system that is easy to understand, that does not screw up by itself. On the other hand I use some Ubuntu machines at work, and I'm baffled that some tools (nmap, whois, rpm2tgz, locate, ... ) are missing in default install. So I'm finding Slackware very usable.
I had this happened to a PFSENSE upgrade. It made me very unhappy because I had no internet thanks to them. Luckily, I was able to download pfsense through my cellphone and copy over all the files, problem resolved. But it wasted 2 hours of my time. I never had this problem before, I can't believe that every upgrade, be it Windows, linux or BSD, you have a high chance of something breaking, where before it would never happen.
But that's exactly what systemd does! It gives you tools to run these processes in their own scope, so that their resources can be properly managed, and the admin knows that these processes are meant to hang around.
"I know I will be modded down for this": where's the option '-1, Asking for it'?
if you don't like gentoo then try arch or antegros
Despite ongoing challenges, I am yet to see a use case presented that the existing initd system cannot handle if you take the time to understand how to use it properly.
I genuinely want to know why systemd is better than initd? As now I am being told that I'll have to make modifications to the way somethings that have worked for years. Do you systemd proponents actually have *any* experience on enterprise systems and how hard it is to get root access to modify these behaviors?
If you want systemd so badly - why don't you just make it a service of initd? Why are you guys, who cannot demonstrate you know any better, subjecting everyone to use this?
My ism, it's full of beliefs.
To me systemd is looking more-and-more like an industrial sponsored trojan horse (i won't be dragged into who sponsored it) to upend linux as the ramifications of this 'thing' is becoming increasingly ugly. It is truly a case of fixing something that wasn't broken.
Please add to the /etc/apt/preferences.d directory a file with the following contents:
Package: systemd
Pin: origin ""
Pin-Priority: -1
or Void Linux....
While "clean up after yourself" is generally a good idea (ask your mom!), in this case it is going to cause a lot of problems because it is being enforced from above in ways that will have unintended consequences because the enforcement mechanism doesn't understand context. I am sure that screen/tmux aren't the only tools affected.
Heck, I implicitly rely on persistence of background processes myself on a semi-regular basis. Doing something that runs counter to this expectation is going to break random stuff, and result in a lot of pissed off sysadmins. This behavior arguably makes sense for desktop distros, but given that Debian is primarily a server distro it should not be the default. Let downstream desktop distros like Ubuntu/Mint/etc. modify the default behavior, if they deem it appropriate (it doesn't even require a code change, it is a config option).
It is also symptomatic of the "all bow down before systemd" mentality, and I have a big problem with that. They may have good intentions, but there are some serious issues with how they're going about implementing their vision.
Again and again I've heard people like you suggest that Slackware is a replacement for a modern mainstream distro like Debian. Others suggest Gentoo.
Well, the reality is that neither is sufficient.
Slackware is, to put it politely, very primitive. While simplicity is a good thing, Slackware takes it to the point where it becomes a liability.
When using Debian, it's possible to get a full-featured desktop or server set up with very little effort, and this can be done quickly. Thanks to sensible defaults and a practical installer, manual configuration is kept to a minimum.
Slackware, on the other hand, requires far too much manual intervention just to get a minimally usable system set up ...
A.C. --
Please define primitive, very little effort and manual intervention.
I can have a fully functioning Slackware system up and running in 30 min, including formatting the HDD with very little manual intervention.
Slackware 14.2 is about to be released. It boots either BIOS or EFI and runs Linux 4.4.11 and a number of Desktop Environments, all without systemd.
There is now a set of 'slackware live' ISO images where I can run with persistence and optionally encrypted from a USB Drive:
http://docs.slackware.com/slackware:liveslak/
When I like what I see, there is an option to install liveslak to the HDD.
As I said Slackware 14.2 is about to be released. This version has succeeded in leaving systemd out while still being able to run the most recent releases of upstream Apps.
Have you actually looked at Slackware ?
There's a lot to like.
-- kjh
WTF!? Do one thing and do it well.
Every year Linux turns more into Windows.
Parent modded currently as +5, Insighful, my rectum... +5 Anti-SystemD sounds more apropos.
FreeBSD gives much of what Debian used to give: stability, reliability, trustworthiness, an excellent packaging system, a superb installer, sensible defaults, no systemd, and an environment that's perfect for both desktops and servers.
You forget: FreeBSD also gives precisely the same as SystemD does:
the need to learn a new system. Both will look sortof familiar, but both will bite you when you least expect it.
True, FreeBSD questions have a wealth of answers on the 'net. But I'm sure SystemD questions will get answered too, especially now that all major distros are going SystemD.
so, everyone is saying: "never mind, is configurable" but:
- somehow it is the default option, changing how debian worked from the beginning
- not only that: is sending a clear message to the bad programmers that made this a necesity in the first place: dont worry about closing your deamon, systemd will do it... and a couple of years into the future all the gnome daemons will remain alive so no one will really have the option if using say pulseaudio (I say gnome because I think they are the suckers that left garbage running without a purpose)
BIG FACEPALM
PS: I wasn't a hater of systemd until now
Don't use systemd. It violates the very core philosophy of Unix.
And on the Eighth Day, Man created God.
Don't break user space. I wish Linus would come down hard on Poettering.
Having said that, you know I hate what systemd did here. But Linux's "one size fits both server and desktop" approach is also to blame.
Most distros come optimized for servers. A different set of kernel parameters would make for a more responsive desktop system, but I need to dig around the internet. How about asking whether a new system is best described as a desktop, laptop, or server? How about having packages that have settings and even patches for specific machines?
Alpine Linux. The default for Docker, very simple, light and configurable.
I left Windows (when it was 95) for Linux, because all I could do more was copy/paste some things into the regedit that I had no real idea what they were doing.
With Linux I had a system that I could do things myself (and screw it up myself).
Now we have a BIOS that wants to do everything, running a boot loader that wants to do everything staring a GUI that wants to do everything with a Desktop that wants to do everything that runs a browser that wants to do everything to visit a site that wants to do everything.
And if you have an issue, they all yell "It wasn't me." and point their fingers to others as if they are toddlers who stole candy.
Don't fight for your country, if your country does not fight for you.
systemd seems to want to fix the problem that Linux is a successful server OS.
"we are all atheists about most of the gods that societies have ever believed in. Some of us just go one god further."
How about doing anything that takes a long time and you don't want to remain logged in for it to complete?
You use screen for that. (My phone, SailfishOS powered Jolla, has this kind of session clean-up enabled on its systemd. Screen is *the* way to do long-duration running).
Or nohup (though I'm not sure if that one is considered as a separate login-session)
so you redirect stdin to /dev/null, stdout to one file, stderr to either the same file or another file,
If you just muck around with redirections and process in background, chances are it won't be correctly dettached/disown.
And in what way does this new mechanism "enhance security"? Running something in the background after you log out doesn't give you any more privileges than if you remained logged in.
It's 2016. We're at the Internet Age.
You don't need root privileges to wreck havok on the network.
And End-User's privilege level is far enough.
Same to do shit on a user's home directory:
A ransom ware doesn't need root privileges to encrypt all end-users' data neither.
e.g.: a Firefox browser of which you've closed the main windows, thus quitted the GUI. But for some reasons there's still a process running in the background.
(It does happen from time to time, when its clean-up procedure is stuck in some loop).
Such a process, which is clearly *not a daemon* would still linger around under older rules, and if that daemon has network access still open and could be hacked, then damage could be done. The setting in logind.conf is one way to handle this kind of scenario (and apparently the debian packagers have decided to turn this on).
But normally, there are clear rules that one must follow to create a daemon: .service conf file that defines it as a daemon.
- old style, pre-systemd: double-fork so the grand-child process gets assigned to PID1, along the necessary file descriptor handling.
- systemd-style: normal process, but launched using a
For anything else, you should use at best screen.
"Sufficiently advanced satire is indistinguishable from reality." - [Tips: 1DrYakQDKCQ6y52z6QbnkxHXAocMZJE61o ]
much of the FreeBSD code is released under truly free BSD family licenses, rather than the far more restrictive and less-free GPL family.
As an (mainly) end-user: go fuck yourself you selfish prick. The BSD license is only "less restrictive and more free" than the GPL if you wish to lock up the code. The only thing the GPL does is put the onus on the entire chain of developers to give their (shitty) code to us poor sob end-users, so if the worst case happens we can try to save ourselves.
Is it possible to install amazon linux on a machine? It seems that is still systemd free, and its a very good distro for servers....
Anyone?
You will now be upgraded.
If non-buggy software is running in its own process group, that's a pretty darn good indication to a competent sysadmin that it is meant to hang around.
That GNOME software is buggy should be news to nobody.
The systemD teams reminds me of "the team".
You know the one that keeps submitting those changes Friday at the end of the day, so that everyone coming Monday discovers that the build has been broken. So you spend the next two days chasing around things that they broke. Meanwhile the managers are wondering why the project is falling so far behind.
I think in the long run Linus is going to take it over and do something similar to git.
But that's exactly what systemd does! It gives you tools to run these processes in their own scope, so that their resources can be properly managed, and the admin knows that these processes are meant to hang around.
If systemd needs a special tool to know that a process which has been detached from its parent is meant to hang around, it's not very smart.
If Poettering can't make pulseaudio terminate on logout like a process should, maybe he should fix that.
"You're right," Fisheye says. "I should have set it on 'whip' or 'chop.'"
But its perfect for the GIMP.
If you want Debian without systemd:
https://devuan.org/
Systemd, you've solved a problem that was never really much of a problem.
“Common sense is not so common.” — Voltaire
RedHat managed to sway Debian and by extension Ubuntu didn't have the will nor even did SuSE.
Horseshit. Stop acting like this is some big conspiracy. The pages of pro and con discussion are still on the Debian wiki. Systemd was selected because it was technically better than upstart, not an unholy maintenance nightmare like SysV, and had more features than OpenRC.
Systemd and cgroups are fixing things that have been broken since the 70s. Usably broken, I grant you, and well-known, but still fundamentally flawed. We have some forty years worth of technical debt accumulated on top of these systems, and frankly I'm surprised that they haven't broken more things. We should not pretend that there are not logical reasons for the changes nor that they are not subject to public scrutiny and input. It definitely looks like a big problem though, if you ignore those factors.
Those who advocate genocide deserve every protection afforded by law, and none afforded by common human decency.
... and all your process are belong to me.
I always thought child processes were killed when the parent was killed, anyway, unless it was deamonized with nohup. I dont know whats new here. The behaviour can be disabled, so if you dont like it, just disable it? Whats the big deal.
Can anyone say zombie process? Its long been the case that if you kill a parent process, children get killed to. Unless, you demonize it with nohup. You can also disable the behaviour in systemd.
systemd is overall a good concept, and is not some monolith. Its a good idea to have the init system be a IPC standard using DBUS, the kernel creates system event messages on dbus, you can have an init daemon listen for these messages and have whatever logic you want in there, if you want to start a process when the network card goes up, you watch the dbus for a network card up message from the kernel, when recieving this you will start your process. When a process is started, that can be announced on dbus as well. The possibilies, modularity and decentralization and configurability of this model far exceeds that of the old system. Highly modularized and decentralized, even more so than the older init model. The old system V init is still supported, so if you dont like the new style, you can always set your services to start with a traditional sysV init script. So whats the problem?
There's a program called screen. It's been around for decades. Used to be we'd lose out connection on our dialups, then firewalls used to get us due to inactivity. Someone wrote an ingenious program called screen. It'll survive those things. Just run whatever you want in that window. You can then detach and later reattach. No problem. The bummer is some of the key bindings conflict with Emacs.
BTW, this isn't a "system D" problem. It's a change to how the shell works. It's been there for years. Stop being systemd haters, get over it already. Man up and learn it. I did and I have over 30 years of working with the old SYS V and BSD. If you don't want to learn it because it's too hard (as if it's too hard), do something else. There's plumbing, electrical, house framing, welding. All of those fields need a lot of people. You'll have to learn stuff there as well, however. Some places require the old Union progression. Journeyman, Master, etc.
One, no one has credibly stated that screen/tmux are left alive. There are people reporting that screen/tmux sessions are killed.
I do.
On a stock Jolla phone, SailfishOS has the same clean-up option activated that the Debian systemd packager has activated in TFA.
If I type:
ssh jolla -t -- su -l nemo -c "'screen'"
My screen session survives without getting killed.
(Note:
- nemo is the main user on a Jolla smartphone.
- su starts this screen session in its own separate session (in a different CGroup, and all the various non-POSIX/Linux-specific seats & namespaces & containers, etc.)
(there's also a systemd-specific way to start a shell in a new sessions, using some "machinectl shell" construction, but su does the job and is more compact)
Or you, know, you could stop complaining on forum, turn the damn option "off" in Debian-Sid like virtually every single other distribution does, and file a ticket on debian's bug tracker to ask the packager to make back the default not to clean-up the session like everyone else is doing.
(and BTW, what are you doing complaining about Debian- Sid ? It's supposed to be unstable and rough edges by design. Things breaking under Sid like this are supposed to be common. Use some LTS distro if you want peace of mind).
Or if you want to go the systemd route, I would encourage you to read a little bit about the various "--user" option, and ".service" (and/or ".timer", etc.) syntax.
That will help you cover most of the "need process in the background" situation that aren't covered by screen's "I need my long-running computation to survive between ssh remote sessions".
(e.g.: for any end-user daemon).
I've managed to convert most of my background tasks this way on the various systemd-powered installation I've been using (openSUSE Leap 42.1, openSUSE Tumbleweed, CentOS 7, and Debian's own Jessie release which doesn't have the "KillUserProcesses" toggle set as mentionned for Sid in TFA).
"Sufficiently advanced satire is indistinguishable from reality." - [Tips: 1DrYakQDKCQ6y52z6QbnkxHXAocMZJE61o ]
Anyone who's ever been disconnected from a server 2 hours into a 3 hour process knows the importance of using screen.
...and would also know not to use Debian Sid on a critical server, BTW.
And even on distro with auto-cleaning-up activated in logind (e.g.: SailfishOS on Jolla), screen DOES work as intended as long as you care to correctly start it in its own seat/session/namespace/container (and all those non-POSIX-y stuff that Linux handles and that systemd manages)
"Sufficiently advanced satire is indistinguishable from reality." - [Tips: 1DrYakQDKCQ6y52z6QbnkxHXAocMZJE61o ]
Actually it stems not that much from systemd itself,
than from Linux being not POSIX, but having lots of extensions over it:
seats, namespaces, cgroups, containers, etc.
Systemd simply tries to manage them (there's no other tool that attempts to do it right now).
And BTW, quite the contrary, this kind of strict compartmentalization actually enables you to have *multiple* users using multiple *seats*.
E.g: having 3 users each running their own desktop environment on the same workstation, as long as the GPU has enough monitor outputs and enough USB keaboards and mice are plugged in.
"Sufficiently advanced satire is indistinguishable from reality." - [Tips: 1DrYakQDKCQ6y52z6QbnkxHXAocMZJE61o ]
Any business running GNU/Linux won't have a problem using Slackware or Gentoo to build a "standard image" to then push to every workstation in the campus. Accompany that with a central "package supplier" (especially for Gentoo) machine, and all workstations can be upgraded (via binary packages, no less!) from a central packaging server that is maintained separately and can have VMs or other local machines used as testbeds before deployment.
No competent business will have trouble using more granular distros, unless they simply can't attract people that know that stuff. And that's not a failure of {Slackware|Gentoo}, but the company.
"Hey, here's a piece of GPL code I want to use in my MIT-licensed software project.
Wait, I need to relicense my project to abide by the licence? Urgh."
this is the highest end unix trolling of the decade of all time
https://bugs.debian.org/cgi-bi...
says "The option has already be[en] reverted in the packaging git."
A Free, fast personal organizer for touch typists: onemodel
Some people are saying that this new behavior is killing screen. Can’t systemd be configured to automatically recognize screen and not kill it?
Gentoo really isn't much better. It's not as bad as Slackware, but Gentoo is still a niche distro, and its whole compilation strategy is wasteful for anyone but hobbyists.
I ran Gentoo for a long time and if you want to upgrade your distro sensibly, at this point recompilation is the only sensible option ;-).
or Gentoo - with OpenRC goodness :)
https://wiki.gentoo.org/wiki/P...
According to Poettering this is just a 'misunderstanding:' "The changed default here is really about defining the lifecycle of unprivileged code by privileged code, and thus about security" Logging out is not meant to invalidate your credentials of running code on a system - its just as arbitrary to make this the default behaviour as it is to automatically kill user processes at 00:00 or after 30 minutes of inactivity - I am sure this would also "improve" security. ...if the user is removed from the system - then, yes kill his processes.. the runaway processes argument is bogus - a runaway process is equally bad whether you are logged in or not...
If any background processes are running, just pop up a dialog on logout and ask if they want them killed. No need to make assumptions.
# make clean sig
FreeBSD is lacking in a few areas on notebooks:
-hardware support lags too far behind;
-wireless is unreliable on Intel, Atheros and nearly non-existent on Broadcom;
-good luck getting a touchscreen working.
I tried to move my home network to a homogeneous FreeBSD environment a few months ago, but had to roll the notebooks back to Linux. My wife got after me about the intermittent wireless, so FreeBSD had to go. I ended up going with Devuan because it's familiar, systemd-free and wireless works a treat.
Is Devuan a thing? I though it is a joke project with a 4.5 GB netinst image (seriously, do they test *anything*?)
Again and again I've heard people like you suggest that Slackware is a replacement for a modern mainstream distro like Debian. Others suggest Gentoo.
Well, the reality is that neither is sufficient.
Slackware is, to put it politely, very primitive. While simplicity is a good thing, Slackware takes it to the point where it becomes a liability.
When using Debian, it's possible to get a full-featured desktop or server set up with very little effort, and this can be done quickly. Thanks to sensible defaults and a practical installer, manual configuration is kept to a minimum.
Frankly, what we need even more than Devuan is a fork and re-structuring of the RedHat ecosystem. Unlike .deb-land where the more dynamic Ubuntu is a downstream of the stabler Debian, the "upstream" of RPM world is the bleeding edge Fedora where this crap began with, not the more-enterprise-stable RHEL.
The unfortunately-named CentOS ("Community ENTerprise OS") is an intended binary-compatible rebuild of RHEL, so it really doesn't have the freedom to change anything at all and remain within its goals (even before it became part of RedHat). What's needed is a sane, more stable fork of Fedora.
It could be done... Start with CentOS 6 as a baseline, and bring this up to date with CentOS/RHEL7 tech (kernel, glibc etc.) using Scientific Linux 7 as a concept for rebuilding. Bring in stability features, while leaving out as a requirement what's generally a poor fit for a server, such as systemd as /sbin/init, NetworkManager, etc. It doesn't mean they're not there, but they're not forced. systemd can still run, it just isn't PID1... It's a service launched via script just like any other service manager (such as xinetd).
From there, build a server-quality distro that's broadly (generationally) compatible with the major release of RHEL, but is free to not do the stupid stuff.
RPM-world needs and deserves a new, server-class RPM-based distribution.
Hire a Linux system administrator, systems engineer,
a bit of FUD here - gentoo is great as is openRC
The main objection point is: Why bother use a systemd-specific mechanism when the problem it's addressing has already a *NIX solution for that, and that had been working will for _years_? Almost all *NIX people will say that's what SIGHUP is for! And what nohup/screen/tmux is designed for of course! Adding an additional, systemd-specific API doesn't tell anything more than what catching SIGHUP is meant to tell. So it's useless effort, and reinventing the wheel.
And also refute a common argument about that "user processes running when user has logged out is a security problem": (1) True misbehaving/malicious software will adapt to this systemd way of keeping alive and continue to be misbehaving, so ultimately you will solve nothing. (2) If what you worry about is bad code of some other programs, then either tell the bad developers to fix them, or, if they are unlikely to fix or that you cannot trust them, use a local **whitelist** for users _and_ admins to decide which programs may be kept alive, and which should die after logout. This is the right way to do the "security problem", not yet-another-systemd-API crap.
I just don't get one thing. Let's look at OS that called Windows. It has two logout options. One to logout completely and kill all user processes and another that you can use remotely to keep your session and everything. Why do we have all this debate?? Linux session is what? Different by nature? Pardon my English.
Again and again I've heard people say that Slackware is too "primitive" to use as a server.
Well, have you tried? I say it's bullshit.
I have used both Redhat and Debian as well as Slackware a lot on servers (and desktops, but that's not what we were discussing) and I have to say the distro with the most sensible defaults is by FAR Slackware. It's also very helpful that it keeps all programs in their default state, i.e. the documentation for each program like Postgres, Apache, dhcpd etc.. can be followed to the letter. Both Redhat and Debian all too often change stuff and move paths around so you have to look for Debian-specific documentation on how to do something.
I can honestly not find a single thing that's been harder to do and manage on a Slackware server compared to Debian and Redhat, and a lot that's easier. The fact that Slackware is a lot more stable then the others is also a huge advantage. You can rely on your scripts and programs to keep working under Slackware, not so much on other distros.
Why do the systemd folks think they need to keep reinventing the wheel?
That's easy: they're creating their own jobs, rather than being told what to do. And I fully understand why a person would want to do that. What I don't understand is why Red Hat and everybody else simply rolls over and takes it.
The sensible arguments just keep getting better :-).
This headline is completely wrong: "Systemd Starts Killing Your Background Processes By Default."
Unless you run a rolling release distro and you blindly update, you're not going to get systemd 230 without knowing it. (You could argue that it's still a problem regardless, but it's no bigger problem that Linux kernel/coreutil releases that have terminal boot errors and what not.) So this panic-inducing clickbait title is preposterous. It's nothing like how Windows 10 forcefully installs on peoples' computers with Windows 7 or 8.1 even if they deny the update.
fuck all your cars up, ride our bus
systemd is a bad idea.
The article is wrong. Systemd didn't change anything. Debian's config for systemd changed a default. Either option is a problem for people. But its not unreasonable to assume that users that want to have long running process know more about their systems and thus how to change them than users who want everything to stop when they logout. The change in default makes sense, and systemd is doing the right thing here.
What's a pain is the disruption caused by transitioning from a non-sensible default to a sensible default.
Your comment is wrong.
Debian didn't *intentionally* change the default. Systemd did. Debian failed to catch/care/notice/revert the change. This happened with Fedora as well (well, rawhide, Fedora's rolling unstable branch).
When you add in the systemd project's stated intent to make it more and more painful to NOT use the systemd defaults across the board (cf. https://lists.freedesktop.org/archives/systemd-devel/2010-September/000391.html), mincing words about distro-level deviations from upstream is not a very compelling response.
Hire a Linux system administrator, systems engineer,
If nobody's mentioned it yet (not reading through 900+ posts), this behaviour was a) easily turned off and b) reverted (i.e. made non-default) after couple of days.
But I expect it'll still be quoted as a reason systemd sucks in 2 years time.