Comments (7)
@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.
@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.
from kubernetes-on-digitalocean.
@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.
@jakoguta Ah i see, thanks for info.
from kubernetes-on-digitalocean.
@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.
@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)
- Creating DO k8s cluster with two masters HOT 2
- Help Wanted HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from kubernetes-on-digitalocean.