Docker Community Forums

Share and learn in the Docker community.

How to install latest docker v1.9.x on Amazon linux

amazonwebservices

(Bill Wang) #1

Start a new Amazon linux instance, and docker v1.7.1 has been installed.

But when I try to install docker-engine, I got below error:

[root@ip-172-31-2-127 init.d]# yum info docker-engine
Loaded plugins: priorities, update-motd, upgrade-helper
Available Packages
Name        : docker-engine
Arch        : x86_64
Version     : 1.9.1
Release     : 1.el7.centos
Size        : 8.2 M
Repo        : dockerrepo
Summary     : The open-source application container engine
URL         : https://dockerproject.org
License     : ASL 2.0
Description : Docker is an open source project to build, ship and run any application as a
    : lightweight container.
    :
    : Docker containers are both hardware-agnostic and platform-agnostic. This means
    : they can run anywhere, from your laptop to the largest EC2 compute instance and
    : everything in between - and they don't require you to use a particular
    : language, framework or packaging system. That makes them great building blocks
    : for deploying and scaling web apps, databases, and backend services without
    : depending on a particular stack or provider.

$ yum install docker-engine
...
---> Package m4.x86_64 0:1.4.16-9.10.amzn1 will be installed
---> Package setools-libs.x86_64 0:3.3.7-34.23.amzn1 will be installed
--> Processing Conflict: docker-engine-1.9.1-1.el7.centos.x86_64 conflicts docker-io
--> Processing Conflict: docker-engine-1.9.1-1.el7.centos.x86_64 conflicts docker
--> Finished Dependency Resolution
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
   Requires: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_38)(64bit)
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
   Requires: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_201)(64bit)
Error: docker-engine conflicts with docker-1.7.1-1.9.amzn1.x86_64
Error: Package: docker-engine-selinux-1.9.1-1.el7.centos.noarch (dockerrepo)
   Requires: selinux-policy-targeted >= 3.13.1-23
   Available: selinux-policy-targeted-3.10.0-98.23.amzn1.noarch (amzn-main)
       selinux-policy-targeted = 3.10.0-98.23.amzn1
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
   Requires: systemd-units
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
   Requires: libsystemd-journal.so.0()(64bit)
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
   Requires: selinux-policy >= 3.13.1-23
   Available: selinux-policy-3.10.0-98.23.amzn1.noarch (amzn-main)
       selinux-policy = 3.10.0-98.23.amzn1
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
   Requires: libsystemd-id128.so.0()(64bit)
Error: Package: docker-engine-selinux-1.9.1-1.el7.centos.noarch (dockerrepo)
   Requires: selinux-policy-base >= 3.13.1-23
   Available: selinux-policy-minimum-3.10.0-98.23.amzn1.noarch (amzn-main)
       selinux-policy-base = 3.10.0-98.23.amzn1
   Available: selinux-policy-mls-3.10.0-98.23.amzn1.noarch (amzn-main)
       selinux-policy-base = 3.10.0-98.23.amzn1
   Available: selinux-policy-targeted-3.10.0-98.23.amzn1.noarch (amzn-main)
       selinux-policy-base = 3.10.0-98.23.amzn1
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
   Requires: selinux-policy >= 3.13.1-23
   Installing: selinux-policy-3.10.0-98.23.amzn1.noarch (amzn-main)
       selinux-policy = 3.10.0-98.23.amzn1
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
   Requires: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_196)(64bit)
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
   Requires: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_195)(64bit)
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest
[root@ip-172-31-2-127 init.d]#

(Ranjandas) #2

Hi,

Looks like the new package (docker 1.9) conflicts with the already installed docker-1.7.1-1.9.amzn1.x86_64. You will have to remove this package prior to installing the new docker engine 1.9.

Regards


(Bill Wang) #3

I have removed the old version and still have the same issue.


(Nhanpt14) #4

I’m get the same issue.

Error: Package: docker-engine-selinux-1.9.1-1.el7.centos.noarch (docker-main-repo)
Requires: selinux-policy-targeted >= 3.13.1-23
Installed: selinux-policy-targeted-3.12.1-153.el7_0.13.noarch (@updates)
selinux-policy-targeted = 3.12.1-153.el7_0.13
Available: selinux-policy-targeted-3.12.1-153.el7.noarch (base)
selinux-policy-targeted = 3.12.1-153.el7
Available: selinux-policy-targeted-3.12.1-153.el7_0.10.noarch (updates)
selinux-policy-targeted = 3.12.1-153.el7_0.10
Available: selinux-policy-targeted-3.12.1-153.el7_0.11.noarch (updates)
selinux-policy-targeted = 3.12.1-153.el7_0.11
Available: selinux-policy-targeted-3.12.1-153.el7_0.12.noarch (updates)
selinux-policy-targeted = 3.12.1-153.el7_0.12
Error: Package: docker-engine-selinux-1.9.1-1.el7.centos.noarch (docker-main-repo)
Requires: selinux-policy-base >= 3.13.1-23
Installed: selinux-policy-targeted-3.12.1-153.el7_0.13.noarch (@updates)
selinux-policy-base = 3.12.1-153.el7_0.13
Available: selinux-policy-minimum-3.12.1-153.el7.noarch (base)
selinux-policy-base = 3.12.1-153.el7
Available: selinux-policy-minimum-3.12.1-153.el7_0.10.noarch (updates)
selinux-policy-base = 3.12.1-153.el7_0.10
Available: selinux-policy-minimum-3.12.1-153.el7_0.11.noarch (updates)
selinux-policy-base = 3.12.1-153.el7_0.11
Available: selinux-policy-minimum-3.12.1-153.el7_0.12.noarch (updates)
selinux-policy-base = 3.12.1-153.el7_0.12
Available: selinux-policy-minimum-3.12.1-153.el7_0.13.noarch (updates)
selinux-policy-base = 3.12.1-153.el7_0.13
Available: selinux-policy-mls-3.12.1-153.el7.noarch (base)
selinux-policy-base = 3.12.1-153.el7
Available: selinux-policy-mls-3.12.1-153.el7_0.10.noarch (updates)
selinux-policy-base = 3.12.1-153.el7_0.10
Available: selinux-policy-mls-3.12.1-153.el7_0.11.noarch (updates)
selinux-policy-base = 3.12.1-153.el7_0.11
Available: selinux-policy-mls-3.12.1-153.el7_0.12.noarch (updates)
selinux-policy-base = 3.12.1-153.el7_0.12
Available: selinux-policy-mls-3.12.1-153.el7_0.13.noarch (updates)
selinux-policy-base = 3.12.1-153.el7_0.13
Available: selinux-policy-targeted-3.12.1-153.el7.noarch (base)
selinux-policy-base = 3.12.1-153.el7
Available: selinux-policy-targeted-3.12.1-153.el7_0.10.noarch (updates)
selinux-policy-base = 3.12.1-153.el7_0.10
Available: selinux-policy-targeted-3.12.1-153.el7_0.11.noarch (updates)
selinux-policy-base = 3.12.1-153.el7_0.11
Available: selinux-policy-targeted-3.12.1-153.el7_0.12.noarch (updates)
selinux-policy-base = 3.12.1-153.el7_0.12

Any help?


(Nhanpt14) #5

Try to > yum clean all first.


(Irfuel) #6

Same problem here:

Resolving Dependencies
–> Running transaction check
—> Package docker-engine.x86_64 0:1.9.1-1.el7.centos will be installed
–> Processing Dependency: docker-engine-selinux >= 1.9.1-1.el7.centos for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: selinux-policy >= 3.13.1-23 for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_201)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_196)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_38)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_195)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: systemd-units for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-id128.so.0()(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0()(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Running transaction check
—> Package docker-engine.x86_64 0:1.9.1-1.el7.centos will be installed
–> Processing Dependency: selinux-policy >= 3.13.1-23 for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_201)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_196)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_38)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_195)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: systemd-units for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-id128.so.0()(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0()(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
—> Package docker-engine-selinux.noarch 0:1.9.1-1.el7.centos will be installed
–> Processing Dependency: selinux-policy-base >= 3.13.1-23 for package: docker-engine-selinux-1.9.1-1.el7.centos.noarch
–> Processing Dependency: selinux-policy-targeted >= 3.13.1-23 for package: docker-engine-selinux-1.9.1-1.el7.centos.noarch
–> Processing Dependency: policycoreutils-python for package: docker-engine-selinux-1.9.1-1.el7.centos.noarch
–> Running transaction check
—> Package docker-engine.x86_64 0:1.9.1-1.el7.centos will be installed
–> Processing Dependency: selinux-policy >= 3.13.1-23 for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_201)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_196)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_38)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_195)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: systemd-units for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-id128.so.0()(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0()(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
—> Package docker-engine-selinux.noarch 0:1.9.1-1.el7.centos will be installed
–> Processing Dependency: selinux-policy-base >= 3.13.1-23 for package: docker-engine-selinux-1.9.1-1.el7.centos.noarch
–> Processing Dependency: selinux-policy-targeted >= 3.13.1-23 for package: docker-engine-selinux-1.9.1-1.el7.centos.noarch
—> Package policycoreutils-python.x86_64 0:2.1.12-5.23.amzn1 will be installed
–> Processing Dependency: setools-libs-python(python27) >= 3.3.7-14 for package: policycoreutils-python-2.1.12-5.23.amzn1.x86_64
–> Processing Dependency: audit-libs-python(python27) >= 2.1.3-4 for package: policycoreutils-python-2.1.12-5.23.amzn1.x86_64
–> Processing Dependency: libsemanage-python(python27) >= 2.1.6-3 for package: policycoreutils-python-2.1.12-5.23.amzn1.x86_64
–> Processing Dependency: selinux-policy-devel for package: policycoreutils-python-2.1.12-5.23.amzn1.x86_64
–> Processing Dependency: python27-IPy for package: policycoreutils-python-2.1.12-5.23.amzn1.x86_64
–> Processing Dependency: libselinux-python(python27) for package: policycoreutils-python-2.1.12-5.23.amzn1.x86_64
–> Running transaction check
—> Package audit-libs-python.x86_64 0:2.4.1-5.27.amzn1 will be installed
—> Package docker-engine.x86_64 0:1.9.1-1.el7.centos will be installed
–> Processing Dependency: selinux-policy >= 3.13.1-23 for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_201)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_196)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_38)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_195)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: systemd-units for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-id128.so.0()(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0()(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
—> Package docker-engine-selinux.noarch 0:1.9.1-1.el7.centos will be installed
–> Processing Dependency: selinux-policy-base >= 3.13.1-23 for package: docker-engine-selinux-1.9.1-1.el7.centos.noarch
–> Processing Dependency: selinux-policy-targeted >= 3.13.1-23 for package: docker-engine-selinux-1.9.1-1.el7.centos.noarch
—> Package libselinux-python.x86_64 0:2.1.10-3.22.amzn1 will be installed
—> Package libsemanage-python.x86_64 0:2.1.6-3.13.amzn1 will be installed
—> Package python27-IPy.noarch 0:0.75-1.6.6.amzn1 will be installed
—> Package selinux-policy.noarch 0:3.10.0-98.23.amzn1 will be installed
–> Processing Dependency: m4 for package: selinux-policy-3.10.0-98.23.amzn1.noarch
—> Package setools-libs-python.x86_64 0:3.3.7-34.23.amzn1 will be installed
–> Processing Dependency: setools-libs(x86-64) = 3.3.7-34.23.amzn1 for package: setools-libs-python-3.3.7-34.23.amzn1.x86_64
–> Processing Dependency: libqpol.so.1(VERS_1.4)(64bit) for package: setools-libs-python-3.3.7-34.23.amzn1.x86_64
–> Processing Dependency: libqpol.so.1(VERS_1.5)(64bit) for package: setools-libs-python-3.3.7-34.23.amzn1.x86_64
–> Processing Dependency: libqpol.so.1(VERS_1.2)(64bit) for package: setools-libs-python-3.3.7-34.23.amzn1.x86_64
–> Processing Dependency: libqpol.so.1()(64bit) for package: setools-libs-python-3.3.7-34.23.amzn1.x86_64
–> Running transaction check
—> Package docker-engine.x86_64 0:1.9.1-1.el7.centos will be installed
–> Processing Dependency: selinux-policy >= 3.13.1-23 for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_201)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_196)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_38)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_195)(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: systemd-units for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-id128.so.0()(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
–> Processing Dependency: libsystemd-journal.so.0()(64bit) for package: docker-engine-1.9.1-1.el7.centos.x86_64
—> Package docker-engine-selinux.noarch 0:1.9.1-1.el7.centos will be installed
–> Processing Dependency: selinux-policy-base >= 3.13.1-23 for package: docker-engine-selinux-1.9.1-1.el7.centos.noarch
–> Processing Dependency: selinux-policy-targeted >= 3.13.1-23 for package: docker-engine-selinux-1.9.1-1.el7.centos.noarch
—> Package m4.x86_64 0:1.4.16-9.10.amzn1 will be installed
—> Package setools-libs.x86_64 0:3.3.7-34.23.amzn1 will be installed
–> Finished Dependency Resolution
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
Requires: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_38)(64bit)
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
Requires: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_201)(64bit)
Error: Package: docker-engine-selinux-1.9.1-1.el7.centos.noarch (dockerrepo)
Requires: selinux-policy-targeted >= 3.13.1-23
Available: selinux-policy-targeted-3.10.0-98.23.amzn1.noarch (amzn-main)
selinux-policy-targeted = 3.10.0-98.23.amzn1
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
Requires: systemd-units
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
Requires: libsystemd-journal.so.0()(64bit)
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
Requires: selinux-policy >= 3.13.1-23
Available: selinux-policy-3.10.0-98.23.amzn1.noarch (amzn-main)
selinux-policy = 3.10.0-98.23.amzn1
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
Requires: libsystemd-id128.so.0()(64bit)
Error: Package: docker-engine-selinux-1.9.1-1.el7.centos.noarch (dockerrepo)
Requires: selinux-policy-base >= 3.13.1-23
Available: selinux-policy-minimum-3.10.0-98.23.amzn1.noarch (amzn-main)
selinux-policy-base = 3.10.0-98.23.amzn1
Available: selinux-policy-mls-3.10.0-98.23.amzn1.noarch (amzn-main)
selinux-policy-base = 3.10.0-98.23.amzn1
Available: selinux-policy-targeted-3.10.0-98.23.amzn1.noarch (amzn-main)
selinux-policy-base = 3.10.0-98.23.amzn1
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
Requires: selinux-policy >= 3.13.1-23
Installing: selinux-policy-3.10.0-98.23.amzn1.noarch (amzn-main)
selinux-policy = 3.10.0-98.23.amzn1
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
Requires: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_196)(64bit)
Error: Package: docker-engine-1.9.1-1.el7.centos.x86_64 (dockerrepo)
Requires: libsystemd-journal.so.0(LIBSYSTEMD_JOURNAL_195)(64bit)
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest


(Irfuel) #7

Seems that simply running sudo yum install -y docker works, so basically don’t follow the amazon docs about getting the latest instructions on the docker site and just use the one delivered by amazon Linux (which is 1.9.1)


(Eli) #8

posting for benefit of future travelers.
@ilianaw and others have added build support for creating rpms for Amazon Linux AMI: https://github.com/docker/docker/tree/master/contrib/builder/rpm/amd64
See discussion in this PR thread for more details: https://github.com/docker/docker/pull/29957


(Mariner) #9

It’s not completely clear from those thread how to install (build) latest Docker on Amazon Linux. Is there any step-by-step manual?