Cannot use docker with HC2

Post Reply
gerrus
Posts: 3
Joined: Sat Oct 12, 2019 2:38 am
languages_spoken: english german
ODROIDs: ODROID HC2
Has thanked: 0
Been thanked: 0
Contact:

Cannot use docker with HC2

Unread post by gerrus » Sat Oct 12, 2019 3:00 am

Hello,
I'm having a problem with the docker. I can't get a single container to run.
i already tried everything i found on the internet. i deleted docker, reinstalled it, tried different versions.
always the same error message "docker: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?"
can someone help me please ?
what am I doing wrong, what else can I try?

User avatar
tobetter
Posts: 4036
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: X, X2, U2, U3, XU3, C1
Location: Paju, South Korea
Has thanked: 43 times
Been thanked: 188 times
Contact:

Re: Cannot use docker with HC2

Unread post by tobetter » Sat Oct 12, 2019 3:55 am

gerrus wrote:
Sat Oct 12, 2019 3:00 am
Hello,
I'm having a problem with the docker. I can't get a single container to run.
i already tried everything i found on the internet. i deleted docker, reinstalled it, tried different versions.
always the same error message "docker: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?"
can someone help me please ?
what am I doing wrong, what else can I try?
Did you add the user account to docker group, log in and run groups command to see if the user is docker group?
Which kernel version are you running?
Can you run this script if your kernel is properly configured to run Docker?
https://github.com/moby/moby/blob/maste ... -config.sh

User avatar
mad_ady
Posts: 6674
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Has thanked: 194 times
Been thanked: 148 times
Contact:

Re: Cannot use docker with HC2

Unread post by mad_ady » Sat Oct 12, 2019 4:13 am

What does sudo service docker status say?

gerrus
Posts: 3
Joined: Sat Oct 12, 2019 2:38 am
languages_spoken: english german
ODROIDs: ODROID HC2
Has thanked: 0
Been thanked: 0
Contact:

Re: Cannot use docker with HC2

Unread post by gerrus » Sat Oct 12, 2019 6:58 pm

tobetter wrote:
Sat Oct 12, 2019 3:55 am
Did you add the user account to docker group, log in and run groups command to see if the user is docker group?
Which kernel version are you running?
Can you run this script if your kernel is properly configured to run Docker?
https://github.com/moby/moby/blob/maste ... -config.sh
Hello tobetter,
command groups provides " root docker".
the output of the script :

Code: Select all

info: reading kernel config from /proc/config.gz ...

Generally Necessary:
- cgroup hierarchy: properly mounted [/sys/fs/cgroup]
- CONFIG_NAMESPACES: enabled
- CONFIG_NET_NS: enabled
- CONFIG_PID_NS: enabled
- CONFIG_IPC_NS: enabled
- CONFIG_UTS_NS: enabled
- CONFIG_CGROUPS: enabled
- CONFIG_CGROUP_CPUACCT: enabled
- CONFIG_CGROUP_DEVICE: enabled
- CONFIG_CGROUP_FREEZER: enabled
- CONFIG_CGROUP_SCHED: enabled
- CONFIG_CPUSETS: enabled
- CONFIG_MEMCG: enabled
- CONFIG_KEYS: enabled
- CONFIG_VETH: enabled (as module)
- CONFIG_BRIDGE: enabled (as module)
- CONFIG_BRIDGE_NETFILTER: enabled (as module)
- CONFIG_NF_NAT_IPV4: enabled (as module)
- CONFIG_IP_NF_FILTER: enabled (as module)
- CONFIG_IP_NF_TARGET_MASQUERADE: enabled (as module)
- CONFIG_NETFILTER_XT_MATCH_ADDRTYPE: enabled (as module)
- CONFIG_NETFILTER_XT_MATCH_CONNTRACK: enabled (as module)
- CONFIG_NETFILTER_XT_MATCH_IPVS: enabled (as module)
- CONFIG_IP_NF_NAT: enabled (as module)
- CONFIG_NF_NAT: enabled (as module)
- CONFIG_NF_NAT_NEEDED: enabled
- CONFIG_POSIX_MQUEUE: enabled

Optional Features:
- CONFIG_USER_NS: enabled
- CONFIG_SECCOMP: enabled
- CONFIG_CGROUP_PIDS: missing
- CONFIG_MEMCG_SWAP: enabled
- CONFIG_MEMCG_SWAP_ENABLED: enabled
    (cgroup swap accounting is currently enabled)
- CONFIG_BLK_CGROUP: enabled
- CONFIG_BLK_DEV_THROTTLING: enabled
- CONFIG_IOSCHED_CFQ: enabled
- CONFIG_CFQ_GROUP_IOSCHED: enabled
- CONFIG_CGROUP_PERF: enabled
- CONFIG_CGROUP_HUGETLB: missing
- CONFIG_NET_CLS_CGROUP: enabled (as module)
- CONFIG_CGROUP_NET_PRIO: enabled
- CONFIG_CFS_BANDWIDTH: enabled
- CONFIG_FAIR_GROUP_SCHED: enabled
- CONFIG_RT_GROUP_SCHED: enabled
- CONFIG_IP_NF_TARGET_REDIRECT: enabled (as module)
- CONFIG_IP_VS: enabled (as module)
- CONFIG_IP_VS_NFCT: enabled
- CONFIG_IP_VS_PROTO_TCP: enabled
- CONFIG_IP_VS_PROTO_UDP: enabled
- CONFIG_IP_VS_RR: enabled (as module)
- CONFIG_EXT3_FS: enabled
- CONFIG_EXT3_FS_XATTR: missing
- CONFIG_EXT3_FS_POSIX_ACL: enabled
- CONFIG_EXT3_FS_SECURITY: enabled
    (enable these ext3 configs if you are using ext3 as backing filesystem)
- CONFIG_EXT4_FS: enabled
- CONFIG_EXT4_FS_POSIX_ACL: enabled
- CONFIG_EXT4_FS_SECURITY: enabled
- Network Drivers:
  - "overlay":
    - CONFIG_VXLAN: enabled (as module)
    - CONFIG_BRIDGE_VLAN_FILTERING: enabled
      Optional (for encrypted networks):
      - CONFIG_CRYPTO: enabled
      - CONFIG_CRYPTO_AEAD: enabled
      - CONFIG_CRYPTO_GCM: enabled (as module)
      - CONFIG_CRYPTO_SEQIV: enabled
      - CONFIG_CRYPTO_GHASH: enabled (as module)
      - CONFIG_XFRM: enabled
      - CONFIG_XFRM_USER: enabled (as module)
      - CONFIG_XFRM_ALGO: enabled
      - CONFIG_INET_ESP: enabled (as module)
      - CONFIG_INET_XFRM_MODE_TRANSPORT: enabled (as module)
  - "ipvlan":
    - CONFIG_IPVLAN: enabled (as module)
  - "macvlan":
    - CONFIG_MACVLAN: enabled (as module)
    - CONFIG_DUMMY: enabled (as module)
  - "ftp,tftp client in container":
    - CONFIG_NF_NAT_FTP: enabled (as module)
    - CONFIG_NF_CONNTRACK_FTP: enabled (as module)
    - CONFIG_NF_NAT_TFTP: enabled (as module)
    - CONFIG_NF_CONNTRACK_TFTP: enabled (as module)
- Storage Drivers:
  - "aufs":
    - CONFIG_AUFS_FS: missing
  - "btrfs":
    - CONFIG_BTRFS_FS: enabled (as module)
    - CONFIG_BTRFS_FS_POSIX_ACL: enabled
  - "devicemapper":
    - CONFIG_BLK_DEV_DM: enabled
    - CONFIG_DM_THIN_PROVISIONING: enabled (as module)
  - "overlay":
    - CONFIG_OVERLAY_FS: enabled (as module)
  - "zfs":
    - /dev/zfs: missing
    - zfs command: missing
    - zpool command: missing

Limits:
- /proc/sys/kernel/keys/root_maxkeys: 1000000
uname -a:

Code: Select all

Linux odroid 4.14.85-152 #1 SMP PREEMPT Mon Dec 3 03:00:02 -02 2018 armv7l armv7l armv7l GNU/Linux
Hello mad_ady,
output of docker status:

Code: Select all

● docker.service - Docker Application Container Engine
   Loaded: loaded (/lib/systemd/system/docker.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Sat 2019-10-12 11:42:59 CEST; 12min ago
     Docs: https://docs.docker.com
  Process: 28616 ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock (code=exited, status=1/FAILURE)
 Main PID: 28616 (code=exited, status=1/FAILURE)

Okt 12 11:42:59 odroid systemd[1]: docker.service: Service hold-off time over, scheduling restart.
Okt 12 11:42:59 odroid systemd[1]: docker.service: Scheduled restart job, restart counter is at 3.
Okt 12 11:42:59 odroid systemd[1]: Stopped Docker Application Container Engine.
Okt 12 11:42:59 odroid systemd[1]: docker.service: Start request repeated too quickly.
Okt 12 11:42:59 odroid systemd[1]: docker.service: Failed with result 'exit-code'.
Okt 12 11:42:59 odroid systemd[1]: Failed to start Docker Application Container Engine.
thank you for quick help

User avatar
tobetter
Posts: 4036
Joined: Mon Feb 25, 2013 10:55 am
languages_spoken: Korean, English
ODROIDs: X, X2, U2, U3, XU3, C1
Location: Paju, South Korea
Has thanked: 43 times
Been thanked: 188 times
Contact:

Re: Cannot use docker with HC2

Unread post by tobetter » Sat Oct 12, 2019 7:14 pm

I had the same issue earlier and resolved removing "-H fd:" in "/etc/systemd/system/multi-user.target.wants/docker.service"...Just not sure which OS was.

"Tapatalk wishes you to have fun with ODROID"


gerrus
Posts: 3
Joined: Sat Oct 12, 2019 2:38 am
languages_spoken: english german
ODROIDs: ODROID HC2
Has thanked: 0
Been thanked: 0
Contact:

Re: Cannot use docker with HC2

Unread post by gerrus » Sat Oct 12, 2019 8:55 pm

tobetter wrote:
Sat Oct 12, 2019 7:14 pm
I had the same issue earlier and resolved removing "-H fd:" in "/etc/systemd/system/multi-user.target.wants/docker.service"...Just not sure which OS was.

"Tapatalk wishes you to have fun with ODROID"
I'm afraid that didn't help.
I cannot uninstall or reinstall docker-ce.

Code: Select all

Job for docker.service failed because the control process exited with error code.
See "systemctl status docker.service" and "journalctl -xe" for details.
invoke-rc.d: initscript docker, action "start" failed.
● docker.service - Docker Application Container Engine
   Loaded: loaded (/lib/systemd/system/docker.service; disabled; vendor preset: enabled)
   Active: activating (auto-restart) (Result: exit-code) since Sat 2019-10-12 13:50:17 CEST; 27ms ago
     Docs: https://docs.docker.com
  Process: 13694 ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock (code=exited, status=1/FAILURE)
 Main PID: 13694 (code=exited, status=1/FAILURE)
dpkg: Fehler beim Bearbeiten des Paketes docker-ce (--configure):
 installed docker-ce package post-installation script subprocess returned error exit status 1
Fehler traten auf beim Bearbeiten von:
 docker-ce
E: Sub-process /usr/bin/dpkg returned an error code (1)
journalctl-xe :

Code: Select all


-- Unit docker.service has begun starting up.
Okt 12 13:50:22 odroid dockerd[13903]: time="2019-10-12T13:50:22.610972428+02:00" level=info msg="Starting up"
Okt 12 13:50:22 odroid dockerd[13903]: time="2019-10-12T13:50:22.616087968+02:00" level=info msg="detected 127.0.0.53 nameserver, assuming systemd-resolved, so using resolv.conf: /run/systemd/resolve/resolv.conf"
Okt 12 13:50:22 odroid dockerd[13903]: time="2019-10-12T13:50:22.619649896+02:00" level=info msg="parsed scheme: \"unix\"" module=grpc
Okt 12 13:50:22 odroid dockerd[13903]: time="2019-10-12T13:50:22.619778103+02:00" level=info msg="scheme \"unix\" not registered, fallback to default scheme" module=grpc
Okt 12 13:50:22 odroid dockerd[13903]: time="2019-10-12T13:50:22.619928560+02:00" level=info msg="ccResolverWrapper: sending update to cc: {[{unix:///run/containerd/containerd.sock 0  <nil>}] <nil>}" module=grpc
Okt 12 13:50:22 odroid dockerd[13903]: time="2019-10-12T13:50:22.620027726+02:00" level=info msg="ClientConn switching balancer to \"pick_first\"" module=grpc
Okt 12 13:50:22 odroid dockerd[13903]: time="2019-10-12T13:50:22.625162641+02:00" level=info msg="parsed scheme: \"unix\"" module=grpc
Okt 12 13:50:22 odroid dockerd[13903]: time="2019-10-12T13:50:22.625269557+02:00" level=info msg="scheme \"unix\" not registered, fallback to default scheme" module=grpc
Okt 12 13:50:22 odroid dockerd[13903]: time="2019-10-12T13:50:22.625355848+02:00" level=info msg="ccResolverWrapper: sending update to cc: {[{unix:///run/containerd/containerd.sock 0  <nil>}] <nil>}" module=grpc
Okt 12 13:50:22 odroid dockerd[13903]: time="2019-10-12T13:50:22.625457513+02:00" level=info msg="ClientConn switching balancer to \"pick_first\"" module=grpc
Okt 12 13:50:22 odroid dockerd[13903]: time="2019-10-12T13:50:22.649595684+02:00" level=error msg="There are no more loopback devices available."
Okt 12 13:50:22 odroid dockerd[13903]: time="2019-10-12T13:50:22.649953889+02:00" level=error msg="[graphdriver] prior storage driver devicemapper failed: loopback attach failed"
Okt 12 13:50:22 odroid dockerd[13903]: failed to start daemon: error initializing graphdriver: loopback attach failed
Okt 12 13:50:22 odroid systemd[1]: docker.service: Main process exited, code=exited, status=1/FAILURE
Okt 12 13:50:22 odroid systemd[1]: docker.service: Failed with result 'exit-code'.
Okt 12 13:50:22 odroid systemd[1]: Failed to start Docker Application Container Engine.
-- Subject: Unit docker.service has failed
-- Defined-By: systemd


User avatar
mad_ady
Posts: 6674
Joined: Wed Jul 15, 2015 5:00 pm
languages_spoken: english
ODROIDs: XU4, C1+, C2, N1, H2, N2
Location: Bucharest, Romania
Has thanked: 194 times
Been thanked: 148 times
Contact:

Re: Cannot use docker with HC2

Unread post by mad_ady » Sat Oct 12, 2019 9:40 pm

Here's the startup script I'm using with docker on XU4:
http://paste.ubuntu.com/p/CGnKMc6SQc/
I needed control over socket.
Kernel is: Linux IQ-01 4.14.127-164 #1 SMP PREEMPT Wed Jun 19 17:28:22 -03 2019 armv7l armv7l armv7l GNU/Linux

Post Reply

Return to “Issues”

Who is online

Users browsing this forum: No registered users and 1 guest