Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
systemd ???
View unanswered posts
View posts from last 24 hours

Goto page 1, 2, 3  Next  
Reply to topic    Gentoo Forums Forum Index Gentoo Chat
View previous topic :: View next topic  
Author Message
Sansavarous
n00b
n00b


Joined: 15 Feb 2004
Posts: 22
Location: My computer.

PostPosted: Tue Mar 18, 2014 9:30 pm    Post subject: systemd ??? Reply with quote

Ok I don't think I'm understanding what systemd is trying to accomplish.

I read the following on http://0pointer.de/blog/projects/systemd.html

"So, in summary: the socket-based service activation and the bus-based service activation together enable us to start all daemons in parallel, without any further synchronization."

To be sure I understand what they're saying they want to have daemons start in parallel, start network, disk, webserver et.al... at the same time. This seems like a bad idea to me, you're just asking for a race condition.

This was one of the reasons I threw my win7 disks in the trash, it was trying to connect to a network share before the network was connected.

How is a web server going to present data to someone who connects if the disk is not accessible yet?

As I read more of the article I noticed that it did say making services wait until it's dependencies are met to load, wait a minute I thought systemd was supposed to load things in parallel?

The article also points out that under sysvinit the file systems are loaded and fscked before anything else, OF COURSE. Have you ever had a situation where you get disk corruption? Do you really want that corruption to be spread by a daemon? GIGO

Once I got to the point where I read, "Another thing we can learn from the MacOS boot-up logic is that shell scripts are evil." I choked on my coffee. Shell scripts are designed to glue where there is no glue, and to run and go away not sit and spin all day. Shell scripts are quick automations, band-aids, kludges to get things to run not solutions. It seems that modern programmers have forgotten that.

Me I don't want some systemd sitting around babysitting my processes. The whole point of an OS is to run the software and GET THE HELL OUT OF THE WAY.

If systemd is just trying to make linux systems boot faster, they scream this over and over, Why not fix what we have? What good is adding another layer of complexity to the system and having yet another thing running in the background? I also have to question, how fast does your system boot now? I lived through the bad old days of win95 and ten minute boot times, and half an hour to an hour of cluster quiescence UPHILL, IN THE SNOW, BOTH WAYS!

If your system boots in less then ten minutes you're fine. If you're so desperate that you must have your computer fix NOW, make it so you don't have to reboot. Wait a minute, this begs to question, why reboot? Hmmm. I only shutdown when I'm not going to use my computer for over 4 hours, heat surge ya know. Reboot, lets see at work I reboot if I have to work on a crappy .NET legacy app and need windows. At home I don't just reboot, I startup do what want and when I'm done with the computer I shutdown. Reboot, why? Oh yeah kernel changes for stuff I've not gotten modularized.

I guess the burning question I have is why is systemd trying to fix something that's not broken?

And suddenly I'm having flashbacks to reading The Adolescence of P-1
Back to top
View user's profile Send private message
TomWij
Developer
Developer


Joined: 04 Jul 2012
Posts: 1551

PostPosted: Tue Mar 18, 2014 9:59 pm    Post subject: Re: systemd ??? Reply with quote

Sansavarous wrote:
To be sure I understand what they're saying they want to have daemons start in parallel, start network, disk, webserver et.al... at the same time. This seems like a bad idea to me, you're just asking for a race condition.


Think about this in several levels; on higher levels, the synchronization becomes less necessary due to how the lower levels work (where synchronization is still present).

Sansavarous wrote:
This was one of the reasons I threw my win7 disks in the trash, it was trying to connect to a network share before the network was connected.


This comparison I don't understand; Linux and Windows act the same here afaik, you can test by doing a ping on both of them with the network cable disconnected, do the same with the interfaces disabled.

Sansavarous wrote:
How is a web server going to present data to someone who connects if the disk is not accessible yet?


There's a difference between starting and reading; you can start a web server while not having it read from disk early on in its start-up, this is how it loads anyway because it needs to get to the configuration after having load its libraries and somewhere after that it'll probably start caching things after a caching library or extension or so is loaded.

So, starting it this way is like saying "start doing as much as possible"; now what happens when the web server reads? That thread will block (on file access or so) until it can respond. On my system, for instance, my second notebook hard disk only gets mounted when I actively started working on it (and it then gets mounted as part of running a command that accesses it in one or another way).

Sansavarous wrote:
As I read more of the article I noticed that it did say making services wait until it's dependencies are met to load, wait a minute I thought systemd was supposed to load things in parallel?


There are still targets to coordinate it a bit; otherwise you could have the display manager load before the graphics driver is tarted, which would be a more painful experience (unless you remove those targets and rely on the display manager restarting, to make it start that slight bit earlier; but that would be a bad habit, unless you also disable logging along).

Sansavarous wrote:
Once I got to the point where I read, "Another thing we can learn from the MacOS boot-up logic is that shell scripts are evil." I choked on my coffee. Shell scripts are designed to glue where there is no glue, and to run and go away not sit and spin all day. Shell scripts are quick automations, band-aids, kludges to get things to run not solutions. It seems that modern programmers have forgotten that.


"Glue where there is no glue" means that shell scripts are still possible when you need them; however, it doesn't make them the main usage, but rather uses glue when it's really necessary.

Sansavarous wrote:
Me I don't want some systemd sitting around babysitting my processes. The whole point of an OS is to run the software and GET THE HELL OUT OF THE WAY.


This is my experience with it; it runs and works fine, it doesn't get into the way for me in practice. YMMV.

Sansavarous wrote:
If systemd is just trying to make linux systems boot faster, they scream this over and over, Why not fix what we have?


http://universe2.us/epoch.html does something along those lines and is available in the Portage tree; using this on my Gentoo based Raspberry Pi, it's very nice and simple for embedded systems. It can certainly be used for desktop systems too; though, setting it up could need more effort than with other init systems as you need to have some knowledge about the boot.

Sansavarous wrote:
What good is adding another layer of complexity to the system and having yet another thing running in the background?


Consider to make the question "What bad is it?" and demonstrate it; this can be questioned and discussed, but experience with it will reveal what it really does.

Sansavarous wrote:
I also have to question, how fast does your system boot now? I lived through the bad old days of win95 and ten minute boot times, and half an hour to an hour of cluster quiescence UPHILL, IN THE SNOW, BOTH WAYS!


Up to the point that you'll notice bootchart's png export has no scaling functionality; which happens when each boot phase (kernel, boot, GUI, login) takes just a second, it can be that fast.

Sansavarous wrote:
If your system boots in less then ten minutes you're fine. If you're so desperate that you must have your computer fix NOW, make it so you don't have to reboot. Wait a minute, this begs to question, why reboot? Hmmm.


Reboots here are needed often because I'm on a laptop without a battery and often move places (upstairs, downstairs, university, ...); besides that, I maintain kernels so need to do a kexec reboot to test them on native hardware, I maintain epoch which is an init system and needs a reboot, I bisect kernels, work on making Nouveau reclocking support my graphic card more stable, ... At this point the output of commands like `dmesg -d | sort -nk4` (and init system specific tricks) can be helpful for quickly identifying what takes long in a boot; other than that, granted, trying to get the boot time really low can also be fun to learn a lot of the internals of the boot.

Sansavarous wrote:
I only shutdown when I'm not going to use my computer for over 4 hours, heat surge ya know. Reboot, lets see at work I reboot if I have to work on a crappy .NET legacy app and need windows. At home I don't just reboot, I startup do what want and when I'm done with the computer I shutdown. Reboot, why? Oh yeah kernel changes for stuff I've not gotten modularized.

I guess the burning question I have is why is systemd trying to fix something that's not broken?

And suddenly I'm having flashbacks to reading The Adolescence of P-1


What works for one is broken for another; or as said, YMMV.


Last edited by TomWij on Tue Mar 18, 2014 10:05 pm; edited 1 time in total
Back to top
View user's profile Send private message
mas-
n00b
n00b


Joined: 07 Jun 2011
Posts: 34

PostPosted: Tue Mar 18, 2014 10:05 pm    Post subject: Reply with quote

Nice rant.

But

Quote:
If your system boots in less then ten minutes you're fine.


I would be really pissed if my systems would need minutes to boot. That might be a reason to switch.
Currently I have two gentoo systems. The mini-server is very weak CPU wise and needs about 30 seconds to boot. The desktop has a powerful CPU, ssd harddrive and needs 3-4 seconds till the kde prompt from BIOS. Both with standard openrc, the desktop with parallel mode enabled.

Hence I also see no need to switch to systemd. On the other hand I have a nettop with archlinux. Also not a very fast CPU. And archlinux comes with systemd. Works, is a bit faster than it would be with openrc, not drastically though. The systemd on arch is not a big problem so far. A bit clumsy to administer, but it works. No incentive for me to change anything on my gentoo systems, also no reason to start demonizing it.
Back to top
View user's profile Send private message
TomWij
Developer
Developer


Joined: 04 Jul 2012
Posts: 1551

PostPosted: Tue Mar 18, 2014 10:08 pm    Post subject: Reply with quote

In terms of boot time, the gap becomes smaller due to better hardware; though, we can avoid that factor to discuss when comparing init systems, I personally benefit from it (see my earlier post in this thread) but I think in general it's not important for a lot of people unless it takes really long.
Back to top
View user's profile Send private message
Sansavarous
n00b
n00b


Joined: 15 Feb 2004
Posts: 22
Location: My computer.

PostPosted: Tue Mar 18, 2014 10:29 pm    Post subject: Reply with quote

@TomWij No I'm not going to make a quote mess post I'm going to do it dino style.

Windows 7 was trying to connect to the network share before the network was started....

If I translate that into *nix, the OS was trying to mount a network drive before obtaining an IP address.

I also notice on many of your replies and quotes you're saying the same thing I am.

"There are still targets to coordinate it a bit; otherwise you could have the display manager load before the graphics driver is tarted, which would be a more painful experience (unless you remove those targets and rely on the display manager restarting, to make it start that slight bit earlier; but that would be a bad habit, unless you also disable logging along). "

""Glue where there is no glue" means that shell scripts are still possible when you need them; however, it doesn't make them the main usage, but rather uses glue when it's really necessary."

Uh.. yeah I said that in my post. Why are you restating it?

Gee, "What bad is it." well it's using up system resources, it's more code on my system that could have dangerous bugs in it, it's yet another package I have to maintain, it's another link in the chain that can break, it's young software, it's not needed, what does it fix?

"Up to the point that you'll notice bootchart's png export has no scaling functionality; which happens when each boot phase (kernel, boot, GUI, login) takes just a second, it can be that fast. "

WTH does that have to do with what I'm saying?

"Reboots here are needed often because I'm on a laptop without a battery" it's a poor engineer who blames his tools, FIX IT.

"besides that, I maintain kernels so need to do a kexec reboot to test them on native hardware"

FINALLY you get to the point.

Yes I can completely understand why you might want to boot faster; however, if you're really doing that then you probably shouldn't be loading a ton of services anyway.

I still don't understand why systemd is useful or good to the other 90 percent out there that don't do kernel dev.

What is it that systemd is fixing? Why is systemd better then what we have?
Back to top
View user's profile Send private message
TomWij
Developer
Developer


Joined: 04 Jul 2012
Posts: 1551

PostPosted: Tue Mar 18, 2014 10:40 pm    Post subject: Reply with quote

Sansavarous wrote:
If I translate that into *nix, the OS was trying to mount a network drive before obtaining an IP address.


That's possible to do; actually, Patrick taking OpenRC boot time to the extreme (scroll down a bit) breaks network and could thus have such mount fail, this is similarly reproducible on systemd.

Sansavarous wrote:
I also notice on many of your replies and quotes you're saying the same thing I am.

"There are still targets to coordinate it a bit; otherwise you could have the display manager load before the graphics driver is tarted, which would be a more painful experience (unless you remove those targets and rely on the display manager restarting, to make it start that slight bit earlier; but that would be a bad habit, unless you also disable logging along). "

""Glue where there is no glue" means that shell scripts are still possible when you need them; however, it doesn't make them the main usage, but rather uses glue when it's really necessary."

Uh.. yeah I said that in my post. Why are you restating it?


See the context, which you have left out, for that; it shows how systemd has targets to coordinate it, as well as why it avoids shell scripts in general but still supports them.

Sansavarous wrote:
Gee, "What bad is it." well it's using up system resources, it's more code on my system that could have dangerous bugs in it, it's yet another package I have to maintain, it's another link in the chain that can break, it's young software, it's not needed, what does it fix?


Nothing; it's a replacement, iotw an alternative, it doesn't have to fix to be necessary. It can be necessary out of preference.

Sansavarous wrote:
"Up to the point that you'll notice bootchart's png export has no scaling functionality; which happens when each boot phase (kernel, boot, GUI, login) takes just a second, it can be that fast. "

WTH does that have to do with what I'm saying?


That was in answer to the amount of time; iotw, its an example of it being that short breaks software that should instead help to demonstrate how short it is.

Sansavarous wrote:
"Reboots here are needed often because I'm on a laptop without a battery" it's a poor engineer who blames his tools, FIX IT.

"besides that, I maintain kernels so need to do a kexec reboot to test them on native hardware"

FINALLY you get to the point.

Yes I can completely understand why you might want to boot faster; however, if you're really doing that then you probably shouldn't be loading a ton of services anyway.


That's indeed what I'm doing; running systemd with barely any services, similar efforts can be achieved on OpenRC and you even get them by default with things like Epoch.

Sansavarous wrote:
I still don't understand why systemd is useful or good to the other 90 percent out there that don't do kernel dev.

What is it that systemd is fixing? Why is systemd better then what we have?


It's an alternative, afaik; there are (dis)advantages you might find on the internet, however, to each their own experience, there's no one size fits all init system / service manager.
Back to top
View user's profile Send private message
Sansavarous
n00b
n00b


Joined: 15 Feb 2004
Posts: 22
Location: My computer.

PostPosted: Tue Mar 18, 2014 10:44 pm    Post subject: Reply with quote

Ok cool thanks TomWij I think I understand better now and I believe we're in agreement. :D

Now if I can just figure out why people are trying to get it default in Gentoo.
Back to top
View user's profile Send private message
genstorm
Advocate
Advocate


Joined: 05 Apr 2007
Posts: 2477
Location: Austria

PostPosted: Wed Mar 19, 2014 12:07 am    Post subject: Reply with quote

Sansavarous wrote:
Now if I can just figure out why people are trying to get it default in Gentoo.

Who does?
_________________
backend.cpp:92:2: warning: #warning TODO - this error message is about as useful as a cooling unit in the arctic
Back to top
View user's profile Send private message
666threesixes666
Veteran
Veteran


Joined: 31 May 2011
Posts: 1242
Location: 42.68n 85.41w

PostPosted: Wed Mar 19, 2014 4:38 am    Post subject: Reply with quote

default? uhhh its a choice, i personally believe all init system choices should be available in stage3, rather than having to rip a "default" init out, a system needs to be crafted to deal with the subtle differences between init system startup scripts. ie use flags for which init system(s) you have installed, pull in installed package init scripts. my laptop has systemd & openrc concurrently installed and selectable upon boot via lilo. kernel sources run lilo upon make install, so id say that's a good candidate for distro preferred, yet not forced boot loader. who's the clown that wanted grub to be default is my question.

ill go so far to say, we need to squash all these retard carnival threads, and simply REMOVE init systems from stage3 and force users to emerge choice at that point preferring traditional openrc.
_________________
cat /etc/*-release
Funtoo Linux - baselayout 2.2.0
consider this warning no. 1
https://wiki.gentoo.org/index.php?title=Special:Contributions/666threesixes666&offset=&limit=500&target=666threesixes666
Back to top
View user's profile Send private message
Ant P.
Advocate
Advocate


Joined: 18 Apr 2009
Posts: 2518
Location: UK

PostPosted: Thu Mar 20, 2014 1:27 am    Post subject: Re: systemd ??? Reply with quote

Sansavarous wrote:
Me I don't want some systemd sitting around babysitting my processes. The whole point of an OS is to run the software and GET THE HELL OUT OF THE WAY.

I agree with the second part, but sysvinit does exactly the same babysitting and restarting of processes, and it's a major feature of just about every other init-replacement like daemontools/runit.
Back to top
View user's profile Send private message
krinn
Advocate
Advocate


Joined: 02 May 2003
Posts: 4402

PostPosted: Thu Mar 20, 2014 2:04 am    Post subject: Reply with quote

666threesixes666 wrote:
kernel sources run lilo upon make install, so id say that's a good candidate for distro preferred, yet not forced boot loader. who's the clown that wanted grub to be default is my question.

I don't know, but he must be a clown that knows grub doesn't need to be rerun to use a new kernel, something that explain why make install doesn't do anything as it's not need or that grub doesn't even need hardcoded kernel and provide a minimal shell so user can browser /boot and available kernels list and just edit the boot line to switch to some valid kernel without need to grab a livecd just because he have made a mistake when typing kernel name.
Looks like clown race is far from extinction...
Back to top
View user's profile Send private message
Sansavarous
n00b
n00b


Joined: 15 Feb 2004
Posts: 22
Location: My computer.

PostPosted: Thu Mar 20, 2014 3:43 am    Post subject: Reply with quote

Now now krinn I'm trying to be nice.

Once was a time I lived under a bridge and had kevlar reinforced asbesdos gel pants! :lol: :wink:
Back to top
View user's profile Send private message
Suicidal
l33t
l33t


Joined: 30 Jul 2003
Posts: 940
Location: /dev/null

PostPosted: Thu Mar 20, 2014 4:16 am    Post subject: Re: systemd ??? Reply with quote

Sansavarous wrote:
Another thing we can learn from the MacOS boot-up logic is that shell scripts are evil.


Depends on the skill of the person writing the shell script, I have seen and written shell/batch/powershell scripts that were more logical and efficient than some compiled software written by so-called professional developers.
_________________
Who controls the past now, controls the future
Who controls the present now, controls the past.
Back to top
View user's profile Send private message
mv
Advocate
Advocate


Joined: 20 Apr 2005
Posts: 4313

PostPosted: Thu Mar 20, 2014 12:41 pm    Post subject: Re: systemd ??? Reply with quote

Ant P. wrote:
I agree with the second part, but sysvinit does exactly the same babysitting and restarting of processes and it's a major feature of just about every other init-replacement like daemontools/runit.

You are ignoring the main difference here: daemontools and sysvinit are separate things.
Traditional init-systems like sysvinit do it exectly for one process, namely PID1. Which is what this PID1 is for and why it is so crucial that this process is as simple as possible, because it is essential for the stability of the whole system. systemd, on the other hand, handles here all sort of processes: From system-critical (of course) up to just "user-convenience" processes which only do some eye-candy in a running X session. In particular, any problem with the process-handling (even of the mere "convenience" processes) can make the wole system stand still.
Back to top
View user's profile Send private message
krinn
Advocate
Advocate


Joined: 02 May 2003
Posts: 4402

PostPosted: Thu Mar 20, 2014 2:15 pm    Post subject: Re: systemd ??? Reply with quote

mv wrote:
You are ignoring the main difference here: daemontools and sysvinit are separate things.
Traditional init-systems like sysvinit do it exectly for one process, namely PID1.

Well, it's hard to believe one could made a system that will froze the computer just because you get a bug in multi-seat support.
But if you consider the POV that "only desktop" count, and don't care about uptime and stability but only about booting fast.
You end-up with systemd concept, where if the GUI is dead, nobody care as the system is considered dead too : you cannot live without a GUI, once GUI is dead, you should reboot.

You just need to add some kind of blue screen and you'll be close to systemd ultimate goal...
Back to top
View user's profile Send private message
Ant P.
Advocate
Advocate


Joined: 18 Apr 2009
Posts: 2518
Location: UK

PostPosted: Sat Mar 29, 2014 4:29 pm    Post subject: Reply with quote

krinn wrote:
666threesixes666 wrote:
kernel sources run lilo upon make install, so id say that's a good candidate for distro preferred, yet not forced boot loader. who's the clown that wanted grub to be default is my question.

I don't know, but he must be a clown that knows grub doesn't need to be rerun to use a new kernel, something that explain why make install doesn't do anything as it's not need or that grub doesn't even need hardcoded kernel and provide a minimal shell so user can browser /boot and available kernels list and just edit the boot line to switch to some valid kernel without need to grab a livecd just because he have made a mistake when typing kernel name.
Looks like clown race is far from extinction...

$(make install) doesn't do anything in that case only because grub doesn't bother to install anything into the standard /etc/kernel.d/ location the makefile looks in — Debian-based systems have their own distro-specific hackery to auto-manually run update-grub on every kernel package update. Of course when that breaks it's not immediately obvious, you just end up rebooting into an old kernel... until you do a cleanup of old kernels one day and grub stops booting.

And unless you're smart enough to figure out the kernel makefile manages symlinks in /boot/ for you (which isn't made obvious in ANY documentation) there's always extra work involved.
Back to top
View user's profile Send private message
steveL
Advocate
Advocate


Joined: 13 Sep 2006
Posts: 2946
Location: The Peanut Gallery

PostPosted: Sat Mar 29, 2014 6:37 pm    Post subject: Reply with quote

"necessary out of preference." LMAO that's brilliant. So the only reason to use it is because we want to.. Circular reasoning ftl.
Back to top
View user's profile Send private message
krinn
Advocate
Advocate


Joined: 02 May 2003
Posts: 4402

PostPosted: Sat Mar 29, 2014 7:19 pm    Post subject: Reply with quote

Ant P. wrote:
krinn wrote:
...

$(make install) doesn't do anything in that case only because grub doesn't bother to install anything into the standard /etc/kernel.d/ location the makefile looks in — Debian-based systems have their own distro-specific hackery to auto-manually run update-grub on every kernel package update. Of course when that breaks it's not immediately obvious, you just end up rebooting into an old kernel... until you do a cleanup of old kernels one day and grub stops booting.

And unless you're smart enough to figure out the kernel makefile manages symlinks in /boot/ for you (which isn't made obvious in ANY documentation) there's always extra work involved.

Just having kernel /vmlinuz ... as grub entry, and when you copy over a new kernel as vmlinuz, reboot. bingo! grub boot it.
After that you can say if someone remove vmlinuz you're dead...
But even if you copy the kernel as vmunix once grub show its prompt, you can just edit the line and change it to boot vmunix. And again : bingo!
Couple that with make install handling symlink for you, and with a 2 menus entry you cover newest kernel and previous one.
i don't why debian run grub, maybe debian add some trick to add the latest kernel as a new entry with its number shown, but that something for grub.conf.
There's just 0 need to run grub, you only need to run grub if you update grub itself.
Back to top
View user's profile Send private message
zeek
Guru
Guru


Joined: 16 Nov 2002
Posts: 478
Location: Bantayan Island

PostPosted: Wed Apr 02, 2014 5:59 am    Post subject: Re: systemd ??? Reply with quote

Sansavarous wrote:
Ok I don't think I'm understanding what systemd is trying to accomplish.


From the conspiracy files:

systemd is trying to take over Linux from within by replacing key components and breaking backward compatibility such that only the systemd "suite" works (ie see udev). The endgame is the operating system will no longer be called Linux (or Gnu/Linux) but systemd.

systemd is a wrapper around the kernel. The endgame is the kernel will be completely abstracted and any adjustments you might want to make (ie tcp buffers) will be done via systemd apis.

systemd is Redhatization of Linux. Linux distros have traditionally used different components to make up their version of "Linux", and that combination of components is what makes distros distinct (ie init system, config files, var layout). These components are being broken forcing replacement with the systemd "suite". What defines a distro if they all use the same kernel, init system, filesystem layout and config syntax?
Back to top
View user's profile Send private message
depontius
Advocate
Advocate


Joined: 05 May 2004
Posts: 2652

PostPosted: Wed Apr 02, 2014 12:08 pm    Post subject: Re: systemd ??? Reply with quote

mv wrote:
Ant P. wrote:
I agree with the second part, but sysvinit does exactly the same babysitting and restarting of processes and it's a major feature of just about every other init-replacement like daemontools/runit.

You are ignoring the main difference here: daemontools and sysvinit are separate things.
Traditional init-systems like sysvinit do it exectly for one process, namely PID1. Which is what this PID1 is for and why it is so crucial that this process is as simple as possible, because it is essential for the stability of the whole system. systemd, on the other hand, handles here all sort of processes: From system-critical (of course) up to just "user-convenience" processes which only do some eye-candy in a running X session. In particular, any problem with the process-handling (even of the mere "convenience" processes) can make the wole system stand still.


Is this really true? It would be a piece-o-cake to change this into to one minimal PID1 process, then a second process to do the rest. The PID1 process would monitor the second process, and kick/restart it as necessary. If I (of no credentials and little brain) can think of that in a few seconds, surely gurus can not only think of it, but cover the holes I missed in only a few seconds. This isn't rocket surgery.
_________________
.sigs waste space and bandwidth
Back to top
View user's profile Send private message
Anon-E-moose
Advocate
Advocate


Joined: 23 May 2008
Posts: 2475
Location: Dallas area

PostPosted: Wed Apr 02, 2014 12:24 pm    Post subject: Re: systemd ??? Reply with quote

depontius wrote:
mv wrote:
Ant P. wrote:
I agree with the second part, but sysvinit does exactly the same babysitting and restarting of processes and it's a major feature of just about every other init-replacement like daemontools/runit.

You are ignoring the main difference here: daemontools and sysvinit are separate things.
Traditional init-systems like sysvinit do it exectly for one process, namely PID1. Which is what this PID1 is for and why it is so crucial that this process is as simple as possible, because it is essential for the stability of the whole system. systemd, on the other hand, handles here all sort of processes: From system-critical (of course) up to just "user-convenience" processes which only do some eye-candy in a running X session. In particular, any problem with the process-handling (even of the mere "convenience" processes) can make the wole system stand still.


Is this really true? It would be a piece-o-cake to change this into to one minimal PID1 process, then a second process to do the rest.


Yes, it would be easy to do that, and with a sane design for sysd then it would have been implemented that way.
I think that it's not being implemented that way because they want everyone to take it all.
If it were split then the other things in "part 2" could be replaced and just use the init part.
They do not want that.

It's all about controlling everything on the system, not about stability or a better system or init, per se.

Quote:
One Ring to rule them all, One Ring to find them,
One Ring to bring them all and in the darkness bind them

Too true in this case
_________________
Asus m5a99fx, FX 8320 - amd64-multilib, 3.15.9-zen, glibc-2.17, gcc-4.7.3-r1, eudev
xorg-server-1.16, openbox w/lxpanel, nouveau, oss4(2010)
Back to top
View user's profile Send private message
mv
Advocate
Advocate


Joined: 20 Apr 2005
Posts: 4313

PostPosted: Wed Apr 02, 2014 6:12 pm    Post subject: Re: systemd ??? Reply with quote

depontius wrote:
Is this really true? It would be a piece-o-cake to change this into to one minimal PID1 process, then a second process to do the rest.

It is not that easy, since PID1 is special. You might want to look at this article and some follow-ups (google will certainly find more of this type), and you could also read what Lennart has written about putting everything into PID1 in his blog (of course all these mixtures of truth, half-truth, and FUD require you to use your brain and form your own opinion).
Independent of technial facts, as Anon-E-moose has written, it is obviously not any priority of systemd to provide a stable system - otherwise this whole nonsense of parallelism during booting would have been avoided, to start with.
Back to top
View user's profile Send private message
Anon-E-moose
Advocate
Advocate


Joined: 23 May 2008
Posts: 2475
Location: Dallas area

PostPosted: Wed Apr 02, 2014 6:33 pm    Post subject: Re: systemd ??? Reply with quote

mv wrote:
and some follow-ups


Interesting article, though a lot of what I read is his view without facts, ie an opinion.
To whit "eudev developers have already proved several times that they do not understand the reasons behind the changes that were made in udev"

I would think that anyone that makes a statement such as this would have at least one example of said "not understanding",
but we (the reader) are supposed to assume that he knows what he's talking about simply because he wrote it.
I do not make those kinds of assumptions.

Quote:
We came from a status where every single distribution had a different init system to the current situation with a single one fitting almost everyone needs. This is the best example of systemd flexibility.

Really I only know of two in widespread use not counting systemd, that being sysvinit and bsd init. Hardly a different init for each distro.

The whole article reads more like a systemd apologists article than anything else.

Again I don't care what people use, sysvinit, bsd init, systemd, daemontools but articles like this are utter cr*p IMO.

Edit to add: This is not to say that the original ewonfix article was neutral, but it did bring up some points that
should be looked at, not glossed over with the mantra "systemd good, everything else bad".

Edit to add 2: What I wrote has nothing to do with you, mv. But about the article itself, just to clarify.
_________________
Asus m5a99fx, FX 8320 - amd64-multilib, 3.15.9-zen, glibc-2.17, gcc-4.7.3-r1, eudev
xorg-server-1.16, openbox w/lxpanel, nouveau, oss4(2010)
Back to top
View user's profile Send private message
depontius
Advocate
Advocate


Joined: 05 May 2004
Posts: 2652

PostPosted: Wed Apr 02, 2014 6:45 pm    Post subject: Re: systemd ??? Reply with quote

mv wrote:
depontius wrote:
Is this really true? It would be a piece-o-cake to change this into to one minimal PID1 process, then a second process to do the rest.

It is not that easy, since PID1 is special. You might want to look at this article and some follow-ups (google will certainly find more of this type), and you could also read what Lennart has written about putting everything into PID1 in his blog (of course all these mixtures of truth, half-truth, and FUD require you to use your brain and form your own opinion).
Independent of technial facts, as Anon-E-moose has written, it is obviously not any priority of systemd to provide a stable system - otherwise this whole nonsense of parallelism during booting would have been avoided, to start with.


Please pardon my ignorance. I've heard before that PID1 is special. The one reason I knew of was that it was the only process that could elevate capabilities once they'e been dropped. Now I see that PID1 is the "parent of last resort", which now that I think of it, is obvious from any time I do a "ps" showing misbehaved processes. Finally, PID1 can crash the box when it crashes - equally logical.

Is there anything else special about PID1?

Which leads to the next question... Can PID1 give parenthood of a process to another process? In other words, let's pretend for a moment that PID1 is the fundamental init process. It starts PID2, which is what starts and monitors the daemons and services. It might also start PID3, which takes care of wayward processes - that is assuming PID1 could give ownership of those processes to PID3.

I'm trying to figure out "how special" PID1 is, because at the moment just because it's parent-of-last-resort doesn't mean to me that you have to have it do everything. Since it's a potential box-crasher, and simply because it is special, I'd think that you'd want it to be as small as possible.

Next ignorant question... How much does SysVInit do in PID1, and how much does it delegate to another PID?
_________________
.sigs waste space and bandwidth
Back to top
View user's profile Send private message
khayyam
Advocate
Advocate


Joined: 07 Jun 2012
Posts: 2248

PostPosted: Wed Apr 02, 2014 7:21 pm    Post subject: Re: systemd ??? Reply with quote

depontius wrote:
Next ignorant question... How much does SysVInit do in PID1, and how much does it delegate to another PID?

depontius ... funny, well, sysvinit runs whatever is in /etc/inittab, in openrc's case it run's '/sbin/rc sysinit' and '/sbin/rc boot' after that it'll spawn getty and whatever else is defined. So, much of the initialisation is delegated to /sbin/rc (openrc).

You might find the s6 on process 1 text of some interest.

best ... khay
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Gentoo Chat All times are GMT
Goto page 1, 2, 3  Next
Page 1 of 3

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum