Rke: Path /var/lib/kubelet is mounted on / but it is not a shared mount.

Created on 25 Jan 2018  路  3Comments  路  Source: rancher/rke

RKE version:

v0.0.12-dev

Docker version: (docker version,docker info preferred)

Docker version 17.03.2-ce

Operating system and kernel: (cat /etc/os-release, uname -r preferred)

Ubuntu 16.04.3 LTS

Type/provider of hosts: (VirtualBox/Bare-metal/AWS/GCE/DO)

LXD

cluster.yml file:

nodes:
- address: "rke-master-1"
  internal_address: ""
  role:
  - controlplane
  - etcd
  hostname_override: "master1"
  user: ubuntu
  docker_socket: /var/run/docker.sock
- address: "rke-master-2"
  internal_address: ""
  role:
  - controlplane
  - etcd
  hostname_override: "master2"
  user: ubuntu
  docker_socket: /var/run/docker.sock
- address: "rke-master-3"
  internal_address: ""
  role:
  - controlplane
  - etcd
  hostname_override: "master3"
  user: ubuntu
  docker_socket: /var/run/docker.sock
- address: "rke-worker-1"
  internal_address: ""
  role:
  - worker
  hostname_override: "worker1"
  user: ubuntu
  docker_socket: /var/run/docker.sock
- address: "rke-worker-2"
  internal_address: ""
  role:
  - worker
  hostname_override: "worker2"
  user: ubuntu
  docker_socket: /var/run/docker.sock
- address: "rke-worker-3"
  internal_address: ""
  role:
  - worker
  hostname_override: "worker3"
  user: ubuntu
  docker_socket: /var/run/docker.sock
services:
  etcd:
    image: quay.io/coreos/etcd:latest
    extra_args: {}
  kube-api:
    image: rancher/k8s:v1.8.3-rancher2
    extra_args: {}
    service_cluster_ip_range: 10.233.0.0/18
  kube-controller:
    image: rancher/k8s:v1.8.3-rancher2
    extra_args: {}
    cluster_cidr: 10.233.64.0/18
    service_cluster_ip_range: 10.233.0.0/18
  scheduler:
    image: rancher/k8s:v1.8.3-rancher2
    extra_args: {}
  kubelet:
    image: rancher/k8s:v1.8.3-rancher2
    extra_args: {}
    cluster_domain: cluster.local
    infra_container_image: gcr.io/google_containers/pause-amd64:3.0
    cluster_dns_server: 10.233.0.3
  kubeproxy:
    image: rancher/k8s:v1.8.3-rancher2
    #image: gcr.io/google-containers/hyperkube-amd64:v1.8.5
    extra_args: {}
network:
  plugin: calico
  options: {}
auth:
  strategy: x509
  options: {}
addons: ""
ssh_key_path: /home/ubuntu/.ssh/id_rsa

Steps to Reproduce:

Results:

FATA[1327] [workerPlane] Failed to bring up Worker Plane: Failed to start [kubelet] container on host [rke-master-3]: Error response from daemon: linux mounts: Path /var/lib/kubelet is mounted on / but it is not a shared mount.

Most helpful comment

I forced MountFlags=shared on docker service, and now kubelet works correctly.

All 3 comments

Looks similar, but not.
I haven't MountFlags option in my service. If I add MountFlags= then reload and restart, I still have the same issue.

I forced MountFlags=shared on docker service, and now kubelet works correctly.

Was this page helpful?
0 / 5 - 0 ratings