当前位置:网站首页>Rancher安装部署及基本使用
Rancher安装部署及基本使用
2022-07-19 08:22:00 【懒人p】
一,安装 Docker
wget https://mirrors.aliyun.com/docker-ce/linux/centos/docker-ce.repo -O /etc/yum.repos.d/docker-ce.repo
yum -y install docker-ce
systemctl enable docker && systemctl start docker
二,安装启动 Rancher
版本说明 - v2.5.15最新稳定版
docker run -d --name=rancher --restart=unless-stopped \
-p 80:80 -p 443:443 \
--privileged \
-v /data/rancher:/var/lib/rancher \
rancher/rancher:v2.5.15
- privileged:可以使我们启动的容器用 root 的方式启动(在 Rancher 2.5 版本以上需要加)
- restart:重启策略,我们配置的是 unless-stopped,表示当容器退出时,便会重新启动容器(除非容器之前就处于停止)
- -v 挂载/data/rancher目录是为了数据持久化
登录 IP+Port(8443)
设置查看密码(2.5.15版本不需要设置)
docker exec -ti <container_id> reset-password
或
docker ps |grep rancher
docker logs fce849440c22 2>&1 | grep "Bootstrap Password:"
三,Rancher 的基本使用。
1》配置 Kubernetes 集群;
- 点击《添加集群》;
- 点击《导入》;
- 设置集群名称;
- 选着导入集群方式,我是自定义的 k8s 集群,所以选择自定义的即可;
- 在集群 master 节点执行命令;
- 看到状态是Active 就表示配置成功了;
#红色三角是因为我一个node节点没起,
#如果状态是 Pending 可以通过以下命令查看原因。
kubectl get pods -n cattle-system
kubectl describe pod <containerd-id> -n cattle-system
kubectl logs pod <containerd-id> -n cattle-system
#如果日志显示正常,那可能是机器内存不够了,添加内存即可。
花里胡哨仪表盘。
点击集群名称,可以查看集群的资源、pod的数量、以及 K8s 组件运行状态。
四,Rancher 官网
持续更新—
边栏推荐
- How to apply neural network model to practice - mathematical modeling case of neural network model
- [solution] the Monaco editor in leetcode cannot be loaded
- 创建文件,文件权限,所有权和粘滞位
- 第十四篇,STM32的CAN总线通信
- Okaleido or get out of the NFT siege, are you optimistic about it?
- Hcia-r & s self use notes (11) VRP file system, system management
- Xiaobai learns MySQL - generated columns function
- Rotation of rectangular coordinate system
- notepad++如何取消空行
- Okaleido或杀出NFT重围,你看好它吗?
猜你喜欢
What network models does neural network include? Basic principles of neural network model
Okaleido或杀出NFT重围,你看好它吗?
Solution to the first game of 2022 Niuke multi school league
VS2017 OpenCV3.4.2 通过Release的版本 源码编译成 x86
powershell和cmd区别
【微信小程序】From表单(88/100)
第十五篇,STM32的SPI串行通信协议
Yunna FSU dynamic loop monitoring unit, what is FSU dynamic loop monitoring unit
2022牛客多校联赛第一场 题解
opencv(12):cv::rectangle学习与代码演示,使用opencv画矩形/矩形框
随机推荐
vulnhub Monitoring: 1
DOM series change element content
Xiaobai learns MySQL - generated columns function
Read the paper: (yolov1) you only look once:unified, real time object detection
DOM系列之改变元素内容
C#入门系列(二十四) -- 密封类和静态类
第十四篇,STM32的CAN总线通信
Digital image processing (Gonzalez) learning Chapter II fundamentals of digital image
IDEA注释模板配置
DOM introduction and acquisition of DOM series
Dynamic ring monitoring module, dynamic ring monitoring module classification
【微信小程序】Button(90/100)
Gamefi industry declines but not out | June report
2022年最新云开发去水印小程序源码
NC93 设计LRU缓存结构
DOM系列之样式属性操作
[wechat applet] checkbox (89/100)
Hcia-r & s self use notes (11) VRP file system, system management
优化案例2:select标量子查询且主查询排序
Methods of querying Oracle11g logs, database audit, record troubleshooting