Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #237036 > unrolled thread

Docker installation problems

Started by"Gary L. Roach" <garyroach719@gmail.com>
First post2021-07-08 01:30 +0200
Last post2021-07-09 01:30 +0200
Articles 7 — 4 participants

Back to article view | Back to linux.debian.user


Contents

  Docker installation problems "Gary L. Roach" <garyroach719@gmail.com> - 2021-07-08 01:30 +0200
    Re: Docker installation problems IL Ka <kazakevichilya@gmail.com> - 2021-07-08 01:50 +0200
      Re: Docker installation problems "Gary L. Roach" <garyroach719@gmail.com> - 2021-07-08 18:50 +0200
        Re: Docker installation problems john doe <johndoe65534@mail.com> - 2021-07-08 20:00 +0200
        Re: Docker installation problems IL Ka <kazakevichilya@gmail.com> - 2021-07-08 20:00 +0200
        Re: Docker installation problems Alex Mestiashvili <amestia@rsh2.donotuse.de> - 2021-07-08 20:00 +0200
          Re: Docker installation problems [Solved] "Gary L. Roach" <garyroach719@gmail.com> - 2021-07-09 01:30 +0200

#237036 — Docker installation problems

From"Gary L. Roach" <garyroach719@gmail.com>
Date2021-07-08 01:30 +0200
SubjectDocker installation problems
Message-ID<Cyp9n-7dq-1@gated-at.bofh.it>
Operating System: Debian GNU/Linux 10
KDE Plasma Version: 5.14.5
Qt Version: 5.11.3
KDE Frameworks Version: 5.54.0
Kernel Version: 4.19.0-17-amd64
OS Type: 64-bit
Processors: 4 × AMD FX(tm)-4350 Quad-Core Processor
Memory: 15.6 GiB of RAM

Hi All,

I'm still having installation problems with Docker. I followed the 
Digital Ocean instructions for Debian 10 to the letter. Everything went 
fine until I tried to run the test case. I got the following:

> root@debian:/home/gary# docker run hello-world
> docker: Cannot connect to the Docker daemon at 
> unix:///var/run/docker.sock. Is the docker daemon running?.
> See 'docker run --help'.
> root@debian:/var/lib/docker# systemctl status docker
> ● docker.service - Docker Application Container Engine
>    Loaded: loaded (/lib/systemd/system/docker.service; enabled; vendor 
> preset: enabled)
>    Active: failed (Result: exit-code) since Mon 2021-07-05 12:43:13 
> PDT; 2 days ago
>      Docs: https://docs.docker.com
>  Main PID: 1026 (code=exited, status=1/FAILURE)
>
> Jul 05 12:43:13 debian systemd[1]: docker.service: Service 
> RestartSec=2s expired, scheduling restart.
> Jul 05 12:43:13 debian systemd[1]: docker.service: Scheduled restart 
> job, restart counter is at 3.
> Jul 05 12:43:13 debian systemd[1]: Stopped Docker Application 
> Container Engine.
> Jul 05 12:43:13 debian systemd[1]: docker.service: Start request 
> repeated too quickly.
> Jul 05 12:43:13 debian systemd[1]: docker.service: Failed with result 
> 'exit-code'.
> Jul 05 12:43:13 debian systemd[1]: Failed to start Docker Application 
> Container Engine.

I suspect that something might be wrong with the /etc/apt/daemon.json 
file but am not sure what.

> root@debian:/etc/docker# less daemon.json
{
>   "debug": true,
>   "tls": true,
>   "tlscert": "/var/docker/server.pem",
>   "tlskey": "/var/docker/serverkey.pem",
>   "hosts": ["tcp://192.168.254.12:2376"]
> }
My installation doesn't seem to be very stable. I'm using the free 
community edition if that helps. Any help will be sincerely appreciated.

Gary R.

[toc] | [next] | [standalone]


#237037

FromIL Ka <kazakevichilya@gmail.com>
Date2021-07-08 01:50 +0200
Message-ID<CypsJ-7jf-7@gated-at.bofh.it>
In reply to#237036

[Multipart message — attachments visible in raw view] — view raw

>
> I suspect that something might be wrong with the /etc/apt/daemon.json
> file but am not sure what.
>
> try
# dockerd
https://docs.docker.com/config/daemon/#start-the-daemon-manually

Do you see any errors?

[toc] | [prev] | [next] | [standalone]


#237079

From"Gary L. Roach" <garyroach719@gmail.com>
Date2021-07-08 18:50 +0200
Message-ID<CyFnP-6c-1@gated-at.bofh.it>
In reply to#237037

[Multipart message — attachments visible in raw view] — view raw

On 7/7/21 4:43 PM, IL Ka wrote:
>
>     I suspect that something might be wrong with the /etc/apt/daemon.json
>     file but am not sure what.
>
> try
> # dockerd
> https://docs.docker.com/config/daemon/#start-the-daemon-manually 
> <https://docs.docker.com/config/daemon/#start-the-daemon-manually>
>
> Do you see any errors?
>
Running dockerd produced the following:

> root@debian:/etc/docker# dockerd
> INFO[2021-07-08T09:44:02.344680610-07:00] Starting up
> failed to create API server: Could not load X509 key pair (cert: 
> "/var/docker/server.pem", key: "/var/docker/serverkey.pem"): open 
> /var/docker/server.pem: no such file or directory
On my system the /var/docker directory doesn't exist. Further, 
server.pem doesn't exist anywhere on my system. Now what?

Gary R.

[toc] | [prev] | [next] | [standalone]


#237080

Fromjohn doe <johndoe65534@mail.com>
Date2021-07-08 20:00 +0200
Message-ID<CyGtz-HJ-1@gated-at.bofh.it>
In reply to#237079
On 7/8/2021 6:48 PM, Gary L. Roach wrote:
>
> On 7/7/21 4:43 PM, IL Ka wrote:
>>
>>     I suspect that something might be wrong with the /etc/apt/daemon.json
>>     file but am not sure what.
>>
>> try
>> # dockerd
>> https://docs.docker.com/config/daemon/#start-the-daemon-manually
>> <https://docs.docker.com/config/daemon/#start-the-daemon-manually>
>>
>> Do you see any errors?
>>
> Running dockerd produced the following:
>
>> root@debian:/etc/docker# dockerd
>> INFO[2021-07-08T09:44:02.344680610-07:00] Starting up
>> failed to create API server: Could not load X509 key pair (cert:
>> "/var/docker/server.pem", key: "/var/docker/serverkey.pem"): open
>> /var/docker/server.pem: no such file or directory
> On my system the /var/docker directory doesn't exist. Further,
> server.pem doesn't exist anywhere on my system. Now what?
>

Looks like you need to generate that file (1).


1)
https://stackoverflow.com/questions/57830003/var-docker-server-pem-no-such-file-or-directory

--
John Doe

[toc] | [prev] | [next] | [standalone]


#237081

FromIL Ka <kazakevichilya@gmail.com>
Date2021-07-08 20:00 +0200
Message-ID<CyGtA-HJ-3@gated-at.bofh.it>
In reply to#237079

[Multipart message — attachments visible in raw view] — view raw

>
> failed to create API server: Could not load X509 key pair (cert:
> "/var/docker/server.pem", key: "/var/docker/serverkey.pem"): open
> /var/docker/server.pem: no such file or directory
>
> On my system the /var/docker directory doesn't exist. Further, server.pem
> doesn't exist anywhere on my system. Now what?


But in your ``daemon.json`` you explicitly asked for TLS and even provided
a path to these files.
(to enable TLS one needs a certificate (with public key) and private key
for it)

Let's see if docker works without this file.

# mv /etc/docker/daemon.json /etc/docker/daemon.json.back
# dockerd

if it works, start it with ``systemd`` and see if it works



>

[toc] | [prev] | [next] | [standalone]


#237082

FromAlex Mestiashvili <amestia@rsh2.donotuse.de>
Date2021-07-08 20:00 +0200
Message-ID<CyGtA-HJ-7@gated-at.bofh.it>
In reply to#237079
On 7/8/21 6:48 PM, Gary L. Roach wrote:
> 
> On 7/7/21 4:43 PM, IL Ka wrote:
>>
>>     I suspect that something might be wrong with the /etc/apt/daemon.json
>>     file but am not sure what.
>>
>> try
>> # dockerd
>> https://docs.docker.com/config/daemon/#start-the-daemon-manually 
>> <https://docs.docker.com/config/daemon/#start-the-daemon-manually>
>>
>> Do you see any errors?
>>
> Running dockerd produced the following:
> 
>> root@debian:/etc/docker# dockerd
>> INFO[2021-07-08T09:44:02.344680610-07:00] Starting up
>> failed to create API server: Could not load X509 key pair (cert: 
>> "/var/docker/server.pem", key: "/var/docker/serverkey.pem"): open 
>> /var/docker/server.pem: no such file or directory
> On my system the /var/docker directory doesn't exist. Further, 
> server.pem doesn't exist anywhere on my system. Now what?
> 
> Gary R.
> 

 From my little experience, the default docker-ce installation comes 
without daemon.json file. Try to remove it and see if docker comes up.

It also doesn't look like Debian related issue tbh, since it is a third 
party package.

Alex

[toc] | [prev] | [next] | [standalone]


#237091 — Re: Docker installation problems [Solved]

From"Gary L. Roach" <garyroach719@gmail.com>
Date2021-07-09 01:30 +0200
SubjectRe: Docker installation problems [Solved]
Message-ID<CyLCW-3UB-1@gated-at.bofh.it>
In reply to#237082
I reinstalled using the docker.com instructions and it works. I also 
installed Portainer. It also works. I appreciate all of the help. Now 
all I have to do is learn to use it.

Thanks again.

Gary R

On 7/8/21 10:44 AM, Alex Mestiashvili wrote:
> On 7/8/21 6:48 PM, Gary L. Roach wrote:
>>
>> On 7/7/21 4:43 PM, IL Ka wrote:
>>>
>>>     I suspect that something might be wrong with the 
>>> /etc/apt/daemon.json
>>>     file but am not sure what.
>>>
>>> try
>>> # dockerd
>>> https://docs.docker.com/config/daemon/#start-the-daemon-manually 
>>> <https://docs.docker.com/config/daemon/#start-the-daemon-manually>
>>>
>>> Do you see any errors?
>>>
>> Running dockerd produced the following:
>>
>>> root@debian:/etc/docker# dockerd
>>> INFO[2021-07-08T09:44:02.344680610-07:00] Starting up
>>> failed to create API server: Could not load X509 key pair (cert: 
>>> "/var/docker/server.pem", key: "/var/docker/serverkey.pem"): open 
>>> /var/docker/server.pem: no such file or directory
>> On my system the /var/docker directory doesn't exist. Further, 
>> server.pem doesn't exist anywhere on my system. Now what?
>>
>> Gary R.
>>
>
> From my little experience, the default docker-ce installation comes 
> without daemon.json file. Try to remove it and see if docker comes up.
>
> It also doesn't look like Debian related issue tbh, since it is a 
> third party package.
>
> Alex
>

[toc] | [prev] | [standalone]


Back to top | Article view | linux.debian.user


csiph-web