搭建基于Ubuntu的k8s单主节点

本文档详细介绍了如何在Ubuntu系统上搭建一个包含一个主节点和一个从节点的Kubernetes(k8s)集群。首先,确保满足至少2GB内存和2核CPU的硬件要求,并打开必要的端口。接着,安装docker和kubeadm、kubelet、kubectl组件。然后,拉取所需的镜像,并使用kubeadm初始化集群,指定版本以解决版本查询问题。最后,安装flannel网络插件并启动集群,同时提供了查看网络组件的方法和故障排查指南。
摘要由CSDN通过智能技术生成

不指定版本默认安装最新版,一个主节点和一个从节点
以下是官方搭建环境要求,大概意思需要2核2G配置,相关端口不要被占用

Installing kubeadm
One or more machines running one of:
Ubuntu 16.04+
Debian 9
CentOS 7
RHEL 7
Fedora 25/26 (best-effort)
HypriotOS v1.0.1+
Container Linux (tested with 1800.6.0)
2 GB or more of RAM per machine (any less will leave little room for your apps)
2 CPUs or more
Full network connectivity between all machines in the cluster (public or private network is fine)
Unique hostname, MAC address, and product_uuid for every node. See here for more details.
Certain ports are open on your machines. See here for more details.
Swap disabled. You MUST disable swap in order for the kubelet to work properly
Verify the MAC address and product_uuid are unique for every node
Check required ports
Master node(s)
Protocol Direction Port Range Purpose Used By
TCP Inbo

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值