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 error with pip version while building new image
  • GCloud: Copying Files from Local Machine into a Docker Container
  • Docker build freezes installing packages from apt
  • How to make a build arg mandatory during Docker build?
  • “No such file or directory” what's wrong in this Dockerfile?
  • How do I not create docker container logs?
  • 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:
    https://docs.docker.com/engine/installation/linux/ubuntulinux/

    This is the website I have tried to build hyperledger fabric (At the stage of building outside of vagrant, installing docker):
    http://hyperledger-fabric.readthedocs.io/en/latest/dev-setup/build/

  • Installing SQL alongside a new ASP.Net Core project in Docker
  • Mnesia doesn't recognize data after sys restart (no_exists error)
  • docker logs doesn't log detached exec
  • Expose docker container port to other machine
  • Setting up your dev environment using docker
  • How to Mount Hugepages inside Docker
  • 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

    then

    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
    

    Afterwards,

    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.