新闻动态
新闻动态
NEWS INFORMATION

Linux系统 Centos7.4手动在线升级到Centos7.7

发布日期:2022-07-15 19:43 | 文章来源:CSDN

Kubernetes部署要求Centos7.5以上版本,否则会出现kubelet无法启动、harbor端口访问异常等问题(同时要求内核版本要升级到4.4.x以上)。

1)查看当前centos系统版本和内核版本

[root@k8s-vm01 ~]# cat /etc/redhat-release
CentOS Linux release 7.4.1902 (Core)
  
[root@k8s-vm01 ~]# uname -r

2)备份原来的CentOS-Base.repo

[root@k8s-vm01 ~]# cd /etc/yum.repos.d/
[root@k8s-vm01 yum.repos.d]# cp CentOS-Base.repo CentOS-Base.repo_bak

3)修改yum源。

要保证更换的yum源地址可以正常访问。如下使用阿里云的yum源http://mirrors.aliyun.com/centos/7.7.1908,要保证手动打开这个地址是有效地址,且镜像yum源内容完整存在。

[root@k8s-vm01 yum.repos.d]# cat /etc/yum.repos.d/CentOS-Base.repo
[base]
name=CentOS-$releasever
enabled=1
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos/7.7.1908/os/$basearch/
gpgcheck=1
gpgkey=http://mirrors.cloud.aliyuncs.com/centos/RPM-GPG-KEY-CentOS-7
[updates]
name=CentOS-$releasever
enabled=1
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos/7.7.1908/updates/$basearch/
gpgcheck=1
gpgkey=http://mirrors.aliyun.com/centos/RPM-GPG-KEY-CentOS-7
[extras]
name=CentOS-$releasever
enabled=1
failovermethod=priority
baseurl=http://mirrors.aliyun.com/centos/7.7.1908/extras/$basearch/
gpgcheck=1
gpgkey=http://mirrors.aliyun.com/centos/RPM-GPG-KEY-CentOS-7

4)执行更新yum

确保下面更新操作没有报错。

[root@k8s-vm01 yum.repos.d]# yum update -y

5)重启系统

[root@k8s-vm01 yum.repos.d]# init 6

重启后查看系统版本

[root@k8s-vm01 ~]# cat /etc/redhat-release
CentOS Linux release 7.7.1908 (Core)

更多关于Centos手动升级的文章请查看下面的相关链接

海外稳定服务器

版权声明:本站文章来源标注为YINGSOO的内容版权均为本站所有,欢迎引用、转载,请保持原文完整并注明来源及原文链接。禁止复制或仿造本网站,禁止在非www.yingsoo.com所属的服务器上建立镜像,否则将依法追究法律责任。本站部分内容来源于网友推荐、互联网收集整理而来,仅供学习参考,不代表本站立场,如有内容涉嫌侵权,请联系alex-e#qq.com处理。

实时开通

自选配置、实时开通

免备案

全球线路精选!

全天候客户服务

7x24全年不间断在线

专属顾问服务

1对1客户咨询顾问

在线
客服

在线客服:7*24小时在线

客服
热线

400-630-3752
7*24小时客服服务热线

关注
微信

关注官方微信
顶部
请您留言

YINGSOO400-630-3752

提交