Linux under docker1.7.1 installation (Yum installation and offline installation) __linux

Source: Internet
Author: User

The following versions of CentOS support Docker:

L CentOS 7 (64-bit)

L CentOS 6.5 (64-bit) or later

To view the system version Directive :

Cat/etc/issue

The use of Docker can refer to the official documentation Note: https://docs.docker.com/v1.9/

1.docker 1.7.1 Installation

There are two installation options available, yum installation and offline installation package installation. 1.1 Yum Mode installation

Install Epel

CentOS built-in Yum command installation is very simple and practical, can automatically help us resolve dependencies, but CentOS built-in yum source of software available less or lower version, usually we need to use a number of Third-party yum source, where you can choose to install two more commonly used and authoritative yum source, Epel or Remi. Install Epel here

Yum Install-y epel-release

Install Docker

CentOS-7 Installation Docker

The Docker package is already included in the default Centos-extras software source, and the installation commands are as follows:

$ sudo yum install Docker

CentOS-6.5 installation Docker-io

In CentOS-6, a system-brought executable application conflicts with the Docker package name, so we renamed Docker's RPM package name Docker-io

Yum Install Docker-io

Docker configuration file path: /etc/sysconfig/docker

Start Docker

# Join Boot

$ sudochkconfig Docker on

#开始运行 Docker Daemon

$ sudoservice Docker Start

#查看状态是否启动成功

$ sudoservice Docker status 1.2 offline installation package installation

Upload the Docker installation package and the required dependencies to the server directory.

Perform the following instructions for the dependency pack installation, and finally install docker1.7.1

RPM-IVH libcgroup-0.40.rc1-23.el6.x86_64.rpm

RPM-IVH lxc-libs-1.0.9-1.el6.x86_64.rpm

RPM-IVH lua-alt-getopt-0.7.0-1.el6.noarch.rpm

RPM-IVH lua-filesystem-1.4.2-1.el6.x86_64.rpm

RPM-IVH lua-lxc-1.0.9-1.el6.x86_64.rpm

RPM-IVH lxc-1.0.9-1.el6.x86_64.rpm

Install Device-mapper-libs, do not install after the start Docker will error (Ignore dependent install)

RPM-IVH device-mapper-libs-1.02.117-12.el6.x86_64.rpm--force--nodeps

Start Docker

# Join Boot

$ sudo chkconfig docker on

#开始运行 Docker Daemon

$ sudo service docker start

#查看状态是否启动成功1.3 Installation Issues

1. After starting to view the status found not started successfully, display Docker dead

View Docker version number, including client, server, dependent go and so on display cannot connect Docker demo

Resolve: Debug mode start Docker found the following error

Should be libmapper related, need to upgrade this library:

Yum-config-manager--enable Public_ol6_latest

Yum Install Device-mapper-event-libs

Restart Docker Demo

$ sudo service docker restart

 

 

Note : The bottom of the firewall in CentOS is to use iptables for data filtering, based on iptables, which may conflict with Docker. When the FIREWALLD is started or restarted, the Docker rule will be removed from the iptables, thus affecting the normal work of Docker.

When you are using SYSTEMD, FIREWALLD will start before Docker, but if you start or reboot Firewalld after Docker startup, you will need to restart the Docker process.

docker1.7.1 offline installation package and all dependent download addresses: http://download.csdn.net/download/sammory/10172062

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.