Docker - Unable to locate package docker-engine
Asked Answered
C

6

32

I am trying to install docker in Ubuntu 16.04. I am following this link for docker installation. I am ending up with Unable to locate package docker-engine

My current kernal version - 4.4.0-38-generic Ubuntu version - 16.04

Crescint answered 22/9, 2016 at 17:15 Comment(3)
Did you update your apt sources following instruction here Update your apt sourcesTilda
What output do you get when you execute following: apt-cache policy docker-engine in terminal ?Tilda
I had the same problem. Run sudo apt-get update and then try again sudo apt-get install docker-engine . This solved the issue by meColloidal
H
54

The docker package already inside Ubuntu is called docker.io [1] so just do

sudo apt-get install docker.io

But if you follow that link you gave and do steps 7, 8, 9 then your installation will know about the package at the docker repo and also find docker-engine.

Your call. I run the Ubuntu version (currently 0.11.2 on Ubuntu 16.04) on some machines, and the one from Docker on others (as I was curious about some 0.12 features). Both will work just fine.

[1] As docker is used for a desktop launcher application 'docking' icons.

Hola answered 22/9, 2016 at 17:21 Comment(1)
I installed docker.io and the docker is running. I created docker group and added my user to docker group. But when I run docker run hello-world , I am ending up with an error docker: Error response from daemon: rpc error: code = 2 desc = "oci runtime error: exec format error". The docker is running and active. I restarted docker and even restarted my machine, still no go.Crescint
D
5

I faced the same issue on AWS-EC2 with ubuntu-18.04 server...

running apt-get update does the trick for me....

Once update runs fine then run apt-get install docker.io

Duroc answered 7/2, 2019 at 6:46 Comment(0)
H
2

Docker-compose-plugin is put into the docker.io repo.

Running sudo apt install docker.io ,or apt-get in older Ubuntu versions, will also get you the files you need.

First you will need to run update to make sure you have most recent versions.
sudo apt update

Hydrochloride answered 6/10, 2022 at 5:57 Comment(0)
T
2

I wasn't able to install docker with the current other solutions but managed to get rid of the "Unable to locate package docker-engine" error with a solution mentioned on the GitHub repo issues (issue of May 31, 2020).

The solution was to run these commands:

sudo apt update
sudo apt install apt-transport-https ca-certificates curl gnupg-agent software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
sudo apt update
sudo apt install docker-ce docker-ce-cli containerd.io
Televise answered 31/1, 2023 at 8:46 Comment(0)
C
1

The main solution which solved most of the issues in docker is installing 64-bit version of ubuntu. I was running with 32-bit(i686). Hope it helps ! !

Crescint answered 7/6, 2017 at 14:1 Comment(0)
E
1

Ubuntu 22.04 LTS

sudo apt install docker-compose
Electromagnet answered 25/9, 2023 at 2:38 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.