Gentoo Archives: gentoo-user

From: Mansour Al Akeel <mansour.alakeel@×××××.com>
To: gentoo-user@l.g.o
Subject: Re: [gentoo-user] Docker installation issues
Date: Sat, 10 Dec 2022 20:50:57
Message-Id: CAFvvX=YRVPD6zGfaPnvznxc=PMR77Hk-E1VpfjES4M6L2Qcpbg@mail.gmail.com
In Reply to: Re: [gentoo-user] Docker installation issues by Andreas Fink
1 Andreas,
2
3 Thank you very much. In fact I didn't go that deep yet, and not sure if I
4 should. I just found that the url is not accessible even from a browser.
5 Googling a bit, tells me there is no clear URL for docker-registry and
6 possibly this one is outdated. I will continue looking around to confirm
7 what the current default repo should be. If you have any suggestions,
8 please let me know.
9
10
11 localhost in ~
12 ○ → curl -k -v https://registry-1.docker.io/v2/
13 * Trying 34.228.211.243:443...
14
15 * connect to 34.228.211.243 port 443 failed: Connection timed out
16 * Failed to connect to registry-1.docker.io port 443 after 129401 ms:
17 Couldn't connect to server
18 * Closing connection 0
19 curl: (28) Failed to connect to registry-1.docker.io port 443 after 129401
20 ms: Couldn't connect to server
21
22
23
24
25
26 On Sat, Dec 10, 2022 at 1:32 PM Andreas Fink <finkandreas@×××.de> wrote:
27
28 > On Sat, 10 Dec 2022 12:30:40 -0500
29 > Mansour Al Akeel <mansour.alakeel@×××××.com> wrote:
30 >
31 > > I am using Openrc
32 > >
33 > > This was my initial /etc/conf.d/docker
34 > > DOCKER_OPTS="--storage-driver overlay2 --data-root /srv/var/lib/docker"
35 > >
36 > > when I try:
37 > >
38 > > $ docker pull hello-world
39 > >
40 > > Error response from daemon: Get "https://registry-1.docker.io/v2/":
41 > > net/http: request canceled while waiting for connection (Client.Timeout
42 > > exceeded while awaiting headers)
43 > >
44 > > Trying to troubleshoot:
45 > >
46 > > localhost /home/mansour # tail -n 20 /var/log/docker.log
47 > > time="2022-12-10T12:17:03.473550705-05:00" level=info msg="scheme
48 > \"unix\"
49 > > not registered, fallback to default scheme" module=grpc
50 > > time="2022-12-10T12:17:03.473566413-05:00" level=info
51 > > msg="ccResolverWrapper: sending update to cc:
52 > > {[{unix:///run/containerd/containerd.sock <nil> 0 <nil>}] <nil> <nil>}"
53 > > module=grpc
54 > > time="2022-12-10T12:17:03.473573787-05:00" level=info msg="ClientConn
55 > > switching balancer to \"pick_first\"" module=grpc
56 > > time="2022-12-10T12:17:03.474530993-05:00" level=info msg="parsed scheme:
57 > > \"unix\"" module=grpc
58 > > time="2022-12-10T12:17:03.474545549-05:00" level=info msg="scheme
59 > \"unix\"
60 > > not registered, fallback to default scheme" module=grpc
61 > > time="2022-12-10T12:17:03.474563752-05:00" level=info
62 > > msg="ccResolverWrapper: sending update to cc:
63 > > {[{unix:///run/containerd/containerd.sock <nil> 0 <nil>}] <nil> <nil>}"
64 > > module=grpc
65 > > time="2022-12-10T12:17:03.474571186-05:00" level=info msg="ClientConn
66 > > switching balancer to \"pick_first\"" module=grpc
67 > > time="2022-12-10T12:17:03.478908716-05:00" level=warning msg="Your kernel
68 > > does not support cgroup blkio weight"
69 > > time="2022-12-10T12:17:03.478927115-05:00" level=warning msg="Your kernel
70 > > does not support cgroup blkio weight_device"
71 > > time="2022-12-10T12:17:03.479037897-05:00" level=info msg="Loading
72 > > containers: start."
73 > > time="2022-12-10T12:17:03.495743563-05:00" level=info msg="failed to read
74 > > ipv6 net.ipv6.conf.<bridge>.accept_ra" bridge=docker0
75 > > syspath=/proc/sys/net/ipv6/conf/docker0/accept_ra
76 > > time="2022-12-10T12:17:03.518761943-05:00" level=info msg="Default bridge
77 > > (docker0) is assigned with an IP address 172.17.0.0/16. Daemon option
78 > --bip
79 > > can be used to set a preferred IP address"
80 > > time="2022-12-10T12:17:03.518886881-05:00" level=info msg="failed to read
81 > > ipv6 net.ipv6.conf.<bridge>.accept_ra" bridge=docker0
82 > > syspath=/proc/sys/net/ipv6/conf/docker0/accept_ra
83 > > time="2022-12-10T12:17:03.534616741-05:00" level=info msg="Loading
84 > > containers: done."
85 > > time="2022-12-10T12:17:03.541080189-05:00" level=info msg="Docker daemon"
86 > > commit=a89b84221c graphdriver(s)=overlay2 version=20.10.17
87 > > time="2022-12-10T12:17:03.541122352-05:00" level=info msg="Daemon has
88 > > completed initialization"
89 > > time="2022-12-10T12:17:03.549888103-05:00" level=info msg="API listen on
90 > > /var/run/docker.sock"
91 > > time="2022-12-10T12:17:27.025622231-05:00" level=warning msg="Error
92 > getting
93 > > v2 registry: Get \"https://registry-1.docker.io/v2/\": net/http: request
94 > > canceled while waiting for connection (Client.Timeout exceeded while
95 > > awaiting headers)"
96 > > time="2022-12-10T12:17:27.025667054-05:00" level=info msg="Attempting
97 > next
98 > > endpoint for pull after error: Get \"https://registry-1.docker.io/v2/\":
99 > > net/http: request canceled while waiting for connection (Client.Timeout
100 > > exceeded while awaiting headers)"
101 > > time="2022-12-10T12:17:27.026851821-05:00" level=error msg="Handler for
102 > > POST /v1.41/images/create returned error: Get \"
103 > > https://registry-1.docker.io/v2/\": net/http: request canceled while
104 > > waiting for connection (Client.Timeout exceeded while awaiting headers)"
105 > >
106 > > time="2022-12-10T12:15:42.036053086-05:00" level=info msg="loading plugin
107 > > \"io.containerd.internal.v1.tracing\"..." type=io.containerd.internal.v1
108 > > time="2022-12-10T12:15:42.036068412-05:00" level=error msg="failed to
109 > > initialize a tracing processor \"otlp\"" error="no OpenTelemetry
110 > endpoint:
111 > > skip plugin"
112 > > time="2022-12-10T12:15:42.036100189-05:00" level=info msg="loading plugin
113 > > \"io.containerd.grpc.v1.cri\"..." type=io.containerd.grpc.v1
114 > > time="2022-12-10T12:15:42.036390695-05:00" level=info msg="Start cri
115 > plugin
116 > > with config {PluginConfig:{ContainerdConfig:{Snapshotter:overlayfs
117 > > DefaultRuntimeName:runc DefaultRuntime:{Type: Path: Engine:
118 > > PodAnnotations:[] ContainerAnnotations:[] Root: Options:map[]
119 > > PrivilegedWithoutHostDevices:false BaseRuntimeSpec: NetworkPluginConfDir:
120 > > NetworkPluginMaxConfNum:0} UntrustedWorkloadRuntime:{Type: Path: Engine:
121 > > PodAnnotations:[] ContainerAnnotations:[] Root: Options:map[]
122 > > PrivilegedWithoutHostDevices:false BaseRuntimeSpec: NetworkPluginConfDir:
123 > > NetworkPluginMaxConfNum:0} Runtimes:map[runc:{Type:io.containerd.runc.v2
124 > > Path: Engine: PodAnnotations:[] ContainerAnnotations:[] Root:
125 > > Options:map[BinaryName: CriuImagePath: CriuPath: CriuWorkPath: IoGid:0
126 > > IoUid:0 NoNewKeyring:false NoPivotRoot:false Root: ShimCgroup:
127 > > SystemdCgroup:false] PrivilegedWithoutHostDevices:false BaseRuntimeSpec:
128 > > NetworkPluginConfDir: NetworkPluginMaxConfNum:0}] NoPivot:false
129 > > DisableSnapshotAnnotations:true DiscardUnpackedLayers:false
130 > > IgnoreRdtNotEnabledErrors:false}
131 > > CniConfig:{NetworkPluginBinDir:/opt/cni/bin
132 > > NetworkPluginConfDir:/etc/cni/net.d NetworkPluginMaxConfNum:1
133 > > NetworkPluginConfTemplate: IPPreference:} Registry:{ConfigPath:
134 > > Mirrors:map[] Configs:map[] Auths:map[] Headers:map[]}
135 > > ImageDecryption:{KeyModel:node} DisableTCPService:true
136 > > StreamServerAddress:127.0.0.1 StreamServerPort:0 StreamIdleTimeout:4h0m0s
137 > > EnableSelinux:false SelinuxCategoryRange:1024 SandboxImage:
138 > > k8s.gcr.io/pause:3.6 StatsCollectPeriod:10 SystemdCgroup:false
139 > > EnableTLSStreaming:false X509KeyPairStreaming:{TLSCertFile: TLSKeyFile:}
140 > > MaxContainerLogLineSize:16384 DisableCgroup:false DisableApparmor:false
141 > > RestrictOOMScoreAdj:false MaxConcurrentDownloads:3 DisableProcMount:false
142 > > UnsetSeccompProfile: TolerateMissingHugetlbController:true
143 > > DisableHugetlbController:true DeviceOwnershipFromSecurityContext:false
144 > > IgnoreImageDefinedVolumes:false NetNSMountsUnderStateDir:false
145 > > EnableUnprivilegedPorts:false EnableUnprivilegedICMP:false}
146 > > ContainerdRootDir:/var/lib/containerd
147 > > ContainerdEndpoint:/run/containerd/containerd.sock
148 > > RootDir:/var/lib/containerd/io.containerd.grpc.v1.cri
149 > > StateDir:/run/containerd/io.containerd.grpc.v1.cri}"
150 > > time="2022-12-10T12:15:42.036530498-05:00" level=info msg="Connect
151 > > containerd service"
152 > > time="2022-12-10T12:15:42.036627681-05:00" level=info msg="Get image
153 > > filesystem path
154 > > \"/var/lib/containerd/io.containerd.snapshotter.v1.overlayfs\""
155 > > time="2022-12-10T12:15:42.036896077-05:00" level=error msg="failed to
156 > load
157 > > cni during init, please check CRI plugin status before setting up network
158 > > for pods" error="cni config load failed: no network config found in
159 > > /etc/cni/net.d: cni plugin not initialized: failed to load cni config"
160 > > time="2022-12-10T12:15:42.036986623-05:00" level=info msg="Start
161 > > subscribing containerd event"
162 > > time="2022-12-10T12:15:42.037028034-05:00" level=info msg="Start
163 > recovering
164 > > state"
165 > > time="2022-12-10T12:15:42.037035874-05:00" level=info msg=serving...
166 > > address=/run/containerd/containerd.sock.ttrpc
167 > > time="2022-12-10T12:15:42.037068181-05:00" level=info msg=serving...
168 > > address=/run/containerd/containerd.sock
169 > > time="2022-12-10T12:15:42.037085346-05:00" level=info msg="containerd
170 > > successfully booted in 0.015889s"
171 > > time="2022-12-10T12:15:42.037072303-05:00" level=info msg="Start event
172 > > monitor"
173 > > time="2022-12-10T12:15:42.037107987-05:00" level=info msg="Start
174 > snapshots
175 > > syncer"
176 > > time="2022-12-10T12:15:42.037119126-05:00" level=info msg="Start cni
177 > > network conf syncer for default"
178 > > time="2022-12-10T12:15:42.037127266-05:00" level=info msg="Start
179 > streaming
180 > > server"
181 > >
182 > >
183 > > Looking at resolv.conf
184 > >
185 > > localhost /home/mansour # cat /etc/resolv.conf
186 > > # Generated by dhcpcd from wlp3s0.dhcp
187 > > # /etc/resolv.conf.head can replace this line
188 > > domain Home
189 > > nameserver 192.168.1.1
190 > > # /etc/resolv.conf.tail can replace this line
191 > >
192 > > So, I added the following to my /etc/dhcpcd.conf
193 > > static domain_name_servers=8.8.8.8 8.8.4.4 192.168.1.1
194 > >
195 > > And restarted dhcpcd:
196 > >
197 > > localhost /home/mansour # cat /etc/resolv.conf
198 > > # Generated by dhcpcd from wlp3s0.dhcp
199 > > # /etc/resolv.conf.head can replace this line
200 > > domain Home
201 > > nameserver 8.8.8.8
202 > > nameserver 8.8.4.4
203 > > nameserver 192.168.1.1
204 > > # /etc/resolv.conf.tail can replace this line
205 > >
206 > >
207 > > docker.log still shows the same error:
208 > > time="2022-12-10T12:28:16.519126445-05:00" level=warning msg="Error
209 > getting
210 > > v2 registry: Get \"https://registry-1.docker.io/v2/\": net/http: request
211 > > canceled while waiting for connection (Client.Timeout exceeded while
212 > > awaiting headers)"
213 > > time="2022-12-10T12:28:16.519173944-05:00" level=info msg="Attempting
214 > next
215 > > endpoint for pull after error: Get \"https://registry-1.docker.io/v2/\":
216 > > net/http: request canceled while waiting for connection (Client.Timeout
217 > > exceeded while awaiting headers)"
218 > > time="2022-12-10T12:28:16.520489790-05:00" level=error msg="Handler for
219 > > POST /v1.41/images/create returned error: Get \"
220 > > https://registry-1.docker.io/v2/\": net/http: request canceled while
221 > > waiting for connection (Client.Timeout exceeded while awaiting headers)"
222 > >
223 > > I am not able to login with "docker login"
224 > >
225 > > Where do I look further for additional troubleshooting hints? Google
226 > didn't
227 > > help a lot.
228 > >
229 > > Thank you.
230 >
231 >
232 > Hello,
233 > my first step would be checking if there is some inherent network
234 > problem reaching registry-1.docker.io/v2, e.g. via
235 > curl -v https://registry-1.docker.io/v2/
236 >
237 > If that runs successfully, you could try if there is an MTU problem. I
238 > remember that I had to set MTU to 1450 in some virtualized environment,
239 > otherwise docker would not run correctly, i.e. I had in
240 > /etc/conf.d/docer
241 > DOCKER_OPTS="--mtu=1450"
242 >
243 > Hope that gives you an idea what to look for.
244 >
245 > If both does not help, there is wireshark, to watch your network, very
246 > low-level, but might give some hints.
247 >
248 > Cheers
249 > Andreas
250 >
251 >

Replies

Subject Author
Re: [gentoo-user] Docker installation issues Andreas Fink <finkandreas@×××.de>
Re: [gentoo-user] Docker installation issues David Rosenbaum <rosenbaumd181@×××××.com>