Q: Failed to get D-Bus connection: Operation not permitted
主要是更换systemctl文件。
1、备份systemctl文件
mv /usr/bin/systemctl /usr/bin/systemctl.old
2、获取新文件
curl https://github.com/gdraheim/docker-systemctl-replacement/tree/master/files/docker/systemctl.py > /usr/bin/systemctl
3、设置可执行
chmod +x /usr/bin/systemctl
三、结果
顺利解决,截图如下:
[root@xxx xxx]# service docker start
$ sudo systemctl start docker
通过运行 hello-world 镜像来验证是否正确安装了 Docker Engine-Community 。
$ sudo docker run hello-world
文档更新时间: 2023-08-03 08:07 作者:admin