Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How to install Docker on CentOS 8.1

2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Servers >

Share

Shulou(Shulou.com)06/01 Report--

How to install Docker on CentOS 8.1? I believe many inexperienced people don't know what to do about it. Therefore, this article summarizes the causes and solutions of the problem. Through this article, I hope you can solve this problem.

Downloaded CentOS 8.1 and tried to install docker.

We will learn how to install and run Docker CE on CentOS 8.1 using the official Docker repository.

What is Docker?

Docker is an open source project that allows applications to be created and distributed within containers, which are standardized environments that can be easily replicated independently of the host system.

Add a Docker repository

First, we must add an external repository to get the Docker CE. We will use the official Docker CE CentOS repository.

Installation steps:

Download repo for docker-ce

$curl https://download.docker.com/linux/centos/docker-ce.repo-o / etc/yum.repos.d/docker-ce.repo% Total% Received% Xferd Average Speed Time Current Dload Upload Total Spent Left Speed100 2424 2424 00 2669 0 -::-2666

Install dependencies (this is a key step compared to CentOS 7)

$yum install https://download.docker.com/linux/Fedora/30/x86_64/stable/Packages/containerd.io-1.2.6-3.3.fc30.x86_64.rpmDocker CE Stable-x86 December 64 9.3 kB/s | 22 kB 00:02 Last metadata expiration check: before 0:00:01, executed on Sunday, April 19, 2020 at 05:23:13. Containerd.io-1.2.6-3.3.fc30.x86_64.rpm 544 kB/s | 21 MB 00:40 dependency resolved. = package architecture version repository size = install: containerd.io x86room64 1.2.6-3.3.fc30 @ commandline 21 M replace runc.x86_64 1.0.0-64.rc9.module_el8.1.0+272+3e64ee36 transaction summary = install 1 package total: 21 M are you sure? [y/N]: y

Install docker-ce

$yum install docker-ce Last metadata expiration check: before 0:01:42, performed at 05:23:13 on Sunday, April 19, 2020. Dependency resolution. = package architecture version repository size = installation: docker-ce x86 "64 3libcgroup 19.03.8-3.el7 docker-ce-stable 25m installation dependency: libcgroup x86" 64 0.41-19.el8 base 70 k docker-ce-cli X86141 19.03.8-3.el7 docker-ce-stable 40m transaction Summary = install 3 package Total download: 64m installation size: 273m are you sure? [y/N]: y

Start docker

$systemctl start docker

We can check whether the service is running properly with the following command:

$systemctl status docker ● docker.service-Docker Application Container Engine Loaded: loaded (/ usr/lib/systemd/system/docker.service; disabled; vendor pre > Active: active (running) since Sun 2020-04-19 05:28:15 EDT 8min ago Docs: https://docs.docker.com Main PID: 60217 (dockerd) Tasks: 15 Memory: 195.9m CGroup: / system.slice/docker.service ├─ 60217 / usr/bin/dockerd-H fd://-- containerd=/run/containerd/conta > └─ 60528 / usr/bin/docker-proxy-proto tcp-host-ip 0.0.0.0-host-port >

At this point, Docker is only installed successfully.

After reading the above, have you mastered how to install Docker on CentOS 8.1? If you want to learn more skills or want to know more about it, you are welcome to follow the industry information channel, thank you for reading!

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.

Share To

Servers

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report