当前位置: 首页 > 工具软件 > NetSet > 使用案例 >

/proc/sys/net/ipv4/ip_forward contents are not set to 1

诸修伟
2023-12-01

问题描述:master主节点初始化报错
[root@harbor01 ~]# kubeadm init --config kubeadm-config.yaml
W0311 17:15:57.116061 8185 validation.go:28] Cannot validate kube-proxy config - no validator is available
W0311 17:15:57.116107 8185 validation.go:28] Cannot validate kubelet config - no validator is available
[init] Using Kubernetes version: v1.17.3
[preflight] Running pre-flight checks
[WARNING IsDockerSystemdCheck]: detected “cgroupfs” as the Docker cgroup driver. The recommended driver is “systemd”. Please follow the guide at https://kubernetes.io/docs/setup/cri/
error execution phase preflight: [preflight] Some fatal errors occurred:
[ERROR FileContent–proc-sys-net-ipv4-ip_forward]: /proc/sys/net/ipv4/ip_forward contents are not set to 1
[preflight] If you know what you are doing, you can make a check non-fatal with --ignore-preflight-errors=...
To see the stack trace of this error execute with --v=5 or higher
处理方法:echo 1 > /proc/sys/net/ipv4/ip_forward
 

 类似资料: