Fixed
Created: Sep 4, 2020
Updated: Sep 20, 2020
Resolved Date: Sep 20, 2020
Found In Version: 10.20.39.0
Fix Version: 10.20.39.0
Severity: Standard
Applicable for: Wind River Linux CD
Component/s: Userspace
root@intel-x86-64:~# cat /proc/cmdline
console=ttyS0,115200 ip=dhcp root=/dev/sda1 rw selinux=0 enforcing=0 mem=24000M
root@intel-x86-64:~#
root@intel-x86-64:~# kubectl get node
NAME STATUS ROLES AGE VERSION
master Ready master 67s v1.18.8-dirty
root@intel-x86-64:~#
root@intel-x86-64:~#
root@intel-x86-64:~# kubectl get pod -A -owide
NAMESPACE NAME READY STATUS RESTARTS AGE IP NODE NOMINATED NODE READINESS GATES
kube-system calico-kube-controllers-65f8bc95db-2m6nn 1/1 Running 0 105s 10.244.219.67 master <none> <none>
kube-system calico-node-9sxj2 0/1 Running 0 105s 128.224.178.51 master <none> <none>
kube-system coredns-66bff467f8-chd64 1/1 Running 0 105s 10.244.219.66 master <none> <none>
kube-system coredns-66bff467f8-qnxwv 1/1 Running 0 105s 10.244.219.65 master <none> <none>
kube-system etcd-master 1/1 Running 0 119s 128.224.178.51 master <none> <none>
kube-system kube-apiserver-master 1/1 Running 0 119s 128.224.178.51 master <none> <none>
kube-system kube-controller-manager-master 1/1 Running 0 119s 128.224.178.51 master <none> <none>
kube-system kube-proxy-qvlsp 1/1 Running 0 105s 128.224.178.51 master <none> <none>
kube-system kube-scheduler-master 1/1 Running 0 119s 128.224.178.51 master <none> <none>
root@intel-x86-64:~#
root@intel-x86-64:~# kubectl describe pod -n kube-system calico-node-9sxj2
Name: calico-node-9sxj2
Namespace: kube-system
Priority: 2000001000
Priority Class Name: system-node-critical
Node: master/128.224.178.51
Start Time: Fri, 04 Sep 2020 08:33:09 +0000
Labels: controller-revision-hash=768dd66fff
k8s-app=calico-node
pod-template-generation=1
Annotations: scheduler.alpha.kubernetes.io/critical-pod:
Status: Running
IP: 128.224.178.51
IPs:
IP: 128.224.178.51
Controlled By: DaemonSet/calico-node
Init Containers:
upgrade-ipam:
Container ID: docker://89473d8569d702c1430cb340a3dff36fae6a195e58fab21b8a2bcd689536f9c8
Image: calico/cni:v3.14.2
Image ID: docker-pullable://pek-lpdfs01:5000/calico/cni@sha256:6ee284684a38631a1d91206134cbe3005b368affb86a703a12ad28398119bbc0
Port: <none>
Host Port: <none>
Command:
/opt/cni/bin/calico-ipam
-upgrade
State: Terminated
Reason: Completed
Exit Code: 0
Started: Fri, 04 Sep 2020 08:33:13 +0000
Finished: Fri, 04 Sep 2020 08:33:13 +0000
Ready: True
Restart Count: 0
Environment:
KUBERNETES_NODE_NAME: (v1:spec.nodeName)
CALICO_NETWORKING_BACKEND: <set to the key 'calico_backend' of config map 'calico-config'> Optional: false
Mounts:
/host/opt/cni/bin from cni-bin-dir (rw)
/var/lib/cni/networks from host-local-net-dir (rw)
/var/run/secrets/kubernetes.io/serviceaccount from calico-node-token-tx4jt (ro)
install-cni:
Container ID: docker://20df2c1a39fd6254f40267da7decf56042f8ddd5c82118f8c75cebeb03b7259b
Image: calico/cni:v3.14.2
Image ID: docker-pullable://pek-lpdfs01:5000/calico/cni@sha256:6ee284684a38631a1d91206134cbe3005b368affb86a703a12ad28398119bbc0
Port: <none>
Host Port: <none>
Command:
/install-cni.sh
State: Terminated
Reason: Completed
Exit Code: 0
Started: Fri, 04 Sep 2020 08:33:16 +0000
Finished: Fri, 04 Sep 2020 08:33:16 +0000
Ready: True
Restart Count: 0
Environment:
CNI_CONF_NAME: 10-calico.conflist
CNI_NETWORK_CONFIG: <set to the key 'cni_network_config' of config map 'calico-config'> Optional: false
KUBERNETES_NODE_NAME: (v1:spec.nodeName)
CNI_MTU: <set to the key 'veth_mtu' of config map 'calico-config'> Optional: false
SLEEP: false
Mounts:
/host/etc/cni/net.d from cni-net-dir (rw)
/host/opt/cni/bin from cni-bin-dir (rw)
/var/run/secrets/kubernetes.io/serviceaccount from calico-node-token-tx4jt (ro)
flexvol-driver:
Container ID: docker://624df0206c528c5d15824ef1b4b9acba412b160c386d7be427ccc2b86097a5a0
Image: calico/pod2daemon-flexvol:v3.14.2
Image ID: docker-pullable://pek-lpdfs01:5000/calico/pod2daemon-flexvol@sha256:c8971aef0dcda39d394755082e65e9e4d2cb09022ec9d5304ec3ab9a524ab271
Port: <none>
Host Port: <none>
State: Terminated
Reason: Completed
Exit Code: 0
Started: Fri, 04 Sep 2020 08:33:20 +0000
Finished: Fri, 04 Sep 2020 08:33:20 +0000
Ready: True
Restart Count: 0
Environment: <none>
Mounts:
/host/driver from flexvol-driver-host (rw)
/var/run/secrets/kubernetes.io/serviceaccount from calico-node-token-tx4jt (ro)
Containers:
calico-node:
Container ID: docker://015c6dde9abea9e707cf9c0154e17e5324d0755f9d3026af41ebcdcc7abff13c
Image: calico/node:v3.14.2
Image ID: docker-pullable://pek-lpdfs01:5000/calico/node@sha256:d237b25921800164eb22d7a85a6703b189b685f8706756ba17afe96752bca7fc
Port: <none>
Host Port: <none>
State: Running
Started: Fri, 04 Sep 2020 08:33:22 +0000
Ready: False
Restart Count: 0
Requests:
cpu: 250m
Liveness: exec [/bin/calico-node -felix-live -bird-live] delay=10s timeout=1s period=10s #success=1 #failure=6
Readiness: exec [/bin/calico-node -felix-ready -bird-ready] delay=0s timeout=1s period=10s #success=1 #failure=3
Environment:
DATASTORE_TYPE: kubernetes
WAIT_FOR_DATASTORE: true
NODENAME: (v1:spec.nodeName)
CALICO_NETWORKING_BACKEND: <set to the key 'calico_backend' of config map 'calico-config'> Optional: false
CLUSTER_TYPE: k8s,bgp
IP_AUTODETECTION_METHOD: interface=eth2
IP: autodetect
CALICO_IPV4POOL_IPIP: Always
CALICO_IPV4POOL_VXLAN: Never
FELIX_IPINIPMTU: <set to the key 'veth_mtu' of config map 'calico-config'> Optional: false
FELIX_VXLANMTU: <set to the key 'veth_mtu' of config map 'calico-config'> Optional: false
CALICO_DISABLE_FILE_LOGGING: true
FELIX_DEFAULTENDPOINTTOHOSTACTION: ACCEPT
FELIX_IPV6SUPPORT: false
FELIX_LOGSEVERITYSCREEN: info
FELIX_HEALTHENABLED: true
Mounts:
/lib/modules from lib-modules (ro)
/run/xtables.lock from xtables-lock (rw)
/var/lib/calico from var-lib-calico (rw)
/var/run/calico from var-run-calico (rw)
/var/run/nodeagent from policysync (rw)
/var/run/secrets/kubernetes.io/serviceaccount from calico-node-token-tx4jt (ro)
Conditions:
Type Status
Initialized True
Ready False
ContainersReady False
PodScheduled True
Volumes:
lib-modules:
Type: HostPath (bare host directory volume)
Path: /lib/modules
HostPathType:
var-run-calico:
Type: HostPath (bare host directory volume)
Path: /var/run/calico
HostPathType:
var-lib-calico:
Type: HostPath (bare host directory volume)
Path: /var/lib/calico
HostPathType:
xtables-lock:
Type: HostPath (bare host directory volume)
Path: /run/xtables.lock
HostPathType: FileOrCreate
cni-bin-dir:
Type: HostPath (bare host directory volume)
Path: /opt/cni/bin
HostPathType:
cni-net-dir:
Type: HostPath (bare host directory volume)
Path: /etc/cni/net.d
HostPathType:
host-local-net-dir:
Type: HostPath (bare host directory volume)
Path: /var/lib/cni/networks
HostPathType:
policysync:
Type: HostPath (bare host directory volume)
Path: /var/run/nodeagent
HostPathType: DirectoryOrCreate
flexvol-driver-host:
Type: HostPath (bare host directory volume)
Path: /usr/libexec/kubernetes/kubelet-plugins/volume/exec/nodeagent~uds
HostPathType: DirectoryOrCreate
calico-node-token-tx4jt:
Type: Secret (a volume populated by a Secret)
SecretName: calico-node-token-tx4jt
Optional: false
QoS Class: Burstable
Node-Selectors: kubernetes.io/os=linux
Tolerations: :NoSchedule
:NoExecute
CriticalAddonsOnly
node.kubernetes.io/disk-pressure:NoSchedule
node.kubernetes.io/memory-pressure:NoSchedule
node.kubernetes.io/network-unavailable:NoSchedule
node.kubernetes.io/not-ready:NoExecute
node.kubernetes.io/pid-pressure:NoSchedule
node.kubernetes.io/unreachable:NoExecute
node.kubernetes.io/unschedulable:NoSchedule
Events:
Type Reason Age From Message
---- ------ ---- ---- -------
Normal Scheduled 2m11s default-scheduler Successfully assigned kube-system/calico-node-9sxj2 to master
Normal Pulled 2m8s kubelet, master Container image "calico/cni:v3.14.2" already present on machine
Normal Created 2m7s kubelet, master Created container upgrade-ipam
Normal Started 2m7s kubelet, master Started container upgrade-ipam
Normal Pulled 2m6s kubelet, master Container image "calico/cni:v3.14.2" already present on machine
Normal Created 2m5s kubelet, master Created container install-cni
Normal Started 2m4s kubelet, master Started container install-cni
Normal Pulled 2m2s kubelet, master Container image "calico/pod2daemon-flexvol:v3.14.2" already present on machine
Normal Created 2m1s kubelet, master Created container flexvol-driver
Normal Started 2m kubelet, master Started container flexvol-driver
Normal Pulled 119s kubelet, master Container image "calico/node:v3.14.2" already present on machine
Normal Created 119s kubelet, master Created container calico-node
Normal Started 118s kubelet, master Started container calico-node
Warning DNSConfigForming 117s (x7 over 2m11s) kubelet, master Nameserver limits were exceeded, some nameservers have been omitted, the applied nameserver line is: 1.1.1.1 8.8.8.8 1.0.0.1
Warning Unhealthy 108s kubelet, master Readiness probe failed: 2020-09-04 08:33:32.019 [INFO][613] confd/health.go 177: Number of node(s) with BGP peering established = 0
calico/node is not ready: felix is not ready: readiness probe reporting 503
Warning Unhealthy 99s kubelet, master Readiness probe failed: 2020-09-04 08:33:41.822 [INFO][1148] confd/health.go 177: Number of node(s) with BGP peering established = 0
calico/node is not ready: felix is not ready: readiness probe reporting 503
Warning Unhealthy 89s kubelet, master Readiness probe failed: 2020-09-04 08:33:51.811 [INFO][1860] confd/health.go 177: Number of node(s) with BGP peering established = 0
calico/node is not ready: felix is not ready: readiness probe reporting 503
Warning Unhealthy 79s kubelet, master Readiness probe failed: 2020-09-04 08:34:01.827 [INFO][2489] confd/health.go 177: Number of node(s) with BGP peering established = 0
calico/node is not ready: felix is not ready: readiness probe reporting 503
Warning Unhealthy 69s kubelet, master Readiness probe failed: 2020-09-04 08:34:11.822 [INFO][3188] confd/health.go 177: Number of node(s) with BGP peering established = 0
calico/node is not ready: felix is not ready: readiness probe reporting 503
Warning Unhealthy 59s kubelet, master Readiness probe failed: 2020-09-04 08:34:21.808 [INFO][3834] confd/health.go 177: Number of node(s) with BGP peering established = 0
calico/node is not ready: felix is not ready: readiness probe reporting 503
root@intel-x86-64:~#
root@intel-x86-64:~# ifconfig
cali7738dca29c6: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1440
inet6 fe80::ecee:eeff:feee:eeee prefixlen 64 scopeid 0x20<link>
ether ee:ee:ee:ee:ee:ee txqueuelen 0 (Ethernet)
RX packets 1340 bytes 97072 (94.7 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 701 bytes 262242 (256.0 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
calib7f8a711849: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1440
inet6 fe80::ecee:eeff:feee:eeee prefixlen 64 scopeid 0x20<link>
ether ee:ee:ee:ee:ee:ee txqueuelen 0 (Ethernet)
RX packets 182 bytes 18863 (18.4 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 223 bytes 112608 (109.9 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
calie67216465b7: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1440
inet6 fe80::ecee:eeff:feee:eeee prefixlen 64 scopeid 0x20<link>
ether ee:ee:ee:ee:ee:ee txqueuelen 0 (Ethernet)
RX packets 1337 bytes 96865 (94.5 KiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 701 bytes 262284 (256.1 KiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
docker0: flags=4099<UP,BROADCAST,MULTICAST> mtu 1500
inet 172.17.0.1 netmask 255.255.0.0 broadcast 172.17.255.255
ether 02:42:7a:87:b9:1a txqueuelen 0 (Ethernet)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
eth2: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500
inet 128.224.178.51 netmask 255.255.254.0 broadcast 128.224.179.255
inet6 fe80::215:17ff:feac:168 prefixlen 64 scopeid 0x20<link>
ether 00:15:17:ac:01:68 txqueuelen 1000 (Ethernet)
RX packets 359073 bytes 467753818 (446.0 MiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 62386 bytes 18944736 (18.0 MiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
device memory 0xb1a20000-b1a3ffff
lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536
inet 127.0.0.1 netmask 255.0.0.0
inet6 ::1 prefixlen 128 scopeid 0x10<host>
loop txqueuelen 1000 (Local Loopback)
RX packets 347986 bytes 140407921 (133.9 MiB)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 347986 bytes 140407921 (133.9 MiB)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
tunl0: flags=193<UP,RUNNING,NOARP> mtu 1440
inet 10.244.219.64 netmask 255.255.255.255
tunnel txqueuelen 1000 (IPIP Tunnel)
RX packets 0 bytes 0 (0.0 B)
RX errors 0 dropped 0 overruns 0 frame 0
TX packets 0 bytes 0 (0.0 B)
TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0
root@intel-x86-64:~#
root@intel-x86-64:~# kubectl logs -n kube-system calico-node-9sxj2
the output info has been attached as calico-node.log
1) setup.sh
./wrlinux-x/setup.sh --dl-layers --all-layers --templates feature/kubernetes
2) bitbake wrlinux-image-std
3) boot the target from sd card
4) on target:
a)
cat > /etc/docker/daemon.json <<EOF
{
"exec-opts": ["native.cgroupdriver=systemd"]
}
EOF
systemctl daemon-reload
systemctl restart docker
b)
swapoff -a
kubeadm config images pull
kubeadm init --apiserver-advertise-address <target_ip> --pod-network-cidr=10.244.0.0/16 --kubernetes-version=v1.18.8
c)
get calico.yaml from https://docs.projectcalico.org/v3.14/manifests/calico.yaml
d)
modify the calico.yaml to add two line as below
.............
# Cluster type to identify the deployment type
- name: CLUSTER_TYPE
value: "k8s,bgp"
- name: IP_AUTODETECTION_METHOD
value: "interface=eth2"
# Auto-detect the BGP IP address.
- name: IP
value: "autodetect"
.............
calico.yaml as has been attached
e)
kubectl apply -f calico.yaml
f)
check kubernets node and pod status as described