安装docker1.10

1.安装
关闭 /etc/selinux/config
# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
#     enforcing - SELinux security policy is enforced.
#     permissive - SELinux prints warnings instead of enforcing.
#     disabled - No SELinux policy is loaded.
SELINUX=disabled
# SELINUXTYPE= can take one of three two values:
#     targeted - Targeted processes are protected,
#     minimum - Modification of targeted policy. Only selected processes are protected. 
#     mls - Multi Level Security protection.
SELINUXTYPE=targeted
装 yum -y install docker  centos7
装 yum -y install docker-engine  centos6
2.启动
为啥安装完启动失败 yum -y install docker
[root@CentOS7 ~]# service docker start
Redirecting to /bin/systemctl start  docker.service
Job for docker.service failed because the control process exited with error code. See "systemctl status docker.service" and "journalctl -xe" for details.
A:yum remove docker
   yum remove docker-selinux
vi  /etc/yum.repos.d/docker.repo
[dockerrepo]
name=Docker Repository
baseurl=https://yum.dockerproject.org/repo/main/centos/$releasever/
enabled=1
gpgcheck=1
    yum install docker-engine
[root@CentOS7 yum.repos.d]#  service docker start
Redirecting to /bin/systemctl start  docker.service
[root@CentOS7 yum.repos.d]#  docker images
REPOSITORY          TAG                 IMAGE ID            CREATED             SIZE
[root@CentOS7 yum.repos.d]#  docker version
Client:
Version:      1.10.3
 API version:  1.22
 Go version:   go1.5.3
 Git commit:   20f81dd
 Built:        Thu Mar 10 15:39:25 2016
 OS/Arch:      linux/amd64
Server:
 Version:      1.10.3
 API version:  1.22
 Go version:   go1.5.3
 Git commit:   20f81dd
 Built:        Thu Mar 10 15:39:25 2016
 OS/Arch:      linux/amd64
3.卸载
[root@CentOS7 yum.repos.d]# yum list installed | grep docker
docker-engine.x86_64                   1.10.3-1.el7.centos             @dockerrepo
docker-engine-selinux.noarch           1.10.3-1.el7.centos             @dockerrepo
[root@CentOS7 yum.repos.d]# yum -y remove docker-engine.x86_64
Loaded plugins: fastestmirror, langpacks
Resolving Dependencies
--> Running transaction check
---> Package docker-engine.x86_64 0:1.10.3-1.el7.centos will be erased
--> Finished Dependency Resolution
Dependencies Resolved
================================================================================================
 Package                Arch            Version                      Repository            Size
================================================================================================
Removing:
 docker-engine          x86_64          1.10.3-1.el7.centos          @dockerrepo           41 M
Transaction Summary
================================================================================================
Remove  1 Package
Installed size: 41 M
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Erasing    : docker-engine-1.10.3-1.el7.centos.x86_64                                     1/1 
  Verifying  : docker-engine-1.10.3-1.el7.centos.x86_64                                     1/1 
Removed:
  docker-engine.x86_64 0:1.10.3-1.el7.centos                                                    
Complete!
[root@CentOS7 yum.repos.d]# yum -y remove docker-engine-selinux.noarch
Loaded plugins: fastestmirror, langpacks
Resolving Dependencies
--> Running transaction check
---> Package docker-engine-selinux.noarch 0:1.10.3-1.el7.centos will be erased
--> Finished Dependency Resolution
Dependencies Resolved
================================================================================================
 Package                      Arch          Version                    Repository          Size
================================================================================================
Removing:
 docker-engine-selinux        noarch        1.10.3-1.el7.centos        @dockerrepo         43 k
Transaction Summary
================================================================================================
Remove  1 Package
Installed size: 43 k
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Erasing    : docker-engine-selinux-1.10.3-1.el7.centos.noarch                             1/1 
  Verifying  : docker-engine-selinux-1.10.3-1.el7.centos.noarch                             1/1 
Removed:
  docker-engine-selinux.noarch 0:1.10.3-1.el7.centos                                            
Complete!

 

转载于:https://www.cnblogs.com/dongdongwq/p/5381752.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值