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

containerd service is running on docker driver with docker run time #7433

Closed
medyagh opened this issue Apr 5, 2020 · 6 comments
Closed

containerd service is running on docker driver with docker run time #7433

medyagh opened this issue Apr 5, 2020 · 6 comments
Labels
area/performance Performance related issues co/docker-driver Issues related to kubernetes in container co/runtime/docker Issues specific to a docker runtime kind/design Categorizes issue or PR as related to design. priority/awaiting-more-evidence Lowest priority. Possibly useful, but not yet enough support to actually get it done.

Comments

@medyagh
Copy link
Member

medyagh commented Apr 5, 2020

While trying to figure out why minikube soft start on docker driver takes longer than VM (#7432)

I noticed on docker driver the containerd service is running but in VM its NOT !

on docker driver:

docker@minikube:~$ sudo systemctl status containerd
● containerd.service - containerd container runtime
   Loaded: loaded (/etc/systemd/system/containerd.service; disabled; vendor preset: enabled)
   Active: active (running) since Sun 2020-04-05 10:21:11 UTC; 44s ago
     Docs: https://containerd.io

on VM hyperkit:

● containerd.service - containerd container runtime
   Loaded: loaded (/usr/lib/systemd/system/containerd.service; disabled; vendor preset: enabled)
   Active: inactive (dead)
     Docs: https://containerd.io

@afbjorklund
Copy link
Collaborator

afbjorklund commented Apr 5, 2020

Since dockerd depends on containerd, I think that this situation is normal ?

Previously it had custom docker-runc and docker-containerd, but not anymore.

https://docs.docker.com/engine/release-notes/18.09/#important-notes-about-this-release-1

In Docker versions prior to 18.09, containerd was managed by the Docker engine daemon. In Docker Engine 18.09, containerd is managed by systemd.

@afbjorklund afbjorklund added the co/docker-driver Issues related to kubernetes in container label Apr 5, 2020
@medyagh
Copy link
Member Author

medyagh commented Apr 5, 2020

BindsTo=containerd.service

I just saw this that only for ubuntu provisioner (kic provisioner) we add bind to containerd and when I remove it it will get stuck in kubeadm init.

@afbjorklund why in VM world we dont have containerd service running but only in kic world ?

also if docker service has to have containerd service running, then we need to disable the logic to DISABLE other container run times.... (because for docker it will disable containerd (which api server is running on it) that willi cause an un-needed False needsReset()
that will make kic soft start (start and then start) very slow compared to VM

what do youu think we should do about it ?

@medyagh
Copy link
Member Author

medyagh commented Apr 5, 2020

from minikube logs for docker driver on a soft start I see that it is trying to stop other container run time services

I0405 04:32:31.291549   38471 kic_runner.go:91] Run: curl -sS -m 2 https://k8s.gcr.io/
I0405 04:32:31.293213   38471 kic_runner.go:91] Run: sudo systemctl is-active --quiet service containerd
I0405 04:32:31.519786   38471 kic_runner.go:91] Run: sudo systemctl stop -f containerd

i believe the problem is on ubuntu I install docker for ubuntu which requires containerd

but in the VM the buildroot does not rquired containerd

@afbjorklund
Copy link
Collaborator

afbjorklund commented Apr 5, 2020

@afbjorklund why in VM world we dont have containerd service running but only in kic world ?

The VM has two different containerd running:

  • /run/docker/containerd/containerd.sock

/usr/lib/systemd/system/docker.service
containerd --config /var/run/docker/containerd/containerd.toml --log-level info

  • /run/containerd/containerd.sock

/usr/lib/systemd/system/containerd.service
/usr/bin/containerd --root /mnt/sda1/var/lib/containerd

That is, Docker will start containerd itself if not running...

See libcontainerd/supervisor/remote_daemon.go

@afbjorklund afbjorklund added co/runtime/docker Issues specific to a docker runtime area/performance Performance related issues labels Apr 5, 2020
@afbjorklund
Copy link
Collaborator

The minikube docker.service has this configuration:

ExecStart=/usr/bin/dockerd -H tcp://0.0.0.0:2376 -H unix:///var/run/docker.sock --default-ulimit=nofile=1048576:1048576 --tlsverify --tlscacert /etc/docker/ca.pem --tlscert /etc/docker/server.pem --tlskey /etc/docker/server-key.pem --label provider=virtualbox --insecure-registry 10.96.0.0/12

The ubuntu docker.service has this configuration:

ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock

@tstromberg tstromberg added the priority/awaiting-more-evidence Lowest priority. Possibly useful, but not yet enough support to actually get it done. label Apr 15, 2020
@tstromberg
Copy link
Contributor

Can we close this because the mystery is solved?

@tstromberg tstromberg added the kind/design Categorizes issue or PR as related to design. label Apr 15, 2020
@medyagh medyagh closed this as completed May 5, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/performance Performance related issues co/docker-driver Issues related to kubernetes in container co/runtime/docker Issues specific to a docker runtime kind/design Categorizes issue or PR as related to design. priority/awaiting-more-evidence Lowest priority. Possibly useful, but not yet enough support to actually get it done.
Projects
None yet
Development

No branches or pull requests

3 participants