Both Windows and Linux have their respective SIGTERM and SIGKILL equivalents. And both usually try SIGTERM before resorting to SIGKILL. That's what systemd's dreaded "a stop job is running" is. It waits a minute or so for the SIGTERM to be honoured before SIGKILLing the offending process.
I once spent several angry hours researching zombie processes in a quest to kill them by any means necessary. Ended up rebooting, which was a sort of baby-with-the bath-water solution.
Zombie processes still infuriate me. While I'm not a Rust developer, nor do I particularly care about the language, I'm eagerly watching Redox OS, as it looks like the micro kernel OS with the best chance to make to it useful desktop status. A good micro kernel would address so so many of the worst aspects of Linux.
Zombie processes are already dead. They aren't executing, the kernel is just keeping a reference to them so their parent process can check their return code (waitpid).
All processes becomes zombies briefly after they exit, just usually their parents wait on them correctly. If their parents exit without waiting on the child, then the child gets reparented to init, which will wait on it. If the parent stays alive, but doesn't wait on the child, then it will remain zombied until the parent exits and triggers the reparenting.
Its not really Linux's fault if processes don't clean up their children correctly, and I'm 99% sure you can zombie a child on redox given its a POSIX OS.
Zombie processes are hilarious. They are the unkillable package delivery person of the Linux system. They have some data that must be delivered before they can die. Before they are allowed to die.
Sometimes just listening to them is all they want. (Strace or redirect their output anywhere.)
Sometimes, the whole village has to burn. (Reboot)
Performance is the major flaw with microkernels that have prevented the half-dozen or more serious attempts at this to succeed.
Incurring context switching for low-level operations is just too slow.
An alternative might be a safe/provable language for kernel and drivers where the compiler can guarantee properties of kernel modules instead of requiring hardware guarantees, and it ends up in one address space/protection boundary. But then the compiler (and its output) becomes a trusted component.
RedoxOS would likely never become feature complete enough to be a stable, useful and daily-drivable OS. It's currently a hobbyist OS that is mainly used as a testbed for OS programming in Rust.
If the RedoxOs devs could port the Cosmic DE, they'd become one of the best Toy OS and maybe become used on some serious projects . This could give them enough funds to become a viable OS used by megacorps on infrastructures where security is critical and it may lead it to develop into a truly daily drivable OS.
Ok, how change of kernel would fix userspace program not reading return value? And if you just want to use microkernel, then use either HURD or whatever DragonflyBSD uses.
But generally microkernels are not solution to problems most people claim they would solve, especially in post-meltdown era.
nah, you can have micro-kernel features on linux, but you can't have monolithc kernel features on microkernel, there's zero arguments in favor of a micro kernel, except being a novel project
Been a while since I've been on Windows but I distinctly remember some button to kill a task without waiting. Maybe they removed it to make Windows soooo much more user friendly.
The end task doesn't terminate the app, it only sends a message to the window to close itself. The app will then decide what to do on its own. For example, if the app has multiple windows open, it might close the active one, but still continue running with other windows open. Or it might ignore the message completely.
That’s what systemd’s dreaded “a stop job is running” is
The worst part of that is that you can't quickly login to check what it is (so maybe you can prevent it in the future?), or kill it anyway because it's likely to be something stupid and unimportant. And if it actually was important, well... it's gonna be shot in the head in a minute anyway, and there's nothing you can do to prevent it, so what's the point of delaying?
In the best case the offending process actually does shut down cleanly before the time is up. Like, some databases like redis keep written data in memory for fast access before actually writing the data to disc. If you were to kill such a process before all the data is written you'd lose it.
So, admins of servers like these might even opt to increase the timeout, depending on their configuration and disc speed.
Stop jobs are a systemdism and they're nice. I think the desktop environment kills its children on its own during reboot and it might not be as nice. Graphical browsers often complain about being killed after a reboot in GNOME.
AFAIK running firefox in a terminal and pressing ^C (SIGINT) has kind of the same effect as logging out or poweroff in GNOME (SIGTERM, if you're using systemd). This gives the browser (or other processes with crash recovery) enough time to save all its data and exit gracefully for the crash recovery the next time they are run.
BTW you can control systemd and how fast it chooses SIGKILL after sending SIGTERM. I don't know why people complain so much about it. It's really just there such that things on your computer end properly without any sort of data corruption or something bad going on after a reboot or the next time you turn on your computer.
Steam is clunky... Exit -> Oh you want to exit? Let me launch a new window letting you know I'm shutting down and take about 20 seconds while I was sitting here idle before you asked to shutdown.
See you tomorrow where I'll validate your games again. Just in case!
Yup. And you can kill processes in Windows to in the task manager. Or probably with a Powershell command too, but nobody's gonna learn Powershell LOL.
There's nearly always equivalent functions in both Linux and Windows, just in Windows you gotta click around in more bullshit forms and shit to find stuff. Or learn Powershell, but again, LOL. They are both OSes after all, they do similar things. Just one might do them better than the other.
Almost every time I restart my Windows PC from an update, it sits on the "closing apps screen" or "restarting" screen then gives up completely and I have to force it to shut down/restart
And, just about every other time I restart with an update, it closes apps and then just fully shuts down after the update!
"restarting" for 15 minutes. Then crashes. Now I have to reinstall updates and go through it all over again. I hate how crappy the windows update process has become.
Except for the immutable versions I have, Linux almost never needs to reboot after an update. Upgrades, yes, but not standard updates. And even after upgrades, it just works [(except for one of the immutable versions I have)].
I usually close all programs before shutting down / rebooting, anyway (a habit I picked up from Win95 days, where it would crash if programs prevented it from shutting down), so I don't really feel this SIGKILL issues.
As Microsoft adds ads in more places more and more, I consider moving over to Linux but I just have too many files and weird Windows only programs that I use that I can't
I also haven't really found a desktop environment I really like yet, so I'm open to suggestions for dual booting!
Windows' might be complex, but it is NOT graceful. If you have notepad open with unsaved text, then shutdown will never shut down - but nothing on the screen will make this obvious to a non-technical person.
SIGTERM is a graceful request to the application to terminate itself and despite their names kill and killall default to SIGTERM (also useful to send other signals to processes, like START, STOP and NOHUP).
Linux actually also has a graceful shutdown process. It tells apps its shutting down by sending SIGTERM, and its up to each process to flush data asap, do whatever they gotta do, and then shut down.
If they don't listen then linux will indeed pull out the baseball batchainsaw katana and make processes die whether they want to or not.
But for some reason Firefox doesn't do this properly, so it offers to or just outright restores all my pages on startup. I've never been able to make it stop doing that.
The number of times I have had the Windows shutdown process tell me “please close <some windows process that I never opened> before shutting down” is fucking annoying. Wipe your own ass, Windows.
The funniest one is when it tells you this but by the time you get back to close the ones that didn't close they've already closed on their own. Confused Travolta.gif
Every computer should have a hard cutoff power switch, when thrown it cuts all physical electricity.
Off means off.
The current trend of soft power buttons, parasitic loads to service impi, or management engines wol, etc is just bad practice and removes agency from the user.
Who hasn't wanted to turn off a laptop to put it in a bag only for the shutdown to trigger an update that takes 10m whole your running late, so the laptop overheats. Or worse, the laptop turns on while in the bag!
The fact windows has a poor ability to apply updates live or In a a/b fashion is no excuse for soft poweroff buttons. Sure it's nice to flush file system write through caches, but Ive been burned by fake power off far more then incomplete file writes.
At least for desktop computers, you have the power switch on the back of the PSU. Assuming your PSU is actually ATX compliant and not some proprietary or otherwise non-standard bullshit.
That switch is inline with the AC input and will kill power to the device completely.
This is what frustrates me about HP laptops. The biggest issues users see with them could be resolved with a hard reset to clear chip states, but you have to perform a hard reset by powering off, unplugging, and holding power for 30 seconds. A shut down or a restart doesn't fully reset all chips and network/audio issues seem to persist.
This is one of the greatest reasons to get a MacBook. It just sleeps instantly and sleeps seemingly forever (loses about 2% overnight). No need to deal with Window’s BS hibernation mode that takes longer to wake than just powering it off and then on.
Now just to get work to let me get a MacBook as my next hardware instead of another Thinkpad (most of my work is cloud based or in the Office suite).
Meanwhile Windows regularly gets hung up for several minutes on the "shutting down..." screen for no fucking reason. Only happens when I'm in a hurry too.
Haha. Popos gnome doesn't have this. You get a pop up and says 60s count down. Wish I knew what command that is. I usually have hotkey 'poweroff' and that ista kills everything and shuts down lol
The command shutdown defaults to 60s, but doesn't throw the popup. shutdown +60 will give you 60min instead (and +30 is 30min, etc), shutdown -c to cancel, and shutdown --show will show if one is scheduled shutdown -h I believe is the "do it now" option but I always just give it the minute.