2018-05-07 docker安裝后啟動不了

https://www.2cto.com/net/201803/730799.html

意思是說:此linux的內核中的SELinux不支持 overlay2 graph driver ,解決方法有兩個,要么啟動一個新內核,要么就在docker里禁用selinux,--selinux-enabled=false

重新編輯docker配置文件:

vi /etc/sysconfig/docker

改為:

然后systemctl start docker 就好啦哈哈哈哈


Error starting daemon: SELinux is not supported with the overlay2 graph driver on this kernel. Either boot into a newer kernel or disable selinux in docker (--selinux-enabled=false)

[root@localhost run]# systemctl status docker.service

● docker.service - Docker Application Container Engine

? Loaded: loaded (/usr/lib/systemd/system/docker.service; enabled; vendor preset: disabled)

? Active: failed (Result: exit-code) since Mon 2018-05-07 10:49:31 CST; 20s ago

? ? Docs: http://docs.docker.com

? Process: 54217 ExecStart=/usr/bin/dockerd-current --add-runtime docker-runc=/usr/libexec/docker/docker-runc-current --default-runtime=docker-runc --exec-opt native.cgroupdriver=systemd --userland-proxy-path=/usr/libexec/docker/docker-proxy-current --seccomp-profile=/etc/docker/seccomp.json $OPTIONS $DOCKER_STORAGE_OPTIONS $DOCKER_NETWORK_OPTIONS $ADD_REGISTRY $BLOCK_REGISTRY $INSECURE_REGISTRY $REGISTRIES (code=exited, status=1/FAILURE)

Main PID: 54217 (code=exited, status=1/FAILURE)

May 07 10:49:29 localhost.localdomain systemd[1]: Starting Docker Application Conta....

May 07 10:49:30 localhost.localdomain dockerd-current[54217]: time="2018-05-07T10:49...

May 07 10:49:30 localhost.localdomain dockerd-current[54217]: time="2018-05-07T10:49...

May 07 10:49:31 localhost.localdomain dockerd-current[54217]: Error starting daemon:...

May 07 10:49:31 localhost.localdomain systemd[1]: docker.service: main process exit...E

May 07 10:49:31 localhost.localdomain systemd[1]: Failed to start Docker Applicatio....

May 07 10:49:31 localhost.localdomain systemd[1]: Unit docker.service entered faile....

May 07 10:49:31 localhost.localdomain systemd[1]: docker.service failed.

Hint: Some lines were ellipsized, use -l to show in full.

[root@localhost run]# systemctl status docker.service -l

● docker.service - Docker Application Container Engine

? Loaded: loaded (/usr/lib/systemd/system/docker.service; enabled; vendor preset: disabled)

? Active: failed (Result: exit-code) since Mon 2018-05-07 10:49:31 CST; 1min 22s ago

? ? Docs: http://docs.docker.com

? Process: 54217 ExecStart=/usr/bin/dockerd-current --add-runtime docker-runc=/usr/libexec/docker/docker-runc-current --default-runtime=docker-runc --exec-opt native.cgroupdriver=systemd --userland-proxy-path=/usr/libexec/docker/docker-proxy-current --seccomp-profile=/etc/docker/seccomp.json $OPTIONS $DOCKER_STORAGE_OPTIONS $DOCKER_NETWORK_OPTIONS $ADD_REGISTRY $BLOCK_REGISTRY $INSECURE_REGISTRY $REGISTRIES (code=exited, status=1/FAILURE)

Main PID: 54217 (code=exited, status=1/FAILURE)

May 07 10:49:29 localhost.localdomain systemd[1]: Starting Docker Application Container Engine...

May 07 10:49:30 localhost.localdomain dockerd-current[54217]: time="2018-05-07T10:49:30.102683786+08:00" level=warning msg="could not change group /var/run/docker.sock to docker: group docker not found"

May 07 10:49:30 localhost.localdomain dockerd-current[54217]: time="2018-05-07T10:49:30.159748297+08:00" level=info msg="libcontainerd: new containerd process, pid: 54225"

May 07 10:49:31 localhost.localdomain dockerd-current[54217]: Error starting daemon: SELinux is not supported with the overlay2 graph driver on this kernel. Either boot into a newer kernel or disable selinux in docker (--selinux-enabled=false)

May 07 10:49:31 localhost.localdomain systemd[1]: docker.service: main process exited, code=exited, status=1/FAILURE

May 07 10:49:31 localhost.localdomain systemd[1]: Failed to start Docker Application Container Engine.

May 07 10:49:31 localhost.localdomain systemd[1]: Unit docker.service entered failed state.

May 07 10:49:31 localhost.localdomain systemd[1]: docker.service failed.

[root@localhost run]# vi /etc/sysconfig/dock

[root@localhost run]# vi /etc/sysconfig/docker

[root@localhost run]# systemctl start docker

[root@localhost run]# docker images

REPOSITORY? ? ? ? ? TAG? ? ? ? ? ? ? ? IMAGE ID? ? ? ? ? ? CREATED? ? ? ? ? ? SIZE

?著作權歸作者所有,轉載或內容合作請聯系作者
平臺聲明:文章內容(如有圖片或視頻亦包括在內)由作者上傳并發布,文章內容僅代表作者本人觀點,簡書系信息發布平臺,僅提供信息存儲服務。

推薦閱讀更多精彩內容