修改

1
wget https://docs.projectcalico.org/v3.6/getting-started/kubernetes/installation/hosted/kubernetes-datastore/calico-networking/1.7/calico.yaml

vi calico.yaml 增加如下env

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
         env:
            - name: FELIX_USAGEREPORTINGENABLED
              value: "false"
            - name: CALICO_STARTUP_LOGLEVEL
              value: "ERROR"
            - name: FELIX_EARLYLOGSEVERITYSCREEN
              value: "warning"
            - name: FELIX_LOGSEVERITYSCREEN
              value: "warning"
            - name: IP_AUTODETECTION_METHOD
              value: "interface=eth1"
1
2
3
4
# 重启 daemonset
kubectl delete pod -n kube-system -l k8s-app=calico-node
# 查看
kubectl -n kube-system exec $(kubectl -n kube-system get pod -l k8s-app=calico-node --no-headers |grep Running | head -1 | awk '{print $1}') -- /bin/sh -c "env" |grep -E "LOG|USAG"

参考