How to Install Docker on Ubuntu 16.10 Yakkety Yak

As you may know, Docker allows you to pack, ship and run any application as a lightweight container. It’s like a virtual machine, only more portable and resources-efficient. This tutorial is going to show you how to install Docker on Ubuntu 16.10 Yakkety Yak.

The latest version available is Docker 1.12.3, released on October 26th, 2016 and bringing various improvements and bug fixes.

The first requirement of using Docker is that you must be using a 64 bits OS because Docker doesn’t support 32 bits. Additionally, your kernel must be 3.10+. Ubuntu 16.10 comes with Linux Kernel 4.8. Now let’s get started.

Install Docker on Ubuntu 16.10 from Ubuntu Repository

Docker is included in Ubuntu software repository since 14.04 Trusty Tahr. We can install the Docker runtime by executing the following command in terminal.

sudo apt install docker.io

install docker on ubuntu 16.10 from ubuntu repository

During the installation, a docker group and a Systemd service will be created.

Install Docker on Ubuntu 16.10 from Docker’s APT Repository

To ensure that we have the latest and greatest version, we will have to install it from Docker’s APT repository. At the time of this writing (Nov 7, 2016), no official Docker repository for Ubuntu 16.10 exists, but we can use the Docker repo for Ubuntu 16.04.

Fire up a terminal window (CTRL+ALT+T), then edit sources.list file with your favourite text editor such as nano.

sudo nano /etc/apt/sources.list

Scroll down to the bottom of this file and add the following line.

deb https://apt.dockerproject.org/repo ubuntu-xenial main

install latest docker on Ubuntu

Press CTRL+O to save the file, then CTRL+X to exit. Next, run the following command to import the Docker GPG key to Ubuntu 16.10 system so that APT can verify package integrity during installation.

sudo apt-key adv --keyserver hkp://p80.pool.sks-keyservers.net:80 --recv-keys 58118E89F3A912897C070ADBF76221572C52609D

And because this repository uses HTTPS connection, which I recommend all software repositories should be using, we also need to install apt-transport-https and ca-certificates package.

sudo apt install apt-transport-https ca-certificates

Finally, update the package index on your Ubuntu 16.10 system and install docker-engine.

sudo apt update

sudo apt install docker-engine

Some Simple Commands You May Want to Run After Installing Docker

Once Docker is installed, the Docker daemon should be automatically started. You can check its status with:

systemctl status docker

docker daemon status ubuntu 16.10

If it’s not running, then start the daemon with this command:

sudo systemctl start docker

And enable autostart at boot time:

sudo systemctl enable docker

Check Docker version.

docker -v

Sample output:

Docker version 1.12.3, build 6b644ec

Display system-wide information regarding the Docker installation.

sudo docker info

Output:

Containers: 0
 Running: 0
 Paused: 0
 Stopped: 0
Images: 0
Server Version: 1.12.3
Storage Driver: aufs
 Root Dir: /var/lib/docker/aufs
 Backing Filesystem: extfs
 Dirs: 0
 Dirperm1 Supported: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
 Volume: local
 Network: host bridge null overlay
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Security Options: apparmor seccomp
Kernel Version: 4.4.0-45-generic
Operating System: Ubuntu 16.04.1 LTS
OSType: linux
Architecture: x86_64
CPUs: 2
Total Memory: 992.4 MiB
Name: jessie
ID: OK56:VRJT:6APE:EG4O:JTNV:DFMO:BJ7I:PFZA:QNKJ:4K3O:KUA7:3G2V
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): false
Registry: https://index.docker.io/v1/
WARNING: No swap limit support
Insecure Registries:
 127.0.0.0/8

Verify Docker is installed correctly.

sudo docker run hello-world

You should see the following message indicating that Docker is working correctly.

Hello from Docker!
This message shows that your installation appears to be working correctly.

That’s it!

I hope this tutorial helped you install Docker on Ubuntu 16.10 Yakkety Yak. As always, if you found this post useful, then subscribe to our free newsletter.You can also follow us on Google+Twitter or like our Facebook page.

Rate this tutorial
[Total: 13 Average: 4.5]