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

why crictl warns on Kic and not on VM "As the default settings are now deprecated, you should set the endpoint instead." #10175

Closed
medyagh opened this issue Jan 19, 2021 · 2 comments · Fixed by #10221
Assignees
Labels
co/runtime/docker Issues specific to a docker runtime kind/bug Categorizes issue or PR as related to a bug. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release.

Comments

@medyagh
Copy link
Member

medyagh commented Jan 19, 2021

medya@~/workspace/minikube (extension_context) $ minikube ssh
docker@minikube:~$ sudo crictl images -o json
{
  "images": [
    {
      "id": "sha256:85069258b98ac4e9f9fbd51dfba3b4212d8cd1d79df7d2ecff44b1319ed641cb",
      "repoTags": [
        "gcr.io/k8s-minikube/storage-provisioner:v4"
      ],
      "repoDigests": [
        "gcr.io/k8s-minikube/storage-provisioner@sha256:06f83c679a723d938b8776510d979c69549ad7df516279981e23554b3e68572f"
      ],
      "size": "29683712",
      "uid": null,
      "username": ""
    },
    {
      "id": "sha256:bfe3a36ebd2528b454be6aebece806db5b40407b833e2af9617bf39afaff8c16",
      "repoTags": [
        "k8s.gcr.io/coredns:1.7.0"
      ],
      "repoDigests": [
        "k8s.gcr.io/coredns@sha256:73ca82b4ce829766d4f1f10947c3a338888f876fbed0540dc849c89ff256e90c"
      ],
      "size": "45227747",
      "uid": null,
      "username": ""
    },
    {
      "id": "sha256:0369cf4303ffdb467dc219990960a9baa8512a54b0ad9283eaf55bd6c0adb934",
      "repoTags": [
        "k8s.gcr.io/etcd:3.4.13-0"
      ],
      "repoDigests": [
        "k8s.gcr.io/etcd@sha256:4ad90a11b55313b182afc186b9876c8e891531b8db4c9bf1541953021618d0e2"
      ],
      "size": "253392289",
      "uid": null,
      "username": ""
    },
    {
      "id": "sha256:ca9843d3b545457f24b012d6d579ba85f132f2406aa171ad84d53caa55e5de99",
      "repoTags": [
        "k8s.gcr.io/kube-apiserver:v1.20.0"
      ],
      "repoDigests": [
        "k8s.gcr.io/kube-apiserver@sha256:8b8125d7a6e4225b08f04f65ca947b27d0cc86380bf09fab890cc80408230114"
      ],
      "size": "121665018",
      "uid": null,
      "username": ""
    },
    {
      "id": "sha256:b9fa1895dcaa6d3dd241d6d9340e939ca30fc0946464ec9f205a8cbe738a8080",
      "repoTags": [
        "k8s.gcr.io/kube-controller-manager:v1.20.0"
      ],
      "repoDigests": [
        "k8s.gcr.io/kube-controller-manager@sha256:00ccc3a5735e82d53bc26054d594a942fae64620a6f84018c057a519ba7ed1dc"
      ],
      "size": "115844602",
      "uid": null,
      "username": ""
    },
    {
      "id": "sha256:10cc881966cfd9287656c2fce1f144625602653d1e8b011487a7a71feb100bdc",
      "repoTags": [
        "k8s.gcr.io/kube-proxy:v1.20.0"
      ],
      "repoDigests": [
        "k8s.gcr.io/kube-proxy@sha256:40423415eebbd598d1c2660a0a38606ad1d949ea9404c405eaf25929163b479d"
      ],
      "size": "118400203",
      "uid": null,
      "username": ""
    },
    {
      "id": "sha256:3138b6e3d471224fd516f758f3b53309219bcb6824e07686b3cd60d78012c899",
      "repoTags": [
        "k8s.gcr.io/kube-scheduler:v1.20.0"
      ],
      "repoDigests": [
        "k8s.gcr.io/kube-scheduler@sha256:beaa710325047fa9c867eff4ab9af38d9c2acec05ac5b416c708c304f76bdbef"
      ],
      "size": "46384634",
      "uid": null,
      "username": ""
    },
    {
      "id": "sha256:80d28bedfe5dec59da9ebf8e6260224ac9008ab5c11dbbe16ee3ba3e4439ac2c",
      "repoTags": [
        "k8s.gcr.io/pause:3.2"
      ],
      "repoDigests": [
        "k8s.gcr.io/pause@sha256:927d98197ec1141a368550822d18fa1c60bdae27b78b0c004f705f548c07814f"
      ],
      "size": "682696",
      "uid": null,
      "username": ""
    },
    {
      "id": "sha256:9a07b5b4bfac07e5cfc27f76c34516a3ad2fdfa3f683f375141fe662ef2e72db",
      "repoTags": [
        "kubernetesui/dashboard:v2.1.0"
      ],
      "repoDigests": [
        "kubernetesui/dashboard@sha256:7f80b5ba141bead69c4fee8661464857af300d7d7ed0274cf7beecedc00322e6"
      ],
      "size": "225733746",
      "uid": null,
      "username": ""
    },
    {
      "id": "sha256:86262685d9abb35698a4e03ed13f9ded5b97c6c85b466285e4f367e5232eeee4",
      "repoTags": [
        "kubernetesui/metrics-scraper:v1.0.4"
      ],
      "repoDigests": [
        "kubernetesui/metrics-scraper@sha256:555981a24f184420f3be0c79d4efb6c948a85cfce84034f85a563f4151a81cbf"
      ],
      "size": "36937728",
      "uid": null,
      "username": ""
    }
  ]
}
docker@minikube:~$ docker version
Client: Docker Engine - Community
 Version:           20.10.0
 API version:       1.41
 Go version:        go1.13.15
 Git commit:        7287ab3
 Built:             Tue Dec  8 18:59:40 2020
 OS/Arch:           linux/amd64
 Context:           default
 Experimental:      true

Server: Docker Engine - Community
 Engine:
  Version:          20.10.0
  API version:      1.41 (minimum version 1.12)
  Go version:       go1.13.15
  Git commit:       eeddea2
  Built:            Tue Dec  8 18:57:45 2020
  OS/Arch:          linux/amd64
  Experimental:     false
 containerd:
  Version:          1.4.3
  GitCommit:        269548fa27e0089a8b8278fc4fc781d7f65a939b
 runc:
  Version:          1.0.0-rc92
  GitCommit:        ff819c7e9184c13b7c2607fe6c30ae19403a7aff
 docker-init:
  Version:          0.19.0
  GitCommit:        de40ad0
docker@minikube:~$ exit
logout
medya@~/workspace/minikube (extension_context) $ minikube start -p p1 --driver=hyperkit
😄  [p1] minikube v1.16.0 on Darwin 10.15.7
✨  Using the hyperkit driver based on user configuration
💿  Downloading VM boot image ...
    > minikube-v1.16.0.iso.sha256: 65 B / 65 B [-------------] 100.00% ? p/s 0s
    > minikube-v1.16.0.iso: 212.62 MiB / 212.62 MiB [] 100.00% 37.13 MiB p/s 6s
👍  Starting control plane node p1 in cluster p1
🔥  Creating hyperkit VM (CPUs=2, Memory=4000MB, Disk=20000MB) ...
🐳  Preparing Kubernetes v1.20.0 on Docker 20.10.0 ...
    ▪ Generating certificates and keys ...
    ▪ Booting up control plane ...
    ▪ Configuring RBAC rules ...
🔎  Verifying Kubernetes components...
🌟  Enabled addons: storage-provisioner, default-storageclass
🏄  Done! kubectl is now configured to use "p1" cluster and "default" namespace by default
medya@~/workspace/minikube (extension_context) $ minikube ssh -p p1 
                         _             _            
            _         _ ( )           ( )           
  ___ ___  (_)  ___  (_)| |/')  _   _ | |_      __  
/' _ ` _ `\| |/' _ `\| || , <  ( ) ( )| '_`\  /'__`\
| ( ) ( ) || || ( ) || || |\`\ | (_) || |_) )(  ___/
(_) (_) (_)(_)(_) (_)(_)(_) (_)`\___/'(_,__/'`\____)

$ sudo crictl images -o json
WARN[0000] image connect using default endpoints: [unix:///var/run/dockershim.sock unix:///run/containerd/containerd.sock unix:///run/crio/crio.sock]. As the default settings are now deprecated, you should set the endpoint instead. 
{
  "images": [
    {
      "id": "sha256:85069258b98ac4e9f9fbd51dfba3b4212d8cd1d79df7d2ecff44b1319ed641cb",
      "repoTags": [
        "gcr.io/k8s-minikube/storage-provisioner:v4"
      ],
      "repoDigests": [
        "gcr.io/k8s-minikube/storage-provisioner@sha256:06f83c679a723d938b8776510d979c69549ad7df516279981e23554b3e68572f"
      ],
      "size": "29683712",
      "uid": null,
      "username": "",
      "spec": null
    },
    {
      "id": "sha256:bfe3a36ebd2528b454be6aebece806db5b40407b833e2af9617bf39afaff8c16",
      "repoTags": [
        "k8s.gcr.io/coredns:1.7.0"
      ],
      "repoDigests": [
        "k8s.gcr.io/coredns@sha256:73ca82b4ce829766d4f1f10947c3a338888f876fbed0540dc849c89ff256e90c"
      ],
      "size": "45227747",
      "uid": null,
      "username": "",
      "spec": null
    },
    {
      "id": "sha256:0369cf4303ffdb467dc219990960a9baa8512a54b0ad9283eaf55bd6c0adb934",
      "repoTags": [
        "k8s.gcr.io/etcd:3.4.13-0"
      ],
      "repoDigests": [
        "k8s.gcr.io/etcd@sha256:4ad90a11b55313b182afc186b9876c8e891531b8db4c9bf1541953021618d0e2"
      ],
      "size": "253392289",
      "uid": null,
      "username": "",
      "spec": null
    },
    {
      "id": "sha256:ca9843d3b545457f24b012d6d579ba85f132f2406aa171ad84d53caa55e5de99",
      "repoTags": [
        "k8s.gcr.io/kube-apiserver:v1.20.0"
      ],
      "repoDigests": [
        "k8s.gcr.io/kube-apiserver@sha256:8b8125d7a6e4225b08f04f65ca947b27d0cc86380bf09fab890cc80408230114"
      ],
      "size": "121665018",
      "uid": null,
      "username": "",
      "spec": null
    },
    {
      "id": "sha256:b9fa1895dcaa6d3dd241d6d9340e939ca30fc0946464ec9f205a8cbe738a8080",
      "repoTags": [
        "k8s.gcr.io/kube-controller-manager:v1.20.0"
      ],
      "repoDigests": [
        "k8s.gcr.io/kube-controller-manager@sha256:00ccc3a5735e82d53bc26054d594a942fae64620a6f84018c057a519ba7ed1dc"
      ],
      "size": "115844602",
      "uid": null,
      "username": "",
      "spec": null
    },
    {
      "id": "sha256:10cc881966cfd9287656c2fce1f144625602653d1e8b011487a7a71feb100bdc",
      "repoTags": [
        "k8s.gcr.io/kube-proxy:v1.20.0"
      ],
      "repoDigests": [
        "k8s.gcr.io/kube-proxy@sha256:40423415eebbd598d1c2660a0a38606ad1d949ea9404c405eaf25929163b479d"
      ],
      "size": "118400203",
      "uid": null,
      "username": "",
      "spec": null
    },
    {
      "id": "sha256:3138b6e3d471224fd516f758f3b53309219bcb6824e07686b3cd60d78012c899",
      "repoTags": [
        "k8s.gcr.io/kube-scheduler:v1.20.0"
      ],
      "repoDigests": [
        "k8s.gcr.io/kube-scheduler@sha256:beaa710325047fa9c867eff4ab9af38d9c2acec05ac5b416c708c304f76bdbef"
      ],
      "size": "46384634",
      "uid": null,
      "username": "",
      "spec": null
    },
    {
      "id": "sha256:80d28bedfe5dec59da9ebf8e6260224ac9008ab5c11dbbe16ee3ba3e4439ac2c",
      "repoTags": [
        "k8s.gcr.io/pause:3.2"
      ],
      "repoDigests": [
        "k8s.gcr.io/pause@sha256:927d98197ec1141a368550822d18fa1c60bdae27b78b0c004f705f548c07814f"
      ],
      "size": "682696",
      "uid": null,
      "username": "",
      "spec": null
    },
    {
      "id": "sha256:9a07b5b4bfac07e5cfc27f76c34516a3ad2fdfa3f683f375141fe662ef2e72db",
      "repoTags": [
        "kubernetesui/dashboard:v2.1.0"
      ],
      "repoDigests": [
        "kubernetesui/dashboard@sha256:7f80b5ba141bead69c4fee8661464857af300d7d7ed0274cf7beecedc00322e6"
      ],
      "size": "225733746",
      "uid": null,
      "username": "",
      "spec": null
    },
    {
      "id": "sha256:86262685d9abb35698a4e03ed13f9ded5b97c6c85b466285e4f367e5232eeee4",
      "repoTags": [
        "kubernetesui/metrics-scraper:v1.0.4"
      ],
      "repoDigests": [
        "kubernetesui/metrics-scraper@sha256:555981a24f184420f3be0c79d4efb6c948a85cfce84034f85a563f4151a81cbf"
      ],
      "size": "36937728",
      "uid": null,
      "username": "",
      "spec": null
    }
  ]
}
$ cat /etc/cr
crio/   cron.d/ 
$ cat /etc/cr
crio/   cron.d/ 
$ cat  /etc/crictl.yaml   
cat: /etc/crictl.yaml: No such file or directory
$ cat  /etc/crictl.yaml
cat: /etc/crictl.yaml: No such file or directory
$ exut
-bash: exut: command not found
$ exit 
logout
ssh: Process exited with status 127
medya@~/workspace/minikube (extension_context) $ minikube ssh -p minikube
@medyagh medyagh added kind/bug Categorizes issue or PR as related to a bug. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. labels Jan 19, 2021
@medyagh medyagh changed the title why crictl warns on Kic and not on VM why crictl warns on Kic and not on VM "As the default settings are now deprecated, you should set the endpoint instead." Jan 19, 2021
@jiefenghe
Copy link
Contributor

/assign

@afbjorklund
Copy link
Collaborator

afbjorklund commented Jan 20, 2021

Maybe you were using something other than docker, for the profile under the docker driver ?

I get the same warning in KIC, which is a duplicate of the already known deprecation: #9868

$ sudo crictl version
WARN[0000] runtime connect using default endpoints: [unix:///var/run/dockershim.sock unix:///run/containerd/containerd.sock unix:///run/crio/crio.sock]. As the default settings are now deprecated, you should set the endpoint instead. 
Version:  0.1.0
RuntimeName:  docker
RuntimeVersion:  20.10.0
RuntimeApiVersion:  1.41.0

Kubernetes doesn't require crictl for docker, until the cri-dockerd is in use.

But we do need to configure the /etc/crictl.yaml file, just to avoid the warning.

Note that there is also a bug with socket path, in the docker cruntime:

        if err := populateCRIConfig(r.Runner, r.SocketPath()); err != nil {
                return err
        }

It needs to be /var/run/dockershim.sock, not /var/run/docker.sock.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
co/runtime/docker Issues specific to a docker runtime kind/bug Categorizes issue or PR as related to a bug. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release.
Projects
None yet
3 participants