Please refer to official site for installation  details :  https://docs.docker.com/install/linux/docker-ee/suse/

Example installation for SUSE Linux SP2 12.2 + Docker  17.06.2

1. Prerequisites 

1.1. Get Docker EE URL by Registration , go to: 
  https://store.docker.com/                          sunnydockerid/Netxxxxx1   nbtoronto/Luuu123!@#  

1.2. OS requirements

    1. Linux version should be or higher than 12.x:

 # cat /etc/*release    

b. Firewall Configuration Check :

# systemctl list-unit-files | grep firewall 

Firewall Disabled: Docker creates a DOCKER iptables chain when it starts.

Firewall Enabled: adjust the start-up script order so that the firewall is   started before Docker, and Docker stops before the  firewall stops.

1.3. Uninstall old version: Older versions of Docker were called docker or docker-engine. If you use OS images from a cloud provider, you may need to remove the runc package, which conflicts with Docker EE

$ sudo zypper rm docker docker-ee runc 

$ sudo rpm -e docker-ee 

1.4. Check Filesystem

# cat /proc/filesystems | grep btrfs

btrfs should be listed.

1.5. Configure the Btrfs filesystem

1.5.1. Check file system:

df -T / /var /var/lib /var/lib/docker  

Note: duplicated result if you do not have separate mount point)

#mkdir /var/lib/docker  

Note: The only supported storage driver for Docker EE on SLES is Btrfs,

If the filesystem that hosts /var/lib/docker/ is not a BTRFS filesystem, you must configure a BTRFS filesystem and mount it on /var/lib/docker/.

1.5.2.   Format your dedicated block device or devices as a Btrfs filesystem.

# df –h   

# mkfs.btrfs -f  /dev/sda2  

1.5.3.  Mount the new Btrfs file system on the /var/lib/docker

 #mount -t btrfs /dev/sda2  /var/lib/docker  

 2. Install Docker EE

2.1 Using the repository 

STEP 1:    SET UP THE REPOSITORY

2.1.1.1:  Add a $DOCKER_EE_URL variable into your environment

DOCKER_EE_URL="<DOCKER-EE-URL>/sles/12.3/x86_64/stable-17.06" 

2.1.1.2. set up the stable repository

sudo zypper addrepo $DOCKER_EE_URL docker-ee-stable 

2.1.1.3. Import the GPG key from the repository

sudo rpm --import "<DOCKER-EE-URL>/sles/gpg"

Notes:  please be aware of the value is DOCKER-EE-URL, NOT DOCKER_EE_URL.

STEP 2: INSTALL DOCKER EE

2.1.2.1. Update the zypper package index

sudo zypper refresh  

2.1.2.2. Install the latest version of docker-ee

sudo zypper install docker-ee   

$ sudo docker info 

 

2.1.2.2. install a specific version: List binary packages and is truncated:

$ zypper search -s --match-exact -t package docker-ee

Note:omit the -t package flag from the command to also list source packages

$sudo zypper install docker-ee-<VERSION_STRING>

2.1.2.3.Configure Docker EE to use the Btrfs filesystem.

This is only required if the / filesystem is not using BTRFS.

# /etc/docker/daemon.json (create it if it does not exist) and add the following contents:

{  "storage-driver": "btrfs"}

2.1.3. Start Docker:

$ sudo service docker start 

$ sudo docker info 

 

 

2.1.4. Verify that Docker EE

$ sudo docker run hello-world 

This command downloads a test image and runs it in a container. When the container runs, it prints an informational message and exits.

systemctl status docker.service

NOW YOU HAVE YOUR DOCKER INSTALLED SUCCESSFULLY !!

2.2. From a Package 

2.2.1. Download the .rpm file and install it manually

<url>/sles/12.3/

2.2.2.Import Docker’s official GPG key:

$ sudo rpm --import <DOCKER-EE-URL>/sles/gpg

2.2.3.Install Docker EE

$ sudo zypper install /path/to/package.rpm

Docker EE is installed but not started. The docker group is created, but no users are added to the group.

2.2.4. Edit the file /etc/docker/daemon.json (create it if it does not exist)

{ "storage-driver": "btrfs" }

2.2.5.Start Docker:

$ sudo service docker start

2.2.6.Verify that Docker EE

$ sudo docker run hello-world

This command downloads a test image and runs it in a container. When the container runs, it prints an informational message and exits.

3. Post-installation steps for Linux 

3.1.  Configure Docker to start on boot

$ sudo systemctl enable docker (or upstart)

"Created symlink from /etc/systemd/system/multi-user.target.wants/docker.service to /usr/lib/systemd/system/docker.service."

3.2.  Add user to docker group

$sudo usermod –a -G docker username

4. Uninstall Docker EE 

4.1 Uninstall the Docker EE package

$ sudo zypper rm docker-ee

Delete all images, containers, and volumes on your host:

$ sudo rm –rf /var/lib/docker/*

4.2 Unmount and format the Btrfs filesystem

If you used a separate BTRFS filesystem to host the contents of /var/lib/docker/, you can unmount and format the Btrfs filesystem.

$ sudo unmount /dev/sda2/  /var/lib/docker

4.3 Manually  delete any edited configuration files

e.g  /etc/docker/daemon.json

 

5. Reference

  • Docker overview:
  • About Docker CE

  • About Docker EE

  • Docker EE for Red Hat Enterprise Linux 7.4

  • Docker Installation in SLES SP2

  • Post-installation steps for Linux

Notes:

For ,

"2.2.2.2 Install the latest version of docker-ee

sudo zypper install docker-ee   "

You may encounter below issues:

  • A:

" Failed to mount cd:///?devices=/dev/disk/by-id/ata-VMware_Virtual_IDE_CDROM_Drive_10000000000000000001 on /var/adm/mount/AP_0xxXbHZP: Mounting media failed (mount: no medium found on /dev/sr0)

"

Solution1:

Step 1:  Right click on your vm at home page,  make sure the  two highlighted check boxes and file path is right, then click OK

Step 2: run the command again:

# zypper install docker-ee

Solution 2:

if you are not able to access to  host home page , in the  terminal, run command below :

$ sudo zypper lr –d

$sudo  zypper mr -d -R -p 101 1

Then reinstall docker-ee again:

$sudo zypper install docker-ee

 
  • :  
    If you encounter below error, please check you networking setting:

Solution: In Modify DNS Configuration, select the way the DNS configuration (name servers, search list, the content of the/etc/resolv.conf file) is modified.

Adding the following lines at the end of the file:

search suse

nameserver 192.168.28.212 (modify accord to your host machine)

nameserver 8.8.8.8

Docker installation in sles SP2的更多相关文章

  1. docker installation on ubuntu

    Ubuntu Docker is supported on these Ubuntu operating systems: Ubuntu Xenial 16.04 (LTS) Ubuntu Trust ...

  2. docker installation and usage

    From 一.环境配置的难题 软件开发最大的麻烦事之一,就是环境配置.用户计算机的环境都不相同,你怎么知道自家的软件,能在那些机器跑起来? 用户必须保证两件事:操作系统的设置,各种库和组件的安装.只有 ...

  3. 深入Docker

    深入Docker 作者:ramanallamilli 随着持续交付等新型开发方法的兴起,工程师再也不会凡事靠运气,希望提交代码上去后,它能在未知环境正常运行.我们可以看到业界这样的转变——开发,质量保 ...

  4. Install Docker on Mac OS X(转)

    Install Docker on Mac OS X You can install Docker using Boot2Docker to run docker commands at your c ...

  5. Docker on CentOS for beginners

    Introduction The article will introduce Docker on CentOS. Key concepts Docker Docker is the world's ...

  6. Docker Architecture、Docker Usage

    目录 . 引言 - 为什么要有Docker技术 . Docker简介 . Docker安装.部署.使用 . Docker安全 . Docker底层实现 . Docker网络配置 . Dockerfil ...

  7. Learn Docker

    Learn Docker A Container is to VM today, what VM was to Physical Servers a while ago. The workload s ...

  8. docker install for centos7

    CentOS Docker runs on CentOS 7.X. An installation on other binary compatible EL7 distributions such ...

  9. 我的docker全套流程例子

    本文来自我的github pages博客http://galengao.github.io/ 即www.gaohuirong.cn 摘要: 下文是自己从搭建docker到docker里安装mysql到 ...

随机推荐

  1. luogu2149 [SDOI2009] Dlaxia的路线

    题目大意 在一个无向图中,定义两个点s,t的最短路径子图为一个极大边集,对于该边集内的所有有向边e,总存在一条起点为s,终点为t且经过边e的路径,使得该路径长度为s到t的最短路径长度.现给出一个无向图 ...

  2. Python 34(进程了解)

    一:僵尸进程与孤儿进程 测试程序: 基本概念: 一个进程使用fork创建子进程,如果子进程退出,而父进程并没有调用wait或waitpid获取子进程的状态信息,那么子进程的进程描述符仍然保存在系统中. ...

  3. React新的安装less的方法

    yarn add less less-loader -D yarn eject 在webpack.config.js文件中 const sassRegex = /\.(scss|sass)$/; co ...

  4. CAS配置(1)SSL证书配置

    一.配置源码 源码配置稍后提供 二.系统环境安装 安装JDK配置,版本>=1.7 环境变量配置(参考): JAVA_HOME=C:\Program Files x86)\Java\jdk1.7. ...

  5. 理解java中的ThreadLocal 专题

    ThreadLocal每一印象: public class IncrementWithStaticVariable{ private static int seqNum = 0; public int ...

  6. 代码code设置9.png/9-patch 图片背景后,此view中的TextView等控件显示不正常

    代码code设置9.png/9-patch 图片背景后,此view中的TextView等控件显示不正常 设置 padding=0

  7. .net core2.0 中使用aspectcore实现aop

    一.新建一个web application项目 1.1.添加AspectCore.Extensions.DependencyInjection引用 二.实现AbstractInterceptorAtt ...

  8. 闰年or平年判断

    <script type="text/javascript">var year = prompt("请输入一个年份");if(year!=null) ...

  9. 解决:惠普HP LaserJet Pro M126a MFP 驱动 安装失败,及其它同类打印机失败问题

    注意:如果在 Windows XP 系统下安装出错,请先安装WindowsXP KB971276-v3补丁后再安装装驱动. 下载地址:http://www.dyjqd.com/soft/KB97127 ...

  10. JQ 获取下一个元素和获取下一个元素的[指定]子元素

    <script type="text/javascript"> $(function () { $("#div1").next().addClass ...