Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

iPython craches when run as PID 1 #77

Closed
soltysh opened this issue Nov 25, 2015 · 11 comments
Closed

iPython craches when run as PID 1 #77

soltysh opened this issue Nov 25, 2015 · 11 comments

Comments

@soltysh
Copy link
Contributor

soltysh commented Nov 25, 2015

There's a known issue with iPython we might want to address somehow in the base image. The problem is that when running ipython with PID 1 (iow. using docker) it'll crash. You need a process that will handle that for you, as described here.

@bparees @rhcarvalho @GrahamDumpleton wdyt

@GrahamDumpleton
Copy link
Contributor

FWIW, I integrated tini into my Docker base images and thus my S2I builders already. :-)

I pull various source packages and compile from source code so don't have an issue with that, but if you have the restriction of only being able to use official packages that is likely going to be a problem unless there is something equivalent in package repositories already.

@bparees
Copy link
Collaborator

bparees commented Dec 18, 2015

@soltysh what's the likelihood that iPython gets fixed? this doesn't sound like a complexity we want to add to our images by default (and we'd need an rpm package of tini, if one doesn't exist, so we'd probably need the SCL team to adopt it)

@GrahamDumpleton
Copy link
Contributor

Reality is that no one would use the Red Hat S2I images if they want to build a Docker image for IPython. So is not a big deal.

@soltysh
Copy link
Contributor Author

soltysh commented Dec 21, 2015

I think @GrahamDumpleton answered that question already.

@bparees
Copy link
Collaborator

bparees commented Dec 22, 2015

Given that, is there a compelling reason to keep this open?

@soltysh
Copy link
Contributor Author

soltysh commented Dec 22, 2015

I think we can close it. It'll be kept here for reference for other folks struggling with similar problems.

@bparees bparees closed this as completed Dec 22, 2015
@bparees
Copy link
Collaborator

bparees commented Dec 22, 2015

Thanks @soltysh

@soltysh
Copy link
Contributor Author

soltysh commented Dec 23, 2015

Thank @GrahamDumpleton he pointed me to that problem 😄

@GrahamDumpleton
Copy link
Contributor

I should have clarified that although no one will use this image for IPython, they will use the Tornado WSGI server and Tornado ASYNC server, Waitress WSGI server, plus others such as the Python standard library HTTP server. None of these will handle properly the pid 1 zombie reading and so eventually will crap out due to memory usage issues, or confusion due to reparenting of processes (as is case for IPython). Basically, if anyone supplies their own app.py and overrides gunicorn there is a good chance they will have problems.

I will be posting a blog post about the issue as part of my series on porting IPython to Docker/OpenShift, highlighting how these other commonly used Python web servers can fail.

@soltysh
Copy link
Contributor Author

soltysh commented Dec 29, 2015

@GrahamDumpleton that sounds perfect, can you please post a link to it in this issue?

@GrahamDumpleton
Copy link
Contributor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants