Giter Club home page Giter Club logo

Comments (7)

chukaofili avatar chukaofili commented on September 3, 2024

@jakoguta Possibly (on the coredns), although i do know this is a routing issue. Have you tried the setup with kubedns?

from kubernetes-on-digitalocean.

jakoguta avatar jakoguta commented on September 3, 2024

@chukaofili in kube v1.11, CoreDNS is the default dns server. Due to the fact am not an expert with Kube, I am not confident to change from CoreDNS to KubeDNS. I will have to do some research and see if I can get a fix on this.

from kubernetes-on-digitalocean.

chukaofili avatar chukaofili commented on September 3, 2024

from kubernetes-on-digitalocean.

jakoguta avatar jakoguta commented on September 3, 2024

@chukaofili I managed to get it working. It was a mistake on my part that messed the network.

ssh core@$MASTER_IP sudo sysctl net.bridge.bridge-nf-call-iptables=1
kubectl apply -f https://raw.githubusercontent.com/coreos/flannel/v0.10.0/Documentation/kube-flannel.yml

I believe I did not run sudo sysctl net.bridge.bridge-nf-call-iptables=1

Thanks for the support, you may close

Edit: I found out that the problem is from the networking part

## Please note that this assumes KUBELET_EXTRA_ARGS hasn’t already been set in the unit file.
echo "Fix Digital Oceans private ip for routing"
IFACE=eth1  # change to eth1 for DO's private network
DROPLET_IP_ADDRESS=$(ip addr show dev $IFACE | awk 'match($0,/inet (([0-9]|\.)+).* scope global/,a) { print a[1]; exit }')
echo $DROPLET_IP_ADDRESS  # check this, just in case
sed -i '2s/^/Environment="KUBELET_EXTRA_ARGS=--node-ip='$DROPLET_IP_ADDRESS'"\n/' /etc/systemd/system/kubelet.service.d/10-kubeadm.conf
systemctl daemon-reload
systemctl restart kubelet

@chukaofili In Kube v1.11 putting Environment="KUBELET_EXTRA_ARGS=--node-ip='$DROPLET_IP_ADDRESS'" in the /etc/systemd/system/kubelet.service.d/10-kubeadm.conf will not work. However, I put it in the file /etc/default/kubelet as shown below and it worked.

IFACE=eth1  # change to eth1 for DO's private network
DROPLET_IP_ADDRESS=$(ip addr show dev $IFACE | awk 'match($0,/inet (([0-9]|\.)+).* scope global/,a) { print a[1]; exit }')
echo $DROPLET_IP_ADDRESS  # check this, just in case
echo "KUBELET_EXTRA_ARGS=--node-ip=$DROPLET_IP_ADDRESS  " > /etc/default/kubelet
systemctl daemon-reload
systemctl restart kubelet

Credits to @jazoom from this issue thread kubernetes/kubeadm#203.

from kubernetes-on-digitalocean.

chukaofili avatar chukaofili commented on September 3, 2024

@jakoguta Ah i see, thanks for info.

from kubernetes-on-digitalocean.

jakoguta avatar jakoguta commented on September 3, 2024

@chukaofili the KUBELET_EXTRA_ARGS values below for the persistent volumes should also be placed in the file /etc/default/kubelet for Kube v1.11. I hope you may find time to add this observation to your documentation for those running Kube v1.11+. The busy-pod was not mounting until I moved the KUBELET_EXTRA_ARGS values.

#!/bin/bash

sudo su
mkdir -p /etc/kubernetes/kubelet-plugins/volume
sed -i -e 's#\(KUBELET_EXTRA_ARGS=\)#\1--volume-plugin-dir=/etc/kubernetes/kubelet-plugins/volume #' /etc/systemd/system/kubelet.service.d/10-kubeadm.conf
systemctl daemon-reload
systemctl restart kubelet

from kubernetes-on-digitalocean.

chukaofili avatar chukaofili commented on September 3, 2024

@jakoguta Yes, just updated the previous one, will update this too now. Thanks for bringing this to my attention.

from kubernetes-on-digitalocean.

Related Issues (3)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.