docker 安装 及 Job for docker.service failed because the control process exited with error code. See "systemctl status docker.service" and "journalctl -xe" for details.报错
安装Docker
1.查看内核版本 <Docker 要求 CentOS 系统的内核版本高于 3.10>
uname -r <内核版本: 3.10.0-327.el7.x86_64>
2.把yum包更新到最新
yum update
3.安装需要的软件包, yum-util 提供yum-config-manager功能,另外两个是devicemapper驱动依赖的
yum install -y yum-utils device-mapper-persistent-data lvm2
4.设置yum源
yum-config-manager --add-repo https://download.docker.com/linux/centos/docker-ce.repo
5.查看仓库中docker版本
yum list docker-ce --showduplicates | sort -r
6. 安装docker
yum install docker-ce
7.启动Docker,设置开机启动,停止Docker
systemctl start docker
systemctl enable docker
systemctl stop docker
Job for docker.service failed because the control process exited with error code. See "systemctl status docker.service" and "journalctl -xe" for details.
修改 以下两个文件
vi /etc/docker/daemon.json
{ "storage-driver": "devicemapper" }
vi etc/sysconfig/docker-storage
DOCKER_STORAGE_OPTIONS="--selinux-enabled --log-driver=journald --signature-verification=false"