|
|
Subscribe / Log in / New account

Systemd vs. Docker

Systemd vs. Docker

Posted Feb 25, 2016 19:38 UTC (Thu) by shykes (guest, #107289)
In reply to: Systemd vs. Docker by fandingo
Parent article: Systemd vs. Docker

First, a general comment: I think I've used a respectful tone and backed my arguments with tangible evidence. I wish you could return the favor.

> > What design principle does Docker break by being a daemon and using a client-server architecture?
> It breaks the UNIX principle that *something* needs to reap unowned children and send SIGCHLD to living parents. Due to the way process hierarchies work and Docker's running the app/entrypoint as PID 1 in the namespace, it's broken, unless that app/entrypoint brings its own reaper functionality, which is outside the purview of applications.

This is completely unrelated to client-server architecture, so you're not answering my question, but I'll address your comment anyway. Requiring that the image provide the pid1 command was a conscious tradeoff.

On the one hand, docker could bundle its own lightweight init to reap orphans as you describe. That would work perfectly for 90% of applications because, as you point out, app developers are typically not concerned with this functionality at all. But this would make life very, very difficult for the remaining 10% which want to bundle their own init process in the image. At the top of that list, of course, is the systemd community which is adamant that the only good way to run any container is with systemd inside (see the article above). Although I personally disagree with that opinion, the whole point of Docker was to allow running anything inside a container, including a custom init.

So the other option was to run the image-specified command as pid1. This solves the problem of bringing your own custom init (although as we later found out, it takes a LOT more to make systemd happy inside a container...). It does introduce a few issues for the 90% of applications which don't require a custom init: first, an application which forks huge numbers of short-lived processes may eventually cause trouble on the system by leaving too may unreaped orphans. second, most applications only handle a minimal set of signals, so you can't communicate with them with the full spectrum of signals typically handled by an init process. The most typical example of this is that containers running a shell script as an entrypoint can only be terminated with SIGKILL, which means that 'docker stop' will hang for a few seconds of grace period. In practice this has proven to be a very minor issue: either users aren't affected at all, or they care enough and simply add an init process to their images, which solves the problem.

We could change the behavior now to insert a lightweight pid1 by default, and allow a custom field to request a custom pid1. But that would break many existing users who rely on the current behavior. Keep in mind that Docker was adopted incredibly quickly, so interface stability became an issue before we had much time to work out these issues.

I hope this helps understand our technical choices better.

> Really, really stupid oversight by Docker, although typical of their mindset of only contemplating the simple and easy.

A strong choice of words. If you have evidence to back your claim that we "only contemplate the simple and easy", feel free to share it, it would give me an opportunity to rebuke. As it stands there is really nothing more I can answer.

> I think that has far more to do with RH actually understanding operating systems and Docker only caring about its niche. Docker plays fast and loose with everything, and it's no wonder that there's a lot of friction when people who have well-designed systems try to work with something crafted from soda crackers and spaghetti.

Again, a lot of strong opinions, but no evidence to back it up.

> > Since the business of Red Hat is based on end-to-end platform lock-in, most of their patches focus on breaking that portability in some way. Invariably those patches get refused with clear and respectful feedback. Invariably the feedback is ignored and a similar patch re-opened the next day. It's a weird war of attrition, and I can't blame Jess for being tired of it.

> Wow, just wow. It's difficult to take anyone in the Docker project seriously when they spout nonsense like this

I suppose what you meant to say was "I disagree"? Anyway, here is an article which describes the strategy in more detail https://gigaom.com/2014/05/13/is-red-hat-the-new-oracle/

Selected quote: "Red Hat — which makes its money selling support and maintenance for its open-source products — [will] refuse to support of users of Red Hat Enterprise Linux who also run non-Red Hat versions of OpenStack. [...] that could ding OpenStack’s promise of no-vendor-lock-in."

> although I suppose the quality of their product already says plenty.

More strong opinions without evidence to back it up.

> It's Docker that tries to lock people in and goes out of its way not to cooperate with other tools and projects.

I'm not sure you understand what "lock-in" means... Do you have any evidence whatsoever that Docker - an open-source tool whose primary feature is portability and independence of the operating system and hardware - is contributing to lock-in?

Same question on going out of our way not to cooperate. What is your evidence? I wish you at least made the effort to articulate a basic argument? Otherwise it's very difficult to have a constructive conversation.

>>> According to him, Docker is working on "containerd", its new alternative to systemd, which will take over the functions of the init system.

>> This is plain wrong.

> Nope, it's just your reading comprehension. "Functions" in this sense doesn't mean all that the init system can do. Instead, it means the limited functionality that it's being used in containers.

The same article says "they dream of being systemd". In that context I think my interpretation is reasonable.


to post comments

Systemd vs. Docker

Posted Feb 25, 2016 20:06 UTC (Thu) by roblucid (guest, #48964) [Link]

I don't have any stake in these issues, but reading through the PR's I do have the impression that Dan was being turned down for non-technical reasons.

Suggestions, that software inside containers ought to be modified for the environment after initially saying they shouldn't be able to detect that they're running under Docker, seems especially unfortunate.

I don't get the problem with bundling, you can offer source for a minimal init to copy into containers or have user deploy another (or none). Presumably the customers can actually choose what they run in the containters, right? So why not on the environment setup?

Similarly things like logging, seem like a basic requirement, it needs solving and if you choose to deploy on modern Linux, systemd needs supporting. Saying a flag like "--init==systemd" is compromising the product is ludicrous.

Remember, Dan's start point is stuff deployable for users, and that things like systemctl DO get used. To reinvent another wheel, will be an act of value subtraction, for Docker & the general Linux community. There's enough splintered ways of doing things already.

As it stands, as a sysadmin, we can use a system which simply runs unmodified application services, or ONE market leader that requires a load of special patches and support plus doesn't try to integrate into the system; I KNOW which one I'd choose to try out first.

Systemd vs. Docker

Posted Feb 25, 2016 21:33 UTC (Thu) by fandingo (guest, #67019) [Link] (2 responses)

> First, a general comment: I think I've used a respectful tone and backed my arguments with tangible evidence. I wish you could return the favor.

> At the top of that list, of course, is the systemd community which is adamant that the only good way to run any container is with systemd inside (see the article above).

WOW! You guys are unbelievable. Everything you say is filled with insinuations and disapproving value judgments. You're not casting aspersions; you're hurling them.

> On the one hand, docker could bundle its own lightweight init to reap orphans as you describe.

Why this wasn't considered and completed years ago is beyond me. Again, Docker is interested in the big, shiny, and invariably simple things to implement. When the going gets tough Docker tends to offer nothing, and even worse, rebukes people who are trying to improve things.

> So the other option was to run the image-specified command as pid1. [...]

I pretty much entirely disagree with this entire assessment. You act like making a change to support some sort of init system flag couldn't be accompanied by a few other changes to work around the difficulties. For instance, the kill behavior can be changed and made more cooperative when init flags are in use. But, no, since one change doesn't solve all the problems and create world peace, it's unreasonable.

> A strong choice of words. If you have evidence to back your claim that we "only contemplate the simple and easy", feel free to share it, it would give me an opportunity to rebuke. As it stands there is really nothing more I can answer.

Not implementing reaper functionality. Next question.

> Selected quote: "Red Hat — which makes its money selling support and maintenance for its open-source products — [will] refuse to support of users of Red Hat Enterprise Linux who also run non-Red Hat versions of OpenStack. [...] that could ding OpenStack’s promise of no-vendor-lock-in."

Will Docker Inc support my customized version of Docker under the standard support agreement. This is a silly point. It also ignores how RH's OpenStack is the most upstream friendly.

> I'm not sure you understand what "lock-in" means... Do you have any evidence whatsoever that Docker - an open-source tool whose primary feature is portability and independence of the operating system and hardware - is contributing to lock-in?

I'd say the same to you about Red Hat. Most open source friendly company in the world. For someone constantly complaining about lack of evidence and links, this shows how worthless grabbing the first match off Google is. This article says nothing.

>The same article says "they dream of being systemd". In that context I think my interpretation is reasonable.

What does that have to do with anything?

Systemd vs. Docker

Posted Feb 26, 2016 23:12 UTC (Fri) by flussence (guest, #85566) [Link] (1 responses)

> WOW! You guys are unbelievable. Everything you say is filled with insinuations and disapproving value judgments. You're not casting aspersions; you're hurling them.

"Wow" indeed! If he's that bad, what position does that leave *you* in with your outright attacks on his person?

Oh wait, I think I know: *plonk*

Systemd vs. Docker

Posted Mar 16, 2016 13:56 UTC (Wed) by nye (subscriber, #51576) [Link]

>"Wow" indeed! If he's that bad, what position does that leave *you* in with your outright attacks on his person?
>Oh wait, I think I know: *plonk*

Wait, what? I think you might have got the two people in this discussion mixed up?

Systemd vs. Docker

Posted Feb 26, 2016 0:57 UTC (Fri) by rahvin (guest, #16953) [Link] (5 responses)

> I suppose what you meant to say was "I disagree"? Anyway, here is an article which describes the strategy in more detail https://gigaom.com/2014/05/13/is-red-hat-the-new-oracle/ Selected quote: "Red Hat — which makes its money selling support and maintenance for its open-source products — [will] refuse to support of users of Red Hat Enterprise Linux who also run non-Red Hat versions of OpenStack. [...] that could ding OpenStack’s promise of no-vendor-lock-in."

Seriously? A speculative news article analysis of a wall street news article about Redhat support.(especially in the new era where these type of attack articles can be purchased) That's your evidence?

I personally don't know very many companies that provide support for software they didn't supply. Why on earth would Redhat supply support for Openstack products that someone downloaded from some unknown source? They couldn't even begin to troubleshoot the issue because they couldn't even duplicate the install conditions and have no idea of the compilation options and the hundred other variables that could be modified or even code patches that could be applied. I haven't used Redhat support in a long time but I don't think they offer support on random software they didn't provide. It is not at all unreasonable that Redhat would require that you use the packages they supply to get support on that software. After all, Redhat doesn't offer support for Windows or Oracle either, you going to ding them for that too?

Systemd vs. Docker

Posted Feb 29, 2016 22:40 UTC (Mon) by shykes (guest, #107289) [Link] (4 responses)

The article isn't about refusing to support another company's Openstack distribution (which I agree is perfectly reasonable). It's about *refusing to support their own operating system* if a particular competing application is installed. That is not at all standard, and meets every reasonable definition of "lock-in".

There is no speculation involved: the article is discussing a verifiable fact.

Systemd vs. Docker

Posted Mar 1, 2016 1:04 UTC (Tue) by vonbrand (subscriber, #4458) [Link] (3 responses)

Once you install anything non-Red Hat, it isn't the Red Hat supplied system anymore. It is reasonable for them to restrict support for the resulting chimaera, particularly if what is being replaced is some fundamental piece. I.e., if I install e.g. git from source, they won't mind (but steer clear from my repositories); if I compile my own glibc, they'll balk with good reason. Docker is even more intrusive than the later.

Systemd vs. Docker

Posted Mar 1, 2016 1:07 UTC (Tue) by Cyberax (✭ supporter ✭, #52523) [Link] (2 responses)

> Docker is even more intrusive than the later.
Why? Docker is just another application that happens to utilize cgroups.

Systemd vs. Docker

Posted Mar 1, 2016 10:09 UTC (Tue) by vonbrand (subscriber, #4458) [Link] (1 responses)

Come on, it provides an environment in which software runs. More comprehensive than glibc for sure

Systemd vs. Docker

Posted Mar 1, 2016 10:23 UTC (Tue) by Cyberax (✭ supporter ✭, #52523) [Link]

If you run a RHEL distro inside a Docker container - that definitely qualifies as "more comprehensive".

However, simply running Docker _inside_ RHEL is definitely covered. It's not fundamentally different from running DOS games inside a DOSBox emulator on RHEL.


Copyright © 2025, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds