Welcome to the Linux Foundation Forum!

pod networking : flannel

Posts: 1
edited December 2017 in LFS258 Class Forum

Hi [Sebastian],

Since the exam is using Ubuntu Xenial (16.04) and Kubernetes v1.6.2, I am trying to create a cluster using these versions. And I am trying to do this in Vagrant so that I can test locally.

My topology has one master and one worker. I also ensured that both the nodes have Docker 1.12.6~cs13-0~ubuntu-xenial.

[On the master] I created the cluster using the following command:

  kubeadm init --pod-network-cidr=10.244.0.0/16 --kubernetes-version=v1.6.2 --apiserver-advertise-address=10.0.0.10

I edited kube-flannel.yml to add "--iface=eth1" and then did 

  kubectl apply -f kube-flannel.yml

I can see that a new pod is created for flannel and it is "Running". However the dns pod is stuck in "Pending".

The master node is also stuck in "NotReady".

I checked the logs for the flannel pod and it has no errors. I also ensured that a flannel configuration file exists in "/etc/cni/net.d/10-flannel.conflist".

I also connected to the etcd pod and did a query as I expect flannel to insert a KV. But etcdctl returned no results.

[On the worker] I joined the worker node to the cluster and can see that a new flannel pod is created. However the worker is also stuck in "NotReady". I can see that the worker node has the flannel configuration file in "/etc/cni/net.d/10-flannel.conflist".

The cluster goes to "Ready" if I use the Weave plugin

  kubectl apply -f https://git.io/weave-kube-1.6

Is there a flannel manifest that is specific to Kubernetes 1.6.2?

Thanks.

Comments

  • Posts: 1,000

    There was an update to flannel which required access to portmap, but this was not included in any documentation. If you load 


    1. wget https://github.com/projectcalico/cni-plugin/releases/download/v1.9.1/portmap
    2. Move the binary to the expected directory and change the access mode.
    3. sudo mv portmap /opt/cni/bin/portmap
    4. sudo chmod 755 /opt/cni/bin/portmap
    5. Find the current kube-dns container that is not in a
    6. Running state.
    7. kubectl get pods --all-namespaces
    8. ....
    9. kube-system kube-dns-545bc4bfd4-xtwn7 0/3 ContainerCreating 0 26m
    10. ....
    11. Delete the container. It should spawn a new container which
    12. will show a Running state quickly. Your container names
    13. will be different.
    14. kubectl delete pod kube-dns-545bc4bfd4-xtwn7 -n kube-system
    15. kubectl get pods --all-namespaces

    Regards,

  • Posts: 2,295
    edited January 2018

    Hi,

    The CKA exam was updated to Kubernetes 1.9.1 this morning.

    Thank you,

    Flavia

Welcome!

It looks like you're new here. Sign in or register to get started.
Sign In

Welcome!

It looks like you're new here. Sign in or register to get started.
Sign In

Categories

Upcoming Training