【Docker】Linux升级

删除旧版本

shell 复制代码
yum remove docker  docker-common docker-selinux docker-engine

安装须要的软件包

shell 复制代码
yum install -y yum-utils device-mapper-persistent-data lvm2

设置Docker yum源

shell 复制代码
yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo

查看全部仓库中全部docker版本

能够查看全部仓库中全部docker版本,并选择特定的版本安装。

shell 复制代码
yum list docker-ce --showduplicates | sort -r

安装docker

shell 复制代码
#因为repo中默认只开启stable仓库,故这里安装的是最新稳定版25.0.3-1.el7
yum install docker-ce

#若是要安装特定版本:
yum install docker-ce-25.0.3-1.el7

启动

设置为开机启动

shell 复制代码
systemctl enable docker

启动

shell 复制代码
systemctl start docker

查看启动状态

shell 复制代码
systemctl status docker

查看版本

shell 复制代码
docker version
相关推荐
yc_12241 小时前
用 Visual Studio 远程调试 Linux:从零到流畅的完整指南
linux·ide·visual studio
计算机安禾2 小时前
【Linux从入门到精通】第31篇:防火墙漫谈——iptables与firewalld防护指南
linux·运维·php
下一页盛夏花开2 小时前
ubuntu 20中安装QT以后出现红色空心断点
linux·运维·ubuntu
sanshanjianke2 小时前
Thunderobot 911ME 笔记本 Linux 风扇控制研究
linux
Nice_Fold3 小时前
Kubernetes DaemonSet、StatefulSet与Service(自用笔记)
笔记·容器·kubernetes
fengyehongWorld5 小时前
TeraTerm ttl脚本登录wsl
linux·teraterm
乌托邦的逃亡者6 小时前
Linux中如何检测IP冲突
linux·运维·tcp/ip
一曦的后花园6 小时前
linux搭建promethes并对接node-exporter指标
linux·运维·服务器
乌托邦的逃亡者6 小时前
CentOS/Openeuler主机中,为一个网卡设置多个IP地址
linux·运维·网络·tcp/ip·centos