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