Unable to install docker

I am trying to do hyperledger fabric(setting up the environment) and it required docker. I tried searching the internet of solving to install docker but it was to no avail. The following is the errors encountered when I tried to install dockers.

At git bash(git) I tried to use sudo apt-get install docker-engine. But it says

  • docker-compose can't find services or containers in Docker for Mac
  • Logstash cannot receive data with Kafka
  • Docker build ignore file permissions
  • PostgreSQL docker container on Widnows
  • Invoke Docker Remote API using Java
  • ceph rbd with docker volumes
  • Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    Some packages could not be installed. This may mean that you have requested an impossible situation or if you are using the unstable distribution that some required packages have not yet been created or been moved out of Incoming.
    The following information may help to resolve the situation:
    The following packages have unmet dependencies:
     Docker-engine: Depends: init-system-helpers (>= 1.13~) but it is not installable
                     Depends: sysv-rc (>= 2.88dsf-24) but 2.88dsf-13.10ubuntu11 is to be installed or
                              file-rc (>= 0.8.16) but it is not installable
                     Depends: libc6 (>= 2.17) but 2.15-0ubuntu10 is to be installed
                     Depends: libdevmapper1.02.1 (>= 2:1.02.63) but 2:1.02.48-4ubuntu7 is to be installed
                     Depends: libsystemd-journal0 (>= 201) but it is not installable
                     Recommends: aufs-tools but it is not going to be installed
                     Recommends: cgroupfs-mount but it is not installable or
                                 cgroup-lite but it is not going to be installed
                     Recommends: git but it is not going to be installed
    E: Unable to correct problems, you have held broken packages.

    I have followed every single step of this website in installing docker:

    This is the website I have tried to build hyperledger fabric (At the stage of building outside of vagrant, installing docker):

  • Docker linking container
  • Containers can not connect after docker update
  • Should I use Vagrant or Docker for creating an isolated environment? [closed]
  • Laravel installed on a local volume (Mac) from docker nginx/php-fpm can't write session files
  • multiple app nodes how to expose jmx in kubernetes?
  • exec not found using Dockerfile ENTRYPOINT
  • 3 Solutions collect form web for “Unable to install docker”

    Clean up the invalid package repository:

    cd ../../etc/apt/sources.list.d
    sudo rm docker.list

    Then add the repository and update:

    sudo apt-add-repository 'deb https://apt.dockerproject.org/repo ubuntu-xenial main'
    sudo apt-get update
    sudo apt-get install docker-engine

    Maybe this page can help you
    Package Download: libsystemd-journal0

    You can download certain deb file then install it using dpkg command, but there may still be some dependency problems. So you’d better modify your /etc/apt/source.list file according to this page(if you need a 64-bit version).

    As for libsystemd-journal0

    You can add the following line after the tail of /etc/apt/sources.list

    deb http://cz.archive.ubuntu.com/ubuntu trusty main


    sudo apt-get update

    I guess other dependency problems can be solved in a similar way.

    Sorry, my English skill is not good.

    Add backports to your apt repo :
    “deb http://ftp.de.debian.org/debian wheezy-backports main”

    and perform a :

    sudo apt-get update


    sudo apt-get install docker-engine

    should complete fine.

    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.