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
[add version/20.10] A container has been force exited but docker ps reports the container Up #43482
Comments
Again a docker journal reads:
so let's testify this bug report, if it survives time test of 5 hours:
The new observations match the bug report. |
Not sure if this specific issue has been fixed since, but I see you're running a version of docker that is no longer maintained (and EOL versions of containerd and runc). If you have a test environment to try on, are you still able to reproduce this issue on a current version of docker (20.10.x) and containerd (1.5.x)? |
Hi Sebastiaan, it another test environment we have a docker at version:
It comes with containerd 1.4.4. If reproduced on that docker version would it be enough, please? |
The docker was restarted and then docker behaves as expected even for the force-exited containers. So this issue is reproducible only if docker is already in a "tired" state. What transitions docker to the "tired" state is so far unknown. |
On a host with:
SETUP NOTE: the fluentd port (defaults to --log-opt fluentd-address=localhost:24224) is not intentionally accepting connections. the repro steps were:
The zombie container was Up, it survived the force stop after the graceful shutdown period. The docker journal had expected info message:
My expectation is that the force stop covers the docker log driver too. |
The flag ForceStopAsyncSend was added to fluent logger lib in v1.5.0 (at this time named AsyncStop) to tell fluentd to abort sending logs asynchronously as soon as possible, when its Close() method is called. However this flag was broken because of the way the lib was handling it (basically, the lib could be stucked in retry-connect loop without checking this flag). Since fluent logger lib v1.7.0, calling Close() (when ForceStopAsyncSend is true) will really stop all ongoing send/connect procedure, wherever it's stucked. Signed-off-by: Albin Kerouanton <albinker@gmail.com> (cherry picked from commit bd61629) Signed-off-by: Wesley <wppttt@amazon.com>
f9df098 is an interesting commit. Following it I eventually ended at https://github.com/moby/moby/releases/tag/v20.10.13 which reads:
|
@pekuz are you still seeing this issue after upgrading? |
At the time, the upgrade was prevented by unavailability of newer Docker versions in RHEL repos. Meanwhile our R&D focus shifted elsewhere. I cannot verify in reasonable time frame. |
Thanks @pekuz I'll go ahead and close this ticket for now, but we can reopen if the issue still persists and if you have more details 👍 |
Description
Randomly, we are observing that docker cannot inspect some containers or it cannot restart them, or
docker stats
hungs. It is a long lasting issue happening with low frequency per docker instance but now I have identified one specific situation when it can happen.If
docker stop CONTAINER
struggles to stop container and it uses the force then docker can end in an inconsistent state (measured by subsequentdocker ps
).Typical workaround to resolve it is to restart the affected docker instance.
Steps to reproduce the issue:
Describe the results you received:
it's an unedited output, the important line is:
Describe the results you expected:
i.e.
86f164e7c63e
is not listed because it is not Up. The container is exited, despite forcefully.Additional information you deem important (e.g. issue happens only occasionally):
It sounds similar to #33369, here however using a stock docker and I might be closer why it is perceived random:
i.e. because the need for using force is random. And when force is used the issue can occur.
The docker/for-linux#1354 shares the symptoms, there it's believed that Docker fluentd log driver can be configured so that container stopping must be forced.
Output of
docker version
:Output of
docker info
:Additional environment details (AWS, VirtualBox, physical, etc.):
VM
The text was updated successfully, but these errors were encountered: