influxdata/helm-charts

[telegraf-ds] MountVolume.SetUp failed for volume "docker-socket"

Closed this issue · 4 comments

I tried installing this chart onto my local k3s cluster and ran into this issue:

  Warning  FailedMount  67s (x18 over 21m)   kubelet            MountVolume.SetUp failed for volume "docker-socket" : hostPath type check failed: /var/run/docker.sock is not a socket file

I don't see a docker.sock on the host. Docker is also not running on the host (I believe k3s just uses containerd?). Is it possible to make this configurable or is access to docker.sock required for the DaemonSet to function?

Alternate route is to just install Telegraf on the host directly I assume?

Can you try installing the chart with --set config.docker_endpoint="" ?

@alespour I got this working today on my amd64 NUC nodes. Getting ErrImagePull on my Pi 4B nodes, though I'm guessing that is not related.

@joestump I think alpine-based images are only for linux/amd64, if you could try just 1.21 or latest (or 1.22) for recently released 1.22, these are available for amd64, arm64v8 and arm32v7.

--set image.tag=1.21

@joestump please, could you share your (sanitized) values.yml? Mine is this

USER-SUPPLIED VALUES:
config.docker_endpoint: ""
config.outputs:
- influxdb_v2:
    bucket: default
    organization: influxdata
    token: BLABLABLA==
    urls:
    - http://influx2.monitoring.svc

With this Kubernetes version/platform (I've built a k3s cluster on Hetzner)

[test0|monitoring] ferdi@DESKTOP-NL6I2OD:~/another-test$ kubectl version
WARNING: This version information is deprecated and will be replaced with the output from kubectl version --short.  Use --output=yaml|json to get the full version.
Client Version: version.Info{Major:"1", Minor:"24", GitVersion:"v1.24.1", GitCommit:"3ddd0f45aa91e2f30c70734b175631bec5b5825a", GitTreeState:"clean", BuildDate:"2022-05-24T12:26:19Z", GoVersion:"go1.18.2", Compiler:"gc", Platform:"linux/amd64"}
Kustomize Version: v4.5.4
Server Version: version.Info{Major:"1", Minor:"22", GitVersion:"v1.22.9+k3s1", GitCommit:"8b0b50a5e88214f69e4ef35ebfd60c6adac9735f", GitTreeState:"clean", BuildDate:"2022-04-28T22:46:07Z", GoVersion:"go1.16.10", Compiler:"gc", Platform:"linux/amd64"}
WARNING: version difference between client (1.24) and server (1.22) exceeds the supported minor version skew of +/-1

but I'm still stuck with the Telegraf pods in ContainerCreating

[test0|monitoring] ferdi@DESKTOP-NL6I2OD:~/another-test$ kubectl get po
NAME                            READY   STATUS              RESTARTS   AGE
ds-telegraf-telegraf-ds-wr4sx   0/1     ContainerCreating   0          96m
ds-telegraf-telegraf-ds-xgbd8   0/1     ContainerCreating   0          96m
ds-telegraf-telegraf-ds-zwhd4   0/1     ContainerCreating   0          96m
influx2-influxdb2-0             1/1     Running             0          111m

With these error messages:

  Warning  FailedMount  56m (x4 over 88m)    kubelet  Unable to attach or mount volumes: unmounted volumes=[docker-socket], unattached volumes=[kube-api-access-rqmkt varrunutmpro hostfsro docker-socket config]: timed out waiting for the condition
  Warning  FailedMount  11m (x50 over 97m)   kubelet  MountVolume.SetUp failed for volume "docker-socket" : hostPath type check failed: /var/run/docker.sock is not a socket file
  Warning  FailedMount  6m35s (x4 over 95m)  kubelet  Unable to attach or mount volumes: unmounted volumes=[docker-socket], unattached volumes=[config kube-api-access-rqmkt varrunutmpro hostfsro docker-socket]: timed out waiting for the condition
  Warning  FailedMount  2m2s (x17 over 76m)  kubelet  Unable to attach or mount volumes: unmounted volumes=[docker-socket], unattached volumes=[varrunutmpro hostfsro docker-socket config kube-api-access-rqmkt]: timed out waiting for the condition