1.软文推荐

2.软文推荐

3.软文推荐

本篇文章重点为大家讲解一下Linux下使用二进制文件的方式安装docker具体步骤,有需要的小伙伴可以参考一下。

1,下载二进制文件
https://download.docker.com/linux/static/stable/x86_64/docker-18.03.1-ce.tgz
2,解压二进制文件
tar xzvf docker-18.03.1-ce.tgz
3,复制二进制文件到/usr/bin目录下
cp docker/* /usr/bin/
4,检查是否安装
docker version
Client:
Version:      18.03.1-ce
API version:  1.37
Go version:   go1.9.2
Git commit:   9ee9f40
Built:        Thu Apr 26 07:12:25 2018
OS/Arch:      linux/amd64
Experimental: false
Orchestrator: swarm

Server:
Engine:
Version:      18.03.1-ce
API version:  1.37 (minimum version 1.12)
Go version:   go1.9.5
Git commit:   9ee9f40
Built:        Thu Apr 26 07:23:03 2018
OS/Arch:      linux/amd64
Experimental: false
5,配置 docker.service文件
vi /usr/lib/systemd/system/docker.service

[Unit]
Description=Docker Application Container Engine
Documentation=https://docs.docker.com
After=network-online.target firewalld.service
Wants=network-online.target

[Service]
Type=notify
ExecStart=/usr/bin/dockerd
ExecReload=/bin/kill -s HUP $MAINPID
LimitNOFILE=infinity
LimitNPROC=infinity
TimeoutStartSec=0
Delegate=yes
KillMode=process
Restart=on-failure
StartLimitBurst=3
StartLimitInterval=60s

[Install]
WantedBy=multi-user.target
6,启动dockerd服务进程
systemctl daemon-reload
systemctl start docker.service
7,检验
# ps aux|grep docker
root 2262 0.1 4.4 472948 44944 ? Ssl 16:38 0:00 /usr/bin/dockerd
root 2266 0.2 1.3 277032 13540 ? Ssl 16:38 0:01 docker-containerd --config /var/run/docker/containerd/containerd.toml
root 2895 0.0 0.0 112660 972 pts/0 S+ 16:48 0:00 grep --color=auto docker
# docker run hello-world

Hello from Docker!
This message shows that your installation appears to be working correctly.

To generate this message, Docker took the following steps:
1. The Docker client contacted the Docker daemon.
2. The Docker daemon pulled the "hello-world" image from the Docker Hub.
(amd64)
3. The Docker daemon created a new container from that image which runs the
executable that produces the output you are currently reading.
4. The Docker daemon streamed that output to the Docker client, which sent it
to your terminal.

To try something more ambitious, you can run an Ubuntu container with:
$ docker run -it ubuntu bash

Share images, automate workflows, and more with a free Docker ID:
https://hub.docker.com/

For more examples and ideas, visit:
https://docs.docker.com/engine/userguide/

本文来源:www.lxlinux.net/4790.html,若引用不当,请联系修改。

相关文章 8

1

电子邮件服务器(电子邮件服务器中的密件抄送指的是) 2分钟前

目录:1、什么是邮件服务器2、电子邮件服务器软件一般安装在哪里3、outlook邮件服务器地址如何设置?4、电子邮件服务器是什么意思 何谓...

2

Linux系统date命令详解 5分钟前

大多数人认为操作系统中的时间并不重要,但是对于管理人员来说时间非常重要,对于一个分布式集群来说时间是至关重要的,下面良许教...

3

详解YARN常用操作 6分钟前

YARN (Yet Another Resource Negotiator,另一种资源协调者)是一 种新的 Hadoop 资源管理器,它是一个通用资源管理系统和调度平台,可为上层应用...

4

阿里云活动中心(阿里云活动中心在哪里) 8分钟前

目录:1、阿里云优惠活动在哪看?2、阿里云云安全中心是什么?可以为我们提供哪些安全保障?3、阿里云隐藏活动分享,你不知道的阿里...

5

Linux永久修改主机名 11分钟前

Linux如何永久修改主机名?Linux系统安装好后,都会有默认的主机名,为了便于使用,我们常常需要修改主机名,下面为大家分享一下Linux永...

6

Linux下安装和使用SQLite3 13分钟前

SQLite3是一种嵌入式数据库,它的数据库就是一个文件。由于SQLite3本身是C写的,而且体积很小,所以,经常被集成到各种应用程序中,甚至...

7

包含ctgnetgia的词条 15分钟前

目录:...

8

Linux常用命令—paste命令 17分钟前

Linux常用命令 paste命令 用于将多个文件按照列队列进行合并,下面良许教程网为大家分享一下Linux常用命令paste命令具体使用方法。 paste 将多...