当我尝试通过Powershell中的docker pull alpine:latest
命令提取docker映像时,收到此消息
Error response from daemon: Get https://registry-1.docker.io/v2/: dial tcp: lookup registry-1.docker.io on [::1]:53: read udp [::1]:43738->[::1]:53: read: connection refused
我为docker使用 linux容器,这是我的 docker信息
Containers: 0
Running: 0
Paused: 0
Stopped: 0
Images: 0
Server Version: 18.03.1-ce
Storage Driver: overlay2
Backing Filesystem: extfs
Supports d_type: true
Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
Volume: local
Network: bridge host macvlan null overlay
Log: awslogs fluentd gcplogs gelf journald json-file logentries splunk syslog
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Init Binary: docker-init
containerd version: 773c489c9c1b21a6d78b5c538cd395416ec50f88
runc version: 4fc53a81fb7c994640722ac585fa9ca548971871
init version: 949e6fa
Security Options:
seccomp
Profile: default
Kernel Version: 4.9.87-linuxkit-aufs
Operating System: Docker for Windows
OSType: linux
Architecture: x86_64
CPUs: 2
Total Memory: 1.934GiB
Name: linuxkit-00155d23d101
ID: KAAJ:RYU5:TJMW:MXFY:KU2F:6A44:N627:72CD:MDEQ:PSV6:CMEF:NHDR
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): true
File Descriptors: 19
Goroutines: 35
System Time: 2018-07-11T06:17:44.0996093Z
EventsListeners: 1
Registry: https://index.docker.io/v1/
Labels:
Experimental: false
Insecure Registries:
127.0.0.0/8
Live Restore Enabled: false
经过研究,我发现重新启动docker / 更改dns 将解决此问题。我确实重新启动了docker +重新安装了边缘版本+更改了dns,但对我而言不起作用。
几周前,我还已经将docker诊断数据上传到 docker for windows github存储库,但是没有运气。
如果我将docker切换为 windows容器,则docker pull命令可以完美地提取图像。当我切换回 linux容器时,它不起作用。