温馨提示×

温馨提示×

您好,登录后才能下订单哦!

密码登录×
登录注册×
其他方式登录
点击 登录注册 即表示同意《亿速云用户服务条款》

RedHat7.4安装Docker的步骤

发布时间:2021-08-22 13:45:03 来源:亿速云 阅读:233 作者:chen 栏目:建站服务器

这篇文章主要讲解了“RedHat7.4安装Docker的步骤”,文中的讲解内容简单清晰,易于学习与理解,下面请大家跟着小编的思路慢慢深入,一起来研究和学习“RedHat7.4安装Docker的步骤”吧!


操作系统版本:

  1. Red Hat Enterprise Linux Server release 7.4 (Maipo)

添加yum源:

  1. vi /etc/yum.repos.d/docker.repo


[dockerrepo]
name=Docker Repository
baseurl=http://yum.dockerproject.org/repo/main/centos/7/
enabled=1
gpgcheck=0

安装:

  1. yum install docker-engine -y

启动Docker服务:

  1. systemctl start docker

检查是否安装成功:

  1. [root@ip-172-31-29-22 yum.repos.d]# docker version
    Client:
     Version:      17.05.0-ce
     API version:  1.29
     Go version:   go1.7.5
     Git commit:   89658be
     Built:        Thu May  4 22:06:25 2017
     OS/Arch:      linux/amd64


    Server:
     Version:      17.05.0-ce
     API version:  1.29 (minimum version 1.12)
     Go version:   go1.7.5
     Git commit:   89658be
     Built:        Thu May  4 22:06:25 2017
     OS/Arch:      linux/amd64
     Experimental: false

查看Docker容器总体状况

  1. [root@ip-172-31-29-22 yum.repos.d]# docker info

  2. Containers: 0

  3.  Running: 0

  4.  Paused: 0

  5.  Stopped: 0

  6. Images: 0

  7. Server Version: 17.05.0-ce

  8. Storage Driver: overlay

  9.  Backing Filesystem: xfs

  10.  Supports d_type: true

  11. Logging Driver: json-file

  12. Cgroup Driver: cgroupfs

  13. Plugins:

  14.  Volume: local

  15.  Network: bridge host macvlan null overlay

  16. Swarm: inactive

  17. Runtimes: runc

  18. Default Runtime: runc

  19. Init Binary: docker-init

  20. containerd version: 9048e5e50717ea4497b757314bad98ea3763c145

  21. runc version: 9c2d8d184e5da67c95d601382adf14862e4f2228

  22. init version: 949e6fa

  23. Security Options:

  24.  seccomp

  25.   Profile: default

  26. Kernel Version: 3.10.0-693.11.6.el7.x86_64

  27. Operating System: Red Hat Enterprise Linux Server 7.4 (Maipo)

  28. OSType: linux

  29. Architecture: x86_64

  30. CPUs: 1

  31. Total Memory: 990.8MiB

  32. Name: ip-172-31-29-22.ap-northeast-1.compute.internal

  33. ID: 6C4S:W4VA:MSIK:TGZC:BHYU:3AHR:FJX7:44SO:467J:4ZNL:7T67:3GYK

  34. Docker Root Dir: /var/lib/docker

  35. Debug Mode (client): false

  36. Debug Mode (server): false

  37. Registry: https://index.docker.io/v1/

  38. Experimental: false

  39. Insecure Registries:

  40.  127.0.0.0/8

  41. Live Restore Enabled: false

设置开机自动启动:
        1.默认是非开机自启的

  1. [root@ip-172-31-29-22 yum.repos.d]# systemctl is-enabled docker

  2. disabled

        2.设置开机启动

  1. systemctl enable docker

感谢各位的阅读,以上就是“RedHat7.4安装Docker的步骤”的内容了,经过本文的学习后,相信大家对RedHat7.4安装Docker的步骤这一问题有了更深刻的体会,具体使用情况还需要大家实践验证。这里是亿速云,小编将为大家推送更多相关知识点的文章,欢迎关注!

向AI问一下细节

免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。

AI