惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

L
LINUX DO - 热门话题
Stack Overflow Blog
Stack Overflow Blog
B
Blog
WordPress大学
WordPress大学
Project Zero
Project Zero
P
Palo Alto Networks Blog
阮一峰的网络日志
阮一峰的网络日志
博客园 - 司徒正美
有赞技术团队
有赞技术团队
S
SegmentFault 最新的问题
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
小众软件
小众软件
T
Tailwind CSS Blog
Forbes - Security
Forbes - Security
F
Full Disclosure
SecWiki News
SecWiki News
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
Hacker News: Ask HN
Hacker News: Ask HN
C
Check Point Blog
Microsoft Security Blog
Microsoft Security Blog
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
F
Fortinet All Blogs
Cisco Talos Blog
Cisco Talos Blog
G
Google Developers Blog
J
Java Code Geeks
Google DeepMind News
Google DeepMind News
人人都是产品经理
人人都是产品经理
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
Recorded Future
Recorded Future
O
OpenAI News
Spread Privacy
Spread Privacy
MongoDB | Blog
MongoDB | Blog
H
Hackread – Cybersecurity News, Data Breaches, AI and More
C
Cybersecurity and Infrastructure Security Agency CISA
S
Securelist
V
Vulnerabilities – Threatpost
Y
Y Combinator Blog
IT之家
IT之家
U
Unit 42
腾讯CDC
S
Security Affairs
C
Cisco Blogs
Schneier on Security
Schneier on Security
The Last Watchdog
The Last Watchdog
B
Blog RSS Feed
宝玉的分享
宝玉的分享
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
S
Security @ Cisco Blogs
Cyberwarzone
Cyberwarzone
T
The Blog of Author Tim Ferriss

error on 打工人日志

k8s master 节点 Unauthorized kindle 邮件发送失败,错误代码E999 SELinux 问题:导致端口无法创建,无法访问 linux服务器进程打开文件过多导致服务异常 解决Elasticsearch索引只读(read-only) Linux 系统收包流程以及内核参数优化 Vue3 + vite + nginx项目部署后404问题 githubAction set-output弃用错误 k8s CNI 问题 连接认证失效 k8s.gcr.io国内无法连接解决方法 K8S 问题排查:cgroup 内存泄露问题 安装 docker 出现 ERROR: Unsupported distribution 'ol' 问题
docker 问题处理
2022-08-04 · via error on 打工人日志

docker 无法启动

打开服务器输入docker ps,输出错误
Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?

怀疑是不是docker.services 部署没成功,systemctl start docker 启动 docker,结果服务器还是报错

Job for docker.service failed because the control process exited with error code.
See “systemctl status docker.service” and “journalctl -xe” for details.

systemctl status docker.service 输出日志:

 1● docker.service - Docker Application Container Engine
 2     Loaded: loaded (/lib/systemd/system/docker.service; enabled; vendor preset: enabled)
 3     Active: failed (Result: exit-code) since Thu 2022-08-04 11:43:05 CST; 2min 57s ago
 4TriggeredBy: ● docker.socket
 5       Docs: https://docs.docker.com
 6    Process: 30432 ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock (code=exited, status=1/FAILURE)
 7   Main PID: 30432 (code=exited, status=1/FAILURE)
 8
 9Aug 04 11:43:05 master01 systemd[1]: docker.service: Scheduled restart job, restart counter is at 3.
10Aug 04 11:43:05 master01 systemd[1]: Stopped Docker Application Container Engine.
11Aug 04 11:43:05 master01 systemd[1]: docker.service: Start request repeated too quickly.
12Aug 04 11:43:05 master01 systemd[1]: docker.service: Failed with result 'exit-code'.
13Aug 04 11:43:05 master01 systemd[1]: Failed to start Docker Application Container Engine.

journalctl -xe 输出日志:

 1Aug 04 11:46:49 master01 systemd[1]: Starting Docker Socket for the API.
 2-- Subject: A start job for unit docker.socket has begun execution
 3-- Defined-By: systemd
 4-- Support: http://www.ubuntu.com/support
 5--
 6-- A start job for unit docker.socket has begun execution.
 7--
 8-- The job identifier is 58900.
 9Aug 04 11:46:49 master01 systemd[1]: Listening on Docker Socket for the API.
10-- Subject: A start job for unit docker.socket has finished successfully
11-- Defined-By: systemd
12-- Support: http://www.ubuntu.com/support
13--
14-- A start job for unit docker.socket has finished successfully.
15--
16-- The job identifier is 58900.
17Aug 04 11:46:49 master01 systemd[1]: Starting Docker Application Container Engine...
18-- Subject: A start job for unit docker.service has begun execution
19-- Defined-By: systemd
20-- Support: http://www.ubuntu.com/support
21--
22-- A start job for unit docker.service has begun execution.
23--
24-- The job identifier is 58830.
25Aug 04 11:46:49 master01 dockerd[30544]: unable to configure the Docker daemon with file /etc/docker/daemon.json: EOF
26Aug 04 11:46:49 master01 systemd[1]: docker.service: Main process exited, code=exited, status=1/FAILURE
27-- Subject: Unit process exited
28-- Defined-By: systemd
29-- Support: http://www.ubuntu.com/support
30--
31-- An ExecStart= process belonging to unit docker.service has exited.
32--
33-- The process' exit code is 'exited' and its exit status is 1.
34Aug 04 11:46:49 master01 systemd[1]: docker.service: Failed with result 'exit-code'.
35-- Subject: Unit failed
36-- Defined-By: systemd
37-- Support: http://www.ubuntu.com/support
38--
39-- The unit docker.service has entered the 'failed' state with result 'exit-code'.
40Aug 04 11:46:49 master01 systemd[1]: Failed to start Docker Application Container Engine.
41-- Subject: A start job for unit docker.service has failed
42-- Defined-By: systemd
43-- Support: http://www.ubuntu.com/support
44--
45-- A start job for unit docker.service has finished with a failure.
46--
47-- The job identifier is 58830 and the job result is failed.
48Aug 04 11:46:49 master01 sudo[30535]: pam_unix(sudo:session): session closed for user root

我运行了:

sudo dockerd –debug

输出日志:
unable to configure the Docker daemon with file /etc/docker/daemon.json: EOF

  • 解决方法:
1#如果 /etc/docker/daemon.json 为空
2vim /etc/docker/daemon.json
3# 添加
4{
5}
6#保存退出
7:wq

重启 docker

systemctl restart docker