In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >
Share
Shulou(Shulou.com)06/01 Report--
This article shows you how to use yum to install Docker in CentOS7. The content is concise and easy to understand. It will definitely brighten your eyes. I hope you can get something through the detailed introduction of this article.
CentOS7 is used here, and the kernel version is
[root@localhost] # uname-r3.10.0-327.el7.x86_64
In this version, the source configured with yum is Ali's mirror source. For specific configuration methods, please see Ali Mirror Source configuration method.
In order to install and upgrade Docker conveniently, configure the yum source of Docker as shown in the official Docker documentation. For more information, please see the CentOS docker yum source configuration method https://docs.docker.com/v1.13/engine/installation/linux/centos/
After configuring the yum source, you can obtain the installable docker version through the list command of yum
[root@localhost ~] # yum list docker-- showduplicates | sort-r * updates: mirrors.aliyun.comLoading mirror speeds from cached hostfileLoaded plugins: fastestmirror Priorities * extras: mirrors.aliyun.com * epel: mirrors.aliyun.comdocker.x86_64 2v 1.12.6-28.git1398f24.el7.centos extrasdocker.x86_64 2v 1.12.6-16.el7.centos extrasdocker.x86_64 2v 1.12.6-11.el7.centos extrasdocker.x86_64 2v 1.12.5-14.el7.centos Extrasdocker.x86_64 2base 1.10.3-59.el7.centos extras * base: mirrors.aliyun.comAvailable Packages [root@localhost ~] # yum list docker-engine.x86_64-- showduplicates | sort-r * updates: mirrors.aliyun.comLoading mirror speeds from cached hostfileLoaded plugins: fastestmirror PrioritiesInstalled Packages * extras: mirrors.aliyun.com * epel: mirrors.aliyun.comdocker-engine.x86_64 1.9.1-1.el7.centos docker-main docker-engine.x86_64 1.9.0-1.el7.centos docker-main docker-engine.x86_64 1.8.3-1.el7.centos docker-main docker-engine.x86_64 1.8.2-1.el7.centos Docker-main docker-engine.x86_64 1.8.1-1.el7.centos docker-main docker-engine.x86_64 1.8.0-1.el7.centos docker-main docker-engine.x86_64 1.7.1-1.el7.centos docker-main docker-engine.x86_64 17.05.0.ce-1.el7.centos docker-main docker-engine.x86_ 64 17.04.0.ce-1.el7.centos docker-main docker-engine.x86_64 17.03.1.ce-1.el7.centos docker-main docker-engine.x86_64 17.03.0.ce-1.el7.centos docker-main docker-engine.x86_64 1.7.0-1.el7.centos docker-main docker-engine.x86_64 1.13.1- 1.el7.centos docker-maindocker-engine.x86_64 1.13.1-1.el7.centos @ docker-maindocker-engine.x86_64 1.13.0-1.el7.centos docker-maindocker-engine.x86_64 1.12.6-1.el7.centos docker-maindocker-engine.x86_64 1.12.5-1.el7.centos docker-main Docker-engine.x86_64 1.12.4-1.el7.centos docker-main docker-engine.x86_64 1.12.3-1.el7.centos docker-main docker-engine.x86_64 1.12.2-1.el7.centos docker-main docker-engine.x86_64 1.12.1-1.el7.centos docker-main docker-engine.x86_64 1.12 .0-1.el7.centos docker-main docker-engine.x86_64 1.11.2-1.el7.centos docker-main docker-engine.x86_64 1.11.1-1.el7.centos docker-main docker-engine.x86_64 1.11.0-1.el7.centos docker-main docker-engine.x86_64 1.10.3-1.el7.centos Docker-main docker-engine.x86_64 1.10.2-1.el7.centos docker-main docker-engine.x86_64 1.10.1-1.el7.centos docker-main docker-engine.x86_64 1.10.0-1.el7.centos docker-main * base: mirrors.aliyun.comAvailable Packages
As can be seen from the above two paragraphs, the name of the docker installation package in the Ali Cloud mirror source is not the same as the installation package officially provided by docker, so when using yum installation, you will probably only find the first paragraph of the result. Although the official source of docker is configured, the latest docker version cannot be searched. It is important to note that if you want to upgrade docker using the installation package from docker's official source, provide the name of the installation package docker-engine so that you can find the various versions of docker.
V1.13 is selected here for installation.
If you previously installed docker (generally using the installation package from the centos source), be sure to remove the old version. Because I installed v1.12 version before, v1.13 version has a lot of changes, if not deleted, there may be unexpected problems.
Delete v1.12 version docker
In addition to its own docker package, this version of docker also has two dependent packages, docker-common and container-linux, which need to be deleted.
[root@localhost ~] # yum erase docker [root@localhost ~] # yum erase docker-common [root@localhost ~] # yum erase container-selinux
Or
[root@localhost ~] # yum remove docker [root@localhost ~] # yum remove docker-common [root@localhost ~] # yum remove container-selinux
Finally install v1.13 version of docker
[root@localhost ~] # yum-y install docker-engine-1.13.1
Start docker and set it to boot
[root@localhost ~] # systemctl start docker [root@localhost ~] # systemctl enable docker
You can view the current docker version through the command
[root@localhost] # docker versionClient: Version: 1.13.1 API version: 1.26 Go version: go1.7.5 Git commit: 092cba3 Built: Wed Feb 8 06:38:28 2017 OS/Arch: linux/amd64Server: Version: 1.13.1 API version: 1.26 (minimum version 1.12) Go version: go1.7.5 Git commit: 092cba3 Built: Wed Feb 8 06:38:28 2017 OS/Arch: linux/amd64 Experimental: false The content is how to install Docker using yum in CentOS7 Have you learned any knowledge or skills? If you want to learn more skills or enrich your knowledge reserve, you are welcome to follow the industry information channel.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.